Click here to Skip to main content
15,900,108 members
Please Sign up or sign in to vote.
2.50/5 (2 votes)
See more:
alright i know how to get the form to startup with windows, what i want is a form that doesnt open (isnt visible) and launches a function , like lets say u have a button and u click it to open a second form , so when the pc launches at startup , instead of showing u the 1st form with the button it shows u the second form(button clicked automaticly) - i was thinking of using it on the form loading :"event" going to try it now but any other suggestions are much apreciated? :)
Posted
Comments
BillWoodruff 23-Oct-15 0:30am    
Win Forms ? WPF ?

Is your current auto-start code putting a short-cut to the App in the StartUp folder, or is it modifying the Win Registry.

Please edit your question and describe what you are doing in more detail.

Sounds like a system tray application might be what you want.

1 solution

Consider creating an arg list for your application and use a value in the list to set a flag.

You can use it to automatically launch the function and do the other program-flow control things you'd like to do if it's present.
 
Share this answer
 
Comments
jamesmc1535 22-Oct-15 9:19am    
okay ill try it like that , i want to make like a email thing that sends to my email address when my pc gets switched on, i have the email sending working but its with a button click - not auto click ,
BillWoodruff 23-Oct-15 2:40am    
+5 To correct stupid down-vote. This may be a short answer, but it contains useful content, and definitely does not deserve a down-vote !
W Balboos, GHB 23-Oct-15 6:31am    
Thanks - it seems to have been my lucky day: two such down votes. The satisfaction is in the comment immediately before yours - that the questioner might have found it useful.
BillWoodruff 23-Oct-15 10:33am    
If that is where your satisfaction is, then your heart's in the right place, as well as your mind :) cheers, Bill
jamesmc1535 26-Oct-15 4:44am    
thanks for the help :) - im confused now, why did it get a downvote :x ??

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