View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
playerbigdog playerbigdog is offline
external usenet poster
 
Posts: 22
Default Print Page Set up

Hey i think that is going to work. Thanks for the quick fix.

"TomPl" wrote:

Maybe, if you change "YEARS2" to "PrintReports2" in the Workbooks.Open
statement it will work.

"playerbigdog" wrote:

Title3 = "What year would you like to print"
PrintReports2 = InputBox(Message3, Title3, "EnterYear")
EnterYear = "YEARS2"
If PrintCharts = "" Then
cancel = "1"
EnterYear = "YEARS2"
Else
cancel = "0"
EnterYear = "YEARS2"
End If

Workbooks.Open Filename:="C:\PF Test\" + "PF Assessment " + YEARS2 +
"\All Members\" + myVar1 + ".xlsx"
Sheets(myVar1).Select

I want this code to allow me to have what year enterd into the "EnterYear"
spot saved under YEARS2. Any suggestions?