Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
I am running the following macro to add an additional sheet.
Sheets("ICS 214").Select Sheets("ICS 214").Copy Befo=Sheets(2) ' End Sub The problem I have is it copies over some information from unlocked cells that I would like to have blank on the new sheet. What can i add to the macro to have it copy the original sheet and automatically clear a group of cells such as d29-d46? |
#2
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
With Sheets(("ICS 214")
.range("D29:D46").clearcontents .copy befo= Sheets(2) end with HTH -- AP "EAHRENS" a écrit dans le message de ... I am running the following macro to add an additional sheet. Sheets("ICS 214").Select Sheets("ICS 214").Copy Befo=Sheets(2) ' End Sub The problem I have is it copies over some information from unlocked cells that I would like to have blank on the new sheet. What can i add to the macro to have it copy the original sheet and automatically clear a group of cells such as d29-d46? |
#3
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
I apparently am not smart enough to apply your fix and need a lower level of
help. I changed the macro and it now reads: Sub ICS214() ' ' ICS214 Macro ' Macro recorded 10/5/2005 by Eric Ahrens ' With Sheets("ICS 214") ..Range("D29:D46").ClearContents .Copy befo=Sheets(2) End With HTH -- ' End Sub When I run it, I get an errof message sub not defined and HTH is highlighted. What did I do wrong? "Ardus Petus" wrote: With Sheets(("ICS 214") .range("D29:D46").clearcontents .copy befo= Sheets(2) end with HTH -- AP "EAHRENS" a écrit dans le message de ... I am running the following macro to add an additional sheet. Sheets("ICS 214").Select Sheets("ICS 214").Copy Befo=Sheets(2) ' End Sub The problem I have is it copies over some information from unlocked cells that I would like to have blank on the new sheet. What can i add to the macro to have it copy the original sheet and automatically clear a group of cells such as d29-d46? |
#4
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Clear the HTH line!
HTH means Hope This Helps HTH -- AP "EAHRENS" a écrit dans le message de ... I apparently am not smart enough to apply your fix and need a lower level of help. I changed the macro and it now reads: Sub ICS214() ' ' ICS214 Macro ' Macro recorded 10/5/2005 by Eric Ahrens ' With Sheets("ICS 214") .Range("D29:D46").ClearContents .Copy befo=Sheets(2) End With HTH -- ' End Sub When I run it, I get an errof message sub not defined and HTH is highlighted. What did I do wrong? "Ardus Petus" wrote: With Sheets(("ICS 214") .range("D29:D46").clearcontents .copy befo= Sheets(2) end with HTH -- AP "EAHRENS" a écrit dans le message de ... I am running the following macro to add an additional sheet. Sheets("ICS 214").Select Sheets("ICS 214").Copy Befo=Sheets(2) ' End Sub The problem I have is it copies over some information from unlocked cells that I would like to have blank on the new sheet. What can i add to the macro to have it copy the original sheet and automatically clear a group of cells such as d29-d46? |
#5
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
I figured I was doing something wrong. i removed it and now get an error
message that reads: Run-time error 1004, Cannot change part of a merged cell. Debug highlights .Range("D29:D46").ClearContents The macro I am running reads: Sub ICS214() ' ' ICS214 Macro ' Macro recorded 10/5/2005 by Eric Ahrens ' With Sheets("ICS 214") ..Range("D29:D46").ClearContents .Copy befo=Sheets(2) End With ' End Sub When I runit I get an error message that "Ardus Petus" wrote: Clear the HTH line! HTH means Hope This Helps HTH -- AP "EAHRENS" a écrit dans le message de ... I apparently am not smart enough to apply your fix and need a lower level of help. I changed the macro and it now reads: Sub ICS214() ' ' ICS214 Macro ' Macro recorded 10/5/2005 by Eric Ahrens ' With Sheets("ICS 214") .Range("D29:D46").ClearContents .Copy befo=Sheets(2) End With HTH -- ' End Sub When I run it, I get an errof message sub not defined and HTH is highlighted. What did I do wrong? "Ardus Petus" wrote: With Sheets(("ICS 214") .range("D29:D46").clearcontents .copy befo= Sheets(2) end with HTH -- AP "EAHRENS" a écrit dans le message de ... I am running the following macro to add an additional sheet. Sheets("ICS 214").Select Sheets("ICS 214").Copy Befo=Sheets(2) ' End Sub The problem I have is it copies over some information from unlocked cells that I would like to have blank on the new sheet. What can i add to the macro to have it copy the original sheet and automatically clear a group of cells such as d29-d46? |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Copy from WORD to EXCEL using a macro..... | Excel Discussion (Misc queries) | |||
Want macro to select & copy cells from a different worksheet | Excel Discussion (Misc queries) | |||
Recorded Macro to Copy Format | Excel Worksheet Functions | |||
Closing File Error | Excel Discussion (Misc queries) | |||
Activate a macro to insert a row and copy the formuals from the rows above to the blank row | Excel Discussion (Misc queries) |