ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Copy Cells/Paste Cells Programatically (https://www.excelbanter.com/excel-programming/371704-copy-cells-paste-cells-programatically.html)

Brig Siton

Copy Cells/Paste Cells Programatically
 
I have a table that looks like the one below

Date Invoice Discount
8/1/06 $100 $20
8/2/06 $200 $40
8/3/06 $300 $80
8/4/06 $400 $160
8/5/06
....
8/31/06

The Invoice column and Discount columns are Dollar amounts that changes
daily.

Its getting its values from another excel sheet. The problem is that this
excel sheet is not driven by dates or any uniform database format. The
figures in this excel shee are manuall entered by users and gets totaled at
the end of the day. These totals represents the Invoice and Discount for
the day. The totals are in fixed, stagnant cells so this one is quite easy
to refer to.

What we want to achieve is that in a daily basis, we run a macro that will
copy the totals to this table that we create and paste the values into the
same date when they run the macro. If they missed running it on that day,
the macro will skip that day.

Let me know if this is something that is doable in excel.

Thank you.





Die_Another_Day

Copy Cells/Paste Cells Programatically
 
I'm not sure I completely understand what you want to do but it does
sound doable. Try this for starters:
Sub MoveStuff()
'Macro Written 8/29/2006 by cchickering
Sheets("TotalsSheet").Range("A1:B1").Copy Sheets("Summary").Range("A" _
& Sheets("Summary").Rows.Count).End(xlUp).Offset(1,1 )
Sheets("Summary").Range("A" & Sheets("Summary").Rows.Count).End(xlUp).
_
Offset(1,0) = Date
End Sub

This copies the Invoice and Discount amounts from the sheet
"TotalsSheet" Ranges A1 and B1 to the end of sheet "Summary", columns B
& C and adds today's date in Column A.

Let me know if you need more help

Charles

Brig Siton wrote:
I have a table that looks like the one below

Date Invoice Discount
8/1/06 $100 $20
8/2/06 $200 $40
8/3/06 $300 $80
8/4/06 $400 $160
8/5/06
...
8/31/06

The Invoice column and Discount columns are Dollar amounts that changes
daily.

Its getting its values from another excel sheet. The problem is that this
excel sheet is not driven by dates or any uniform database format. The
figures in this excel shee are manuall entered by users and gets totaled at
the end of the day. These totals represents the Invoice and Discount for
the day. The totals are in fixed, stagnant cells so this one is quite easy
to refer to.

What we want to achieve is that in a daily basis, we run a macro that will
copy the totals to this table that we create and paste the values into the
same date when they run the macro. If they missed running it on that day,
the macro will skip that day.

Let me know if this is something that is doable in excel.

Thank you.



Brig Siton

Copy Cells/Paste Cells Programatically
 
Thank you.

Will give it a shot and let you know if it works.

Brigham

"Die_Another_Day" wrote in message
oups.com...
I'm not sure I completely understand what you want to do but it does
sound doable. Try this for starters:
Sub MoveStuff()
'Macro Written 8/29/2006 by cchickering
Sheets("TotalsSheet").Range("A1:B1").Copy Sheets("Summary").Range("A" _
& Sheets("Summary").Rows.Count).End(xlUp).Offset(1,1 )
Sheets("Summary").Range("A" & Sheets("Summary").Rows.Count).End(xlUp).
_
Offset(1,0) = Date
End Sub

This copies the Invoice and Discount amounts from the sheet
"TotalsSheet" Ranges A1 and B1 to the end of sheet "Summary", columns B
& C and adds today's date in Column A.

Let me know if you need more help

Charles

Brig Siton wrote:
I have a table that looks like the one below

Date Invoice Discount
8/1/06 $100 $20
8/2/06 $200 $40
8/3/06 $300 $80
8/4/06 $400 $160
8/5/06
...
8/31/06

The Invoice column and Discount columns are Dollar amounts that changes
daily.

Its getting its values from another excel sheet. The problem is that
this
excel sheet is not driven by dates or any uniform database format. The
figures in this excel shee are manuall entered by users and gets totaled
at
the end of the day. These totals represents the Invoice and Discount for
the day. The totals are in fixed, stagnant cells so this one is quite
easy
to refer to.

What we want to achieve is that in a daily basis, we run a macro that
will
copy the totals to this table that we create and paste the values into
the
same date when they run the macro. If they missed running it on that
day,
the macro will skip that day.

Let me know if this is something that is doable in excel.

Thank you.






All times are GMT +1. The time now is 01:35 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com