View Single Post
Old 06-09-2006, 08:45 AM
martys martys is online now
Registered User
Join Date: 06-09-2006
Posts: 24
Manually setting macros

For developer builds, we don't worry about version numbers when we build every night. However, when semi-official builds go out to QA, we want to set the build version number properly. So, rather than trying to do it programmatically, since version numbers are questionable in their progression, we put a "Set Macro" step at the beginning of the build, so it's pretty much a two-step process. Start the build, input the version numbers. Of course, we want to have a messagebox popping up to ask what we want to set it to in all cases, not just when no macro exists. And rather than having to type in the whole version number, it could display the existing version number. To make a long story short (too late), here's a little script that will prompt the user for any macro and display the current version.

function getMacro(name)
	dim tmp
	tmp = ""
	if not vbld_AllMacros.Item(name) is nothing then tmp = vbld_AllMacros.Item(name)
	getMacro = inputbox("Please enter " & name, "Set Macro", tmp)
end function
Then you call it in the Set Macro action using [getMacro("Version")]
Reply With Quote