G
Grace
I was having trouble with public declarations et al amongst modules, and
decided the only variable which was problematic in a filename I was trying
to concatenate was the one where I tried to call the variable instead of a
worksheet cell populated with that variable's value. So, I decided, even
though the spreadsheet didn't "need" it, to just do the same thing, i.e.,
stick the result in a worksheet cell, and then use the cell's value in
creating the filename. But I am having trouble with this, too. This is
part of a macro:
strMessage = "ENTER LONG DISPLAY NAME OF WRAP MANAGER"
StrTitle = ""
StrDefault = ""
StrMGR_LONG_NAME = InputBox(strMessage, StrTitle, StrDefault)
Sheets("INPUTS").Range("C11").Value = StrMGR_LONG_NAME ' cell C11 populates
strMessage = "ENTER SHORT NAME OF WRAP MANAGER"
StrTitle = ""
StrDefault = ""
StrMGR_SHORT_NAME = InputBox(strMessage, StrTitle, StrDefault)
MsgBox StrMGR_SHORT_NAME ' the macro confirms that this is producing the
string entered in the InputBox query
Sheets("INPUTS").Range("C29").Value = StrMGR_SHORT_NAME ' cell C29 does not
populate, why?
In the first case, it clearly puts the result of what I entered in cell C11.
In the 2nd case, it is NOT putting the result I entered in cell C29. As you
can see from my message box statement, I check to make sure that the
strMGR_SHORT_NAME is getting the right result and indeed it is. Cell C29 is
not protected so that is not the problem. What can explain why the C11
value is populating on the spreadsheet, but the C29 value is not?
Thanks,
Grace
decided the only variable which was problematic in a filename I was trying
to concatenate was the one where I tried to call the variable instead of a
worksheet cell populated with that variable's value. So, I decided, even
though the spreadsheet didn't "need" it, to just do the same thing, i.e.,
stick the result in a worksheet cell, and then use the cell's value in
creating the filename. But I am having trouble with this, too. This is
part of a macro:
strMessage = "ENTER LONG DISPLAY NAME OF WRAP MANAGER"
StrTitle = ""
StrDefault = ""
StrMGR_LONG_NAME = InputBox(strMessage, StrTitle, StrDefault)
Sheets("INPUTS").Range("C11").Value = StrMGR_LONG_NAME ' cell C11 populates
strMessage = "ENTER SHORT NAME OF WRAP MANAGER"
StrTitle = ""
StrDefault = ""
StrMGR_SHORT_NAME = InputBox(strMessage, StrTitle, StrDefault)
MsgBox StrMGR_SHORT_NAME ' the macro confirms that this is producing the
string entered in the InputBox query
Sheets("INPUTS").Range("C29").Value = StrMGR_SHORT_NAME ' cell C29 does not
populate, why?
In the first case, it clearly puts the result of what I entered in cell C11.
In the 2nd case, it is NOT putting the result I entered in cell C29. As you
can see from my message box statement, I check to make sure that the
strMGR_SHORT_NAME is getting the right result and indeed it is. Cell C29 is
not protected so that is not the problem. What can explain why the C11
value is populating on the spreadsheet, but the C29 value is not?
Thanks,
Grace