Steps
1. Convert your macro into visual basic
2. Edit the newly created module containing the vba
3. Create a form and place a text box and a button on it
4. in the text box enter the name of the fiel to import
5. on the OnClick event of the command button copy the code from the module to here and replace the known file name with the control name.
Example taken from converted macro
DoCmd.TransferSpreadsheet acImport, 8, "tblImport", "fred", True, ""
code placed on OnClick event of command button
Code:
Dim sFile As String
sFile = Me.TextBox1.Value
DoCmd.TransferSpreadsheet acImport, 8, "tblImport", sFile, True, ""
David