Code: Select all
Set rngSelRange = Application.InputBox( _
Prompt:="Please select the columns that you wish to include in the chart.", _
Title:="Selected columns", _
Default:=rngSelRange.Address, _
Type:=8)
Code: Select all
Set rngSelRange = Application.InputBox( _
Prompt:="Please select the columns that you wish to include in the chart.", _
Title:="Selected columns", _
Default:=rngSelRange.Address, _
Type:=8)
Code: Select all
Set rngSelRange = Application.InputBox( _
Prompt:="Please select the columns that you wish to include in the chart.", _
Title:="Selected columns", _
Default:=rngSelRange.Address(ReferenceStyle:=Application.ReferenceStyle), _
Type:=8)
Code: Select all
Dim rngSelRange As Range, rngtemp As Range
'Set rngSelRange = Selection
Set rngtemp = Nothing
On Error Resume Next
Set rngtemp = Application.InputBox( _
Prompt:="Please select the columns that you wish to include in the chart.", _
Title:="Selected columns", _
Default:=rngSelRange.Address(ReferenceStyle:=Application.ReferenceStyle), _
Type:=8)
On Error GoTo 0
'test what's in rngtemp:
If rngtemp Is Nothing Then
MsgBox "Cancelled"
Else
Set rngSelRange = rngtemp
rngSelRange.Select
End If