LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 265
Default variable available after userform

Hi all; I have this macro


public var1,var2, var3 as integer
sub getdata()
var1=cells(3,1)
load userform1
userform1.show ' In userform1 the var1 should be used and then the value of
cells(3,1) changed, var2 is obtained from userform1.
if var2<1 then
load userform2
userform2.show
else

load userform3
userform3.show
end if
'var3 is obtained from userform2 or 3 and used
end sub

my problem is with the variables, when I open the userform1 var1 loose its
value, also, when I get values from userform2 and 3 I'm not able to operate
with them in my macro, could someone give me a small explanation about
variables in userforms and how to solve my problem???

TIA

 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
userform textbox to variable Peter[_61_] Excel Programming 2 July 18th 07 11:50 AM
Userform and variable Jeff Excel Discussion (Misc queries) 1 March 16th 07 03:14 PM
userform and variable Gary Keramidas Excel Programming 11 December 6th 06 05:34 PM
Variable from Userform to Macro Vikesh Jain Excel Programming 2 June 28th 06 06:13 AM
VBA Variable as userform [email protected] Excel Programming 3 April 13th 06 08:32 PM


All times are GMT +1. The time now is 03:12 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"