Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default moving columns to a new sheet


i have the workbook attached,

in sheet1 i have a list of hyperlinks in column A, and Names in column
B

what i want to do is in sheet 2

column A - shows the Column A from sheet 1 without the hyperlink

Coulmn B - Shows the Column A Actual hyperlink url

Coulmn C - Shows Column B from sheet 1

i know i need a macro to do this but not sure how to do this, i have
attached a small example of what i need

many thanks

Craig


+-------------------------------------------------------------------+
|Filename: test.zip |
|Download: http://www.excelforum.com/attachment.php?postid=5013 |
+-------------------------------------------------------------------+

--
craigmacca
------------------------------------------------------------------------
craigmacca's Profile: http://www.excelforum.com/member.php...o&userid=36259
View this thread: http://www.excelforum.com/showthread...hreadid=560521

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default moving columns to a new sheet


Hi

You may want to try this

Sub copy_sheet1_sheet2()
Sheets("Sheet1").Select
rowcount = Cells(Cells.Rows.Count, "a").End(xlUp).Row
For i = 1 To rowcount
Sheets("Sheet1").Select
Range("a" & i).Select
val_a = ActiveCell.Value
ActiveCell.Offset(0, 1).Select
val_c = ActiveCell.Value
ActiveCell.Offset(0, -1).Select
val_b = ActiveCell.Hyperlinks(1).Address
Sheets("Sheet2").Select
Range("A" & i).Select
ActiveCell.Value = val_a
Range("b" & i).Select
ActiveCell = val_b
Range("c" & i).Select
ActiveCell = val_c
Next
Call make_hyperlink
End Sub
Sub make_hyperlink()
Sheets("Sheet2").Select
rowcount = Cells(Cells.Rows.Count, "a").End(xlUp).Row
For i = 1 To rowcount
Range("b" & i).Select
adr = ActiveCell.Value
ActiveSheet.Hyperlinks.Add Anchor:=Selection, Address:=adr, _
TextToDisplay:=adr
Next
End Su

--
jette
-----------------------------------------------------------------------
jetted's Profile: http://www.excelforum.com/member.php...fo&userid=1753
View this thread: http://www.excelforum.com/showthread.php?threadid=56052

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
formula for moving information from one sheet to another sheet Puzzled Excel Discussion (Misc queries) 4 June 6th 10 05:58 AM
Moving Columns egrave Excel Discussion (Misc queries) 1 July 6th 08 11:09 PM
moving informatiion from one sheet to a total sheet john Excel Discussion (Misc queries) 2 January 31st 08 10:17 PM
Moving Columns only hyyfte[_16_] Excel Programming 0 September 22nd 04 04:03 PM
Moving Columns gminor7 Excel Programming 2 September 12th 03 03:27 PM


All times are GMT +1. The time now is 05:21 PM.

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"