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 / March 2006

Tip: Looking for answers? Try searching our database.

Using Click Once for a  Console Application

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Orlando - 17 Mar 2006 22:41 GMT
Hi,
We need to have two interfaces into our web services layer - a GUI and a
command line scriptable client. I know Click Once can be used for both GUI
and CUI apps... but can the Console App be called via a batch file? So far
I've found one place that says this isn't possible, but i wanted to confirm
that their is absolutely no work around.

thanks,
Orlando
"Jeffrey Tan[MSFT]" - 20 Mar 2006 08:02 GMT
Hi Orlando,

Thanks for your post!

Batch file is a collection of shell command. .Net ClickOnce uses rundll32
with dfshim.dll to lauch the *.application file, so we can place this shell
command in a batch file. Then it will invoke the ClickOnce application
without any problem.

Try placing the following in the test.bat file:
rundll32.exe dfshim.dll,ShOpenVerbApplication
http://machinename/appname/appname.application

Hope this helps!

Best regards,
Jeffrey Tan
Microsoft Online Partner Support
Signature

Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.

Orlando - 20 Mar 2006 17:46 GMT
Thanks for your response.. Can you pass arguments in this method such that
the console app will get them? For example,

ConsoleApp -f c:\MyFileToRead.txt

Or are you limited to passing things via querystring?

Orlando

> Hi Orlando,
>
[quoted text clipped - 16 lines]
> Get Secure! - www.microsoft.com/security
> This posting is provided "as is" with no warranties and confers no rights.
"Jeffrey Tan[MSFT]" - 21 Mar 2006 03:05 GMT
Hi Orlando,

Yes, we cannot use commandLine to pass parameters into the ClickOnce
application at run time. We can only access query string parameters for a
ClickOnce deployment from the application's AppDomain. For more
information, please refer to the article below:
"How to: Retrieve Query String Information in a ClickOnce Application "
http://msdn2.microsoft.com/en-us/library/ms172242(VS.80).aspx

Hope this helps!

Best regards,
Jeffrey Tan
Microsoft Online Partner Support
Signature

Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.


Rate this thread:







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.