I have the following code:
After copy a range from the original sheet to sheet "Data", how do I go back to the original sheet?
Sub CopyPressure()
Dim Fcell As String
If ActiveSheet.Name = ("Data"
Then
MsgBox ("Go to the original sheet to select the first cell contained value in column Pressure"
Else
Fcell = InputBox("Type first cell in column ? Ex: B3", "Input required"
Range(Fcell).Select
Range(Selection, Selection.End(xlDown)).Select
Selection.Copy
Sheets("Data"
.Select
Range("A1"
.Select
Selection.PasteSpecial Paste:=xlValues, Operation:=xlNone, SkipBlanks:= _
False, Transpose:=False
End If
End Sub
Please help.
Thanks,
XT
After copy a range from the original sheet to sheet "Data", how do I go back to the original sheet?
Sub CopyPressure()
Dim Fcell As String
If ActiveSheet.Name = ("Data"
MsgBox ("Go to the original sheet to select the first cell contained value in column Pressure"
Else
Fcell = InputBox("Type first cell in column ? Ex: B3", "Input required"
Range(Fcell).Select
Range(Selection, Selection.End(xlDown)).Select
Selection.Copy
Sheets("Data"
Range("A1"
Selection.PasteSpecial Paste:=xlValues, Operation:=xlNone, SkipBlanks:= _
False, Transpose:=False
End If
End Sub
Please help.
Thanks,
XT