Home |
Search |
Today's Posts |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Do you turn off screenupdating before you try to get that range? Turn it back
on (just temporarily)--and turn it off after you get the range: Option Explicit Sub testme01() Dim Rnge As Range Application.ScreenUpdating = True Set Rnge = Nothing On Error Resume Next Set Rnge = Application.InputBox("Select Cell", Type:=8) On Error GoTo 0 Application.ScreenUpdating = False If Rnge Is Nothing Then 'user hit cancel Exit Sub '??? End If Selection.Copy Rnge.Cells(1).PasteSpecial Paste:=xlPasteFormulas Application.ScreenUpdating = True End Sub STEVE BELL wrote: Thanks guys, here's the code Set rnge = Application.InputBox("Select Cell", Type:=8) Selection.Copy Range(rnge).Select Selection.PasteSpecial Paste:=xlFormulas I am just trying to select a small range on a row and have it pasted to another range. The input box helps select the start cell for the paste. But now I can't even select a cell when the input box comes up... (it worked before) Am running Excel 2k, and show R1C1 instead of A1. -- steveB Remove "AYN" from email to respond "Tom Ogilvy" wrote in message ... get your ranges, then copy and paste in one command. -- Regards, Tom Ogilvy "STEVE BELL" wrote in message news:zny3f.45133$HM1.37868@trnddc04... Thanks in advance for any help on this. I had built code to define a range Set rnge = Application.InputBox("Select Cell", Type:=8) and either one of 2 things would occur 1. Unable to select cell on worksheet 2. rnge not defined ("empty") This was working in Excel 2000 when I copied a single (row) range and went to select a cell to paste into. Than it started acting up when I copied more than 2 rows, and selected a single (from the Input Box) cell to paste to. Has my Excel been corrupted or am I missing something... Thanks... -- steveB Remove "AYN" from email to respond -- Dave Peterson |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
I can't input anything I type on Excel. What can I do? Nothing p. | Excel Worksheet Functions | |||
error 13 type mismatch input box | Excel Discussion (Misc queries) | |||
How to modify the code for different type of input? | Excel Worksheet Functions | |||
How to modify the code for different type of input? | Excel Discussion (Misc queries) | |||
Defining input box data type? | Excel Programming |