Prev Previous Post   Next Post Next
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4
Default Excel

Hi Craig

How about something like this:
Sub test()
Dim DataCell As Range
Dim RangeCell As Range

For Each DataCell In Range("A1:A3")
Set RangeCell = DataCell.Offset(0, 1)
Range(RangeCell).Value = DataCell.Value
Next

End Sub

This obviously assumes that the ranges A1:A3 contain your data and B1:B3
contains the corresponding addresses where you would like to insert the
values.

Hope this helps!

Regards
Jane Pratt
Developer Tools Support
Microsoft UK

This posting is provided "AS IS" with no warranties, and confers no rights.
Use of included script samples are subject to the terms specified at
http://www.microsoft.com/info/cpyright.htm.

 
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



All times are GMT +1. The time now is 07:55 PM.

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

About Us

"It's about Microsoft Excel"