A Microsoft Outlook email forum. Outlook Banter

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » Outlook Banter forum » Microsoft Outlook Email Newsgroups » Outlook and VBA
Site Map Home Register Authors List Search Today's Posts Mark Forums Read Web Partners

Cancel and Reset UserForm and macros



 
 
Thread Tools Search this Thread Display Modes
  #1  
Old October 28th 08, 02:24 PM posted to microsoft.public.outlook.program_vba
DStrong
external usenet poster
 
Posts: 18
Default Cancel and Reset UserForm and macros

OK, this seems like it should not be that big of a deal, but I am going crazy
trying to figure this out. I am running Outlook 2003 on XP Pro machine. I
have created a userform that functions in all ways as it should, except when
the function of the form is done or if the user hits the cancel button.

I first had userform1.hide, that got rid of the form, but did not seem to
reset things in the VBA side of things. I then tried, reset, quit, terminate,
close. I have look up on MSND with no luck, googled this still no luck. I
have Sue Moshers book on programming and cannot find what I need to do this.

What I want to happen is the same thing that happens when in VBA and I click
the STOP(Reset) control button.

Is there a command line that I need to make this work? Or does this just not
matter? Please help, I am pulling my hair out. j/k
Ads
  #2  
Old October 28th 08, 02:44 PM posted to microsoft.public.outlook.program_vba
Ken Slovak - [MVP - Outlook]
external usenet poster
 
Posts: 5,848
Default Cancel and Reset UserForm and macros

UserForm1.Hide() just make the form not visible. Any code on the form would
continue to run. You probably want to use Unload UserForm1 instead, which
will terminate the form.

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Professional Programming Outlook 2007.
Reminder Manager, Extended Reminders, Attachment Options.
http://www.slovaktech.com/products.htm


"DStrong" wrote in message
news
OK, this seems like it should not be that big of a deal, but I am going
crazy
trying to figure this out. I am running Outlook 2003 on XP Pro machine. I
have created a userform that functions in all ways as it should, except
when
the function of the form is done or if the user hits the cancel button.

I first had userform1.hide, that got rid of the form, but did not seem to
reset things in the VBA side of things. I then tried, reset, quit,
terminate,
close. I have look up on MSND with no luck, googled this still no luck. I
have Sue Moshers book on programming and cannot find what I need to do
this.

What I want to happen is the same thing that happens when in VBA and I
click
the STOP(Reset) control button.

Is there a command line that I need to make this work? Or does this just
not
matter? Please help, I am pulling my hair out. j/k


  #3  
Old October 28th 08, 02:54 PM posted to microsoft.public.outlook.program_vba
DStrong
external usenet poster
 
Posts: 18
Default Cancel and Reset UserForm and macros

Ken you are the best! Thank you, I will not be going bald after all. Good day
to you.

"Ken Slovak - [MVP - Outlook]" wrote:

UserForm1.Hide() just make the form not visible. Any code on the form would
continue to run. You probably want to use Unload UserForm1 instead, which
will terminate the form.

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Professional Programming Outlook 2007.
Reminder Manager, Extended Reminders, Attachment Options.
http://www.slovaktech.com/products.htm


"DStrong" wrote in message
news
OK, this seems like it should not be that big of a deal, but I am going
crazy
trying to figure this out. I am running Outlook 2003 on XP Pro machine. I
have created a userform that functions in all ways as it should, except
when
the function of the form is done or if the user hits the cancel button.

I first had userform1.hide, that got rid of the form, but did not seem to
reset things in the VBA side of things. I then tried, reset, quit,
terminate,
close. I have look up on MSND with no luck, googled this still no luck. I
have Sue Moshers book on programming and cannot find what I need to do
this.

What I want to happen is the same thing that happens when in VBA and I
click
the STOP(Reset) control button.

Is there a command line that I need to make this work? Or does this just
not
matter? Please help, I am pulling my hair out. j/k



  #4  
Old March 6th 09, 09:55 PM posted to microsoft.public.outlook.program_vba
Chris Malter
external usenet poster
 
Posts: 1
Default Cancel and Reset UserForm and macros

Ken, you rock. I've been trying to figure this one out for a while. If only
Microsoft was consistent with VBA and VB, I could have just found the close
method and used me.close. Ah well. At least we have experts like you.
 




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Outlook vba errror message says Access can't find my userform MarceepooNu Outlook and VBA 5 October 8th 08 10:19 PM
UserForm Listbox with Access Database Table data RobLo Outlook - Using Forms 4 March 9th 07 04:47 PM
Launching an UserForm from a cutomised form Tof Outlook - Using Forms 5 January 9th 07 10:02 PM
Build a userform on excel to copy contacts from outlook 2003 Oggy Outlook - General Queries 4 January 2nd 07 07:13 PM
UserForm ShowModal strange behaviour David OShea Outlook - Using Forms 1 March 14th 06 06:58 PM


All times are GMT +1. The time now is 08:47 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.Search Engine Friendly URLs by vBSEO 2.4.0
Copyright ©2004-2025 Outlook Banter.
The comments are property of their posters.