Feb 11, 2007 #1 allanmc10 Programmer Feb 23, 2006 39 GB I am pressing a btn and showing a form but i want to hide the form the btn is on and when i close existing form, main form comes to the front. Any ideas???? Cheers big al
I am pressing a btn and showing a form but i want to hide the form the btn is on and when i close existing form, main form comes to the front. Any ideas???? Cheers big al
Feb 11, 2007 #2 TipGiver Programmer Sep 1, 2005 1,863 Hi, I must say that by reading your post... i dont understand you. So, according to the title, i would suggest to search for 'singleton form' Hope this helps Upvote 0 Downvote
Hi, I must say that by reading your post... i dont understand you. So, according to the title, i would suggest to search for 'singleton form' Hope this helps
Feb 11, 2007 #3 RonRepp Technical User Feb 25, 2005 1,031 US Al: On form with button, paste this code behind the click event. [code--Form1] Visible=False [/code] Ron Repp If gray hair is a sign of wisdom, then I'm a genius. Upvote 0 Downvote
Al: On form with button, paste this code behind the click event. [code--Form1] Visible=False [/code] Ron Repp If gray hair is a sign of wisdom, then I'm a genius.
Feb 11, 2007 #4 RonRepp Technical User Feb 25, 2005 1,031 US Site keeps erroring: Al: On form with button, paste this code behind the click event. [code--Form1] SetMainForm=Me Visible=False [/code] On 2nd Form, paste this code inside the Formevents.Closing event. [Code--Form2.Closing] FRM1=GetMainForm FRM1.Visible=True [/code] Create a module and add the properties to Set and Get the Main Form [Code--Module1] Public FRM1 as Form1 Public WriteOnly Property SetForm() As Form1 Set(ByVal Value As Form1) FRM1 = Value End Set End Property Public ReadOnly Property GetForm() As Form1 Get Return FRM1 End Get End Property [/code] I hope this helps. Ron Repp If gray hair is a sign of wisdom, then I'm a genius. Upvote 0 Downvote
Site keeps erroring: Al: On form with button, paste this code behind the click event. [code--Form1] SetMainForm=Me Visible=False [/code] On 2nd Form, paste this code inside the Formevents.Closing event. [Code--Form2.Closing] FRM1=GetMainForm FRM1.Visible=True [/code] Create a module and add the properties to Set and Get the Main Form [Code--Module1] Public FRM1 as Form1 Public WriteOnly Property SetForm() As Form1 Set(ByVal Value As Form1) FRM1 = Value End Set End Property Public ReadOnly Property GetForm() As Form1 Get Return FRM1 End Get End Property [/code] I hope this helps. Ron Repp If gray hair is a sign of wisdom, then I'm a genius.