ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Variable Storage (https://www.excelbanter.com/excel-programming/352737-variable-storage.html)

gti_jobert[_10_]

Variable Storage
 

Hello All,

Basically I have a form with a 'Save Data' cmdButton, when the user
clicks this they are prompted with a MsgBox (vbYesNo). If they say
'Yes' then I want to unload the form and then reload it again -
assuming this clears all the data inc. arrays. Before the form is
unloaded, I want to store some values on the form then put them BACK on
the form once its been reloaded.

I tried a global varaible declaration, but it'll only last as long as
the form - would the method be using the module to store/retrieve
varables? If so how wouyld i go by doing this?

Hope this makes sense to someone out there. Thanks in adavance for any
help!

Joe


--
gti_jobert
------------------------------------------------------------------------
gti_jobert's Profile: http://www.excelforum.com/member.php...o&userid=30634
View this thread: http://www.excelforum.com/showthread...hreadid=509949


gti_jobert[_11_]

Variable Storage
 

Simply:

Store Variable
Unload Form
Show Form
Retrieve Variable - Add to For

--
gti_jober
-----------------------------------------------------------------------
gti_jobert's Profile: http://www.excelforum.com/member.php...fo&userid=3063
View this thread: http://www.excelforum.com/showthread.php?threadid=50994


keepITcool

Variable Storage
 
store your variable at module level
in a NORMAL module, not in the userform.
--
keepITcool
| www.XLsupport.com | keepITcool chello nl | amsterdam


gti_jobert wrote :


Simply:

Store Variable
Unload Form
Show Form
Retrieve Variable - Add to Form


keepITcool

Variable Storage
 
PS:
those variable must be Public

--
keepITcool
| www.XLsupport.com | keepITcool chello nl | amsterdam


keepITcool wrote :

store your variable at module level
in a NORMAL module, not in the userform.



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

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com