MrExcel Publishing
Your One Stop for Excel Tips & Solutions

inputbox concatenation


Posted by Derick J. on February 13, 2001 9:36 AM

I'm pre-loading the filename into an input box, but I need to concatenate the value (subject) from A1. This is what I have so far...

DestFile = InputBox("Enter the destination filename" & Chr(10) & "(with complete path):", "KSUCVM Excel File Exporter", "C:\Windows\Desktop\diff_" & A1.Value & ".txt")

It works with a static filename, but not with the concatentation. Any help would be GREATLY appreciated.


Posted by Dave Hawley on February 13, 2001 11:51 PM

Hi Derick

I would advise stronly against using an InputBox to collect a file name, the user WILL stuff it up 9 times out of 10. Try this instead:

DestFile = Application.GetOpenFilename
MsgBox DestFile

OzGrid Business Applications