Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 68
Default Macro - copy and paste value

When i downloaded the detailed suppliers invoices from my accounting
software, the layout is:
Supplier name in column B (only shown once on top of all the invoices
outstanding)
Invoice detail in column C, D, E & F (details shown immediately after the
supplier name in Column B)

The list is for all suppliers.

Is there any macro can be used to copy the supplier name and paste down
wards so that i can use sumif function to get detailed aging report based on
the invoice date in column C.

The macro should be able to recognised different suppliers name i.e. row 23
is Supplier A name and its related details run from row 24 to row 56 and
supplier B name at row 57 and details run from row 58 to row 80.

This macro should be able to copy supplier A from row 23 in column A and
paste from row 24 to 56 in column A. Then copy supplier B name in row 57 in
column A, paste from row 58 to row 80.

Hopefully this is not too confusing! :-)
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,520
Default Macro - copy and paste value

Howard, you have mentioned that 'Supplier name in column B '. Towards the end
of your description you have again mentioned that "supplier A from row 23 in
column A"

I am assuming you have your supplier name in ColumnB. You really dont need a
macro to do this, However both solutions are given.

Sub MyMacro()
Dim lngRow As Long
For lngRow = 2 To Cells(Rows.Count, "C").End(xlUp).Row
If Trim(Range("B" & lngRow)) = "" Then _
Range("B" & lngRow) = Range("B" & lngRow - 1)
Next
End Sub



1. Select the data range in ColA (say B1:B100).
2. Press F5. From 'Goto window'Special from Options select 'Blanks' and
hit OK
3. This will select all blanks.
4. Now press = (equal sign)
5. Then press Up Arrow to reference the cell just above
6. Now press Ctrl and Enter key together


If this post helps click Yes
---------------
Jacob Skaria


"Howard" wrote:

When i downloaded the detailed suppliers invoices from my accounting
software, the layout is:
Supplier name in column B (only shown once on top of all the invoices
outstanding)
Invoice detail in column C, D, E & F (details shown immediately after the
supplier name in Column B)

The list is for all suppliers.

Is there any macro can be used to copy the supplier name and paste down
wards so that i can use sumif function to get detailed aging report based on
the invoice date in column C.

The macro should be able to recognised different suppliers name i.e. row 23
is Supplier A name and its related details run from row 24 to row 56 and
supplier B name at row 57 and details run from row 58 to row 80.

This macro should be able to copy supplier A from row 23 in column A and
paste from row 24 to 56 in column A. Then copy supplier B name in row 57 in
column A, paste from row 58 to row 80.

Hopefully this is not too confusing! :-)

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 68
Default Macro - copy and paste value

Dear Jacob,

This is very useful and on the GOTO Special function, is there any resource
that i can read up to understand the logic on how excel work on this.

Thanks A loT!

"Jacob Skaria" wrote:

Howard, you have mentioned that 'Supplier name in column B '. Towards the end
of your description you have again mentioned that "supplier A from row 23 in
column A"

I am assuming you have your supplier name in ColumnB. You really dont need a
macro to do this, However both solutions are given.

Sub MyMacro()
Dim lngRow As Long
For lngRow = 2 To Cells(Rows.Count, "C").End(xlUp).Row
If Trim(Range("B" & lngRow)) = "" Then _
Range("B" & lngRow) = Range("B" & lngRow - 1)
Next
End Sub



1. Select the data range in ColA (say B1:B100).
2. Press F5. From 'Goto window'Special from Options select 'Blanks' and
hit OK
3. This will select all blanks.
4. Now press = (equal sign)
5. Then press Up Arrow to reference the cell just above
6. Now press Ctrl and Enter key together


If this post helps click Yes
---------------
Jacob Skaria


"Howard" wrote:

When i downloaded the detailed suppliers invoices from my accounting
software, the layout is:
Supplier name in column B (only shown once on top of all the invoices
outstanding)
Invoice detail in column C, D, E & F (details shown immediately after the
supplier name in Column B)

The list is for all suppliers.

Is there any macro can be used to copy the supplier name and paste down
wards so that i can use sumif function to get detailed aging report based on
the invoice date in column C.

The macro should be able to recognised different suppliers name i.e. row 23
is Supplier A name and its related details run from row 24 to row 56 and
supplier B name at row 57 and details run from row 58 to row 80.

This macro should be able to copy supplier A from row 23 in column A and
paste from row 24 to 56 in column A. Then copy supplier B name in row 57 in
column A, paste from row 58 to row 80.

Hopefully this is not too confusing! :-)

  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,520
Default Macro - copy and paste value

Thanks for the feedback. I don't have any articles/link as such to refer
other than googling. May be search for "Excel GoTo Dialog".Cheers

"Howard" wrote:

Dear Jacob,

This is very useful and on the GOTO Special function, is there any resource
that i can read up to understand the logic on how excel work on this.

Thanks A loT!

"Jacob Skaria" wrote:

Howard, you have mentioned that 'Supplier name in column B '. Towards the end
of your description you have again mentioned that "supplier A from row 23 in
column A"

I am assuming you have your supplier name in ColumnB. You really dont need a
macro to do this, However both solutions are given.

Sub MyMacro()
Dim lngRow As Long
For lngRow = 2 To Cells(Rows.Count, "C").End(xlUp).Row
If Trim(Range("B" & lngRow)) = "" Then _
Range("B" & lngRow) = Range("B" & lngRow - 1)
Next
End Sub



1. Select the data range in ColA (say B1:B100).
2. Press F5. From 'Goto window'Special from Options select 'Blanks' and
hit OK
3. This will select all blanks.
4. Now press = (equal sign)
5. Then press Up Arrow to reference the cell just above
6. Now press Ctrl and Enter key together


If this post helps click Yes
---------------
Jacob Skaria


"Howard" wrote:

When i downloaded the detailed suppliers invoices from my accounting
software, the layout is:
Supplier name in column B (only shown once on top of all the invoices
outstanding)
Invoice detail in column C, D, E & F (details shown immediately after the
supplier name in Column B)

The list is for all suppliers.

Is there any macro can be used to copy the supplier name and paste down
wards so that i can use sumif function to get detailed aging report based on
the invoice date in column C.

The macro should be able to recognised different suppliers name i.e. row 23
is Supplier A name and its related details run from row 24 to row 56 and
supplier B name at row 57 and details run from row 58 to row 80.

This macro should be able to copy supplier A from row 23 in column A and
paste from row 24 to 56 in column A. Then copy supplier B name in row 57 in
column A, paste from row 58 to row 80.

Hopefully this is not too confusing! :-)

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
Copy and Paste Macro Schwimms Excel Discussion (Misc queries) 1 February 4th 09 05:10 PM
using macro to copy paste ramzi Excel Discussion (Misc queries) 4 January 29th 09 09:05 AM
macro to copy and paste estella Excel Discussion (Misc queries) 1 May 16th 08 04:43 AM
Copy and Paste using macro [email protected] Excel Discussion (Misc queries) 0 February 8th 07 09:47 AM
Should I use a macro to copy and paste value? Rebecca Excel Worksheet Functions 0 April 6th 06 10:03 PM


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