Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Windows Forms / WinForm General / November 2006

Tip: Looking for answers? Try searching our database.

ClickOnce - How to add config file to list of files that get published

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
roybrew@att.net - 29 Nov 2006 17:51 GMT
This (seemingly) simple item has escaped me after pouring over tons of
posts about ClickOnce.  How does one add a config file
(myapp.exe.config) to the list of executables and dlls that get
published with a ClickOnce application?  All I want to do has have a
standard config file get dropped down in the folder where the
application gets run from.  I don't want to have to edit the manifest
every time I publish.  When you go to the publish tab in the project
settings and click on the "Application Files" button, it seems to find
the EXE, and DLLs correctly.  How can I make sure that my config file
gets added to that list as well?  TIA

Roy
Andy - 29 Nov 2006 19:47 GMT
Did you try clicking the Applications Files button?  Normally though if
your have an App.config in  your solution, it will automatically pick
up the config file for clickonce.

HTH
Andy

> This (seemingly) simple item has escaped me after pouring over tons of
> posts about ClickOnce.  How does one add a config file
[quoted text clipped - 8 lines]
>
> Roy
roybrew@att.net - 30 Nov 2006 15:24 GMT
Uh, yeah.  I clicked the button.  That's how I found my exe and dlls
listed.  Does the config file actually need to be named "App.config" or
can it be called MyApp.exe.config?

roy

> Did you try clicking the Applications Files button?  Normally though if
> your have an App.config in  your solution, it will automatically pick
[quoted text clipped - 15 lines]
> >
> > Roy
Andy - 30 Nov 2006 16:19 GMT
In your project it should be called App.Config.  When you build, VS
will automatically rename that file to whatever the configuration
should be called after it copies the file to the bin folder.

HTH
Andy

> Uh, yeah.  I clicked the button.  That's how I found my exe and dlls
> listed.  Does the config file actually need to be named "App.config" or
> can it be called MyApp.exe.config?
>
> roy
roybrew@att.net - 30 Nov 2006 17:41 GMT
Thanks Andy.  I was also able to add the config file as it was named
(i.e. myaapp.exe.config) and give it a build action of "Content" and
make sure it was copied to the output directory.  This also added it to
the list of Application files.  But your way is cleaner and appears to
be the standard way, so I'll use that.  Thanks again for the help.

roy

> In your project it should be called App.Config.  When you build, VS
> will automatically rename that file to whatever the configuration
[quoted text clipped - 8 lines]
> >
> > roy

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.