Click here to Skip to main content
15,868,159 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
SQL
where can i find app.config. under the solution tree, i do not have app.config. how to add app.config in vb.net in class library application.



please help out. Thanks!..
Posted
Comments
Sergey Alexandrovich Kryukov 16-Oct-13 13:35pm    
Not clear. Why do you need it and why would you have to find it, where?
—SA

In Solution Explorer, select some node: the project node or some sub-directory. From context menu, chose "Add" => "New Item" => ["Add New Item" window] => "General" => "Add Application Configuration File". Another option is: create a brand new application project and just find this node in it.

After that, I would advise to drag the newly created node under project's "Properties" node (it does not allow to add items directly, but this is the best place for app.config).

Are you sure you know what app.config is used for? I'm asking, because I'm not sure if you understand that "app.config" goes to output under different name, named after your application's main executable module of your entry assembly name. (Asking just in case, sorry if this is redundant.) If you started from the application Visual Studio template, this node already was there, so why did you remove it? (Before delving into programming, a reasonable developer first learns the tools used, at least looks at all the UI elements shown by the IDE and learns what they do. Why wasting time on development if you feel blind-folded?)

—SA
 
Share this answer
 
v3
Class Library projects don't really need an app.config. This is because they just generate a .DLL file and get loaded directly into the .EXE that's using them. This means that the app.config file that your library uses will be the host applications app.config, NOT the app.config you put into your class library project.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900