Try this
Option Explicit
Sub PrintSht()
Dim iX As Integer
Dim FirstNumber As Integer
Dim LastNumber As Integer
Dim PgCopy As String
FirstNumber = Application.InputBox(prompt:="Enter first number", Type:=1)
If FirstNumber > 1 Then GoTo exit_proc
LastNumber = Application.InputBox(prompt:="Enter last number", Type:=1)
If LastNumber > 1 Then GoTo exit_proc
For iX = FirstNumber To LastNumber
PgCopy = "QSA" & iX
Cells(1, 1).Value = PgCopy '<- puts number in A1
ActiveSheet.PrintPreview '<just for testing
'ActiveSheet.PrintOut '<- print sheet
Next iX
Exit Sub
exit_proc:
'no number entered
MsgBox "You must enter a number", vbCritical, "Cancelled"
End Sub
Bookmarks