Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5
Default Macro to Move cells

Your answer works great thanks but I need the value copied not the formula.
Is there a way to do that.

"Weasel" wrote:

I'm trying to move a range of cells to a new file and new range I can't get
it to work.

eg.
doc name: sheet1
range: a2:f2
new file: sheet2
new range: a1:f1

Any help would be appreciated

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 694
Default Macro to Move cells

In that case, use the PasteSpecial method the following way:

Workbooks("book1.xls").Worksheets("sheet1").Range( "a2:f2").Copy
Workbooks("book2.xls")Worksheets("sheet2").Range(" a1").PasteSpecial _
xlPasteValues
Application.CutCopyMode = False

Regards,
sebastien

"Weasel" wrote:

Your answer works great thanks but I need the value copied not the formula.
Is there a way to do that.

"Weasel" wrote:

I'm trying to move a range of cells to a new file and new range I can't get
it to work.

eg.
doc name: sheet1
range: a2:f2
new file: sheet2
new range: a1:f1

Any help would be appreciated

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5
Default Macro to Move cells

Thanks alot! Everything works great now thanks.

"sebastienm" wrote:

In that case, use the PasteSpecial method the following way:

Workbooks("book1.xls").Worksheets("sheet1").Range( "a2:f2").Copy
Workbooks("book2.xls")Worksheets("sheet2").Range(" a1").PasteSpecial _
xlPasteValues
Application.CutCopyMode = False

Regards,
sebastien

"Weasel" wrote:

Your answer works great thanks but I need the value copied not the formula.
Is there a way to do that.

"Weasel" wrote:

I'm trying to move a range of cells to a new file and new range I can't get
it to work.

eg.
doc name: sheet1
range: a2:f2
new file: sheet2
new range: a1:f1

Any help would be appreciated

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
macro to move to another cell Frappier New Users to Excel 8 November 11th 08 02:06 PM
Can references (to cells being sorted) move with the cells? Zack Setting up and Configuration of Excel 1 January 16th 08 01:50 PM
Sorting cells: a list behind the cells do not move with the cell Ross M Excel Discussion (Misc queries) 2 September 21st 06 12:14 PM
Macro to move to specified cells, pause for input at each? Pete in Montrose Excel Discussion (Misc queries) 1 March 5th 05 06:18 PM
Macro to Move cells Weasel Excel Programming 1 September 3rd 04 10:49 PM


All times are GMT +1. The time now is 07:30 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"