Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3
Default cut and paste using absolute references in vba

A B C D
1 start time

2 5 2 X

3 3 4 Y

3 6 3 Z


The cursor is at D2.
What is the code to cut and paste values in
column C - X to I2:J2, Y to G3:J3 and Z to J4:J6?
Hope this is understandable.

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default cut and paste using absolute references in vba

Sub BuiltData()
for each cell in Range("C2:C4")
cell.Offset(0,cell.offset(0,-2).Value+1). _
Resize(1,cell.offset(0,-1).Value).Value =
cell.Value
cell.ClearContents
Next
End Sub

Assume

Z to J4:J6
should say
Z to J4:K4

--
Regards,
Tom Ogilvy



"Stewart" wrote in message
...
A B C D
1 start time

2 5 2 X

3 3 4 Y

3 6 3 Z


The cursor is at D2.
What is the code to cut and paste values in
column C - X to I2:J2, Y to G3:J3 and Z to J4:J6?
Hope this is understandable.



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
convert relative cell references to absolute cell references via amacro? Dave F[_2_] Excel Discussion (Misc queries) 1 May 15th 08 04:43 PM
Help with converting a block of cells with Absolute and mixed references to relative references Vulcan Excel Worksheet Functions 3 December 13th 07 11:43 PM
Absolute References Dan Beard Excel Discussion (Misc queries) 3 October 16th 07 03:20 AM
Absolute References [email protected] Excel Worksheet Functions 1 November 29th 06 12:41 AM
transpose absolute references Mark Whittall Excel Programming 3 August 27th 03 04:27 AM


All times are GMT +1. The time now is 06:25 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"