Select the Name of the Worksheet with InputBox

N

Neeraja

Hi,

Could someone let me know how to Select the Name of the
Worksheet which has the Data with the help of an Input
box.

Right now in my Macro I am providing the user with an
option to select the Excel file. The code is as follows:

Sub OpenOneFile()

ExcelFile1 = Application.GetOpenFilename("Excel-
files,*.xls", _
1, "Select Input File To Open", , False)
If TypeName(ExcelFile1) = "Boolean" Then Exit Sub

Debug.Print "Selected file: " & ExcelFile1
Workbooks.Open ExcelFile1
End Sub


After selecting the Excel File, the user must be Provided
with an option to select the Excel Sheet which has the
needed Data. How do I do this????

I appreciate any help.
Thanks,
Neeraja.
 
D

Dave Peterson

see one suggestion at your other post.
Hi,

Could someone let me know how to Select the Name of the
Worksheet which has the Data with the help of an Input
box.

Right now in my Macro I am providing the user with an
option to select the Excel file. The code is as follows:

Sub OpenOneFile()

ExcelFile1 = Application.GetOpenFilename("Excel-
files,*.xls", _
1, "Select Input File To Open", , False)
If TypeName(ExcelFile1) = "Boolean" Then Exit Sub

Debug.Print "Selected file: " & ExcelFile1
Workbooks.Open ExcelFile1
End Sub

After selecting the Excel File, the user must be Provided
with an option to select the Excel Sheet which has the
needed Data. How do I do this????

I appreciate any help.
Thanks,
Neeraja.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top