VBA programming assistance

tyantorno

New member
Joined
Nov 29, 2012
Messages
6
Reaction score
0
Points
0
Hello All,
I am working on creating a VBA multiple form based program to edit a text file, basically modify columns with user defined input that occurs monthly. This program would be to assist multiple users in editing this large text file. This modification of the file could be the same each month. Is there a way for a user to be able to pull up “settings” that they had last month to redo the manipulation? I appreciate any input to point me in the right direction. Thank you.
 

JeffreyWeir

Super Moderator
Staff member
Joined
Mar 22, 2011
Messages
357
Reaction score
0
Points
0
Location
New Zealand
There sure is...just save the settings to either a hidden worksheet or a named constant (i.e. a named range that holds a constant, rather than a reference to an actual cell)

For example, on a workseet called 'Settings' set up a named range called "UserName" to say hold the user's name. Then you can refer to this in VBA like so:
IF [UserName] = "Jeff" then msgbox "Don't muck up my spreadsheet, Jeff!"

To set up a named constant for the above example, open NameManager, click "New", put UserName in the Name box and in the RefersTo box type "Jeff" WITHOUT an equals sign (and without the quotes)
 

tyantorno

New member
Joined
Nov 29, 2012
Messages
6
Reaction score
0
Points
0
Thank you Jeff, excellent idea. I really appreciate it. Have a great day!
 
Top