Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 44
Default How to get the latest data from a workbook

Hi,
I usually download the receipt data from oracle database in excel
spreadsheet say Workbook 1.
At present the data is almost about 40000 rows & will be increased as the
days passes. It is the data of goods received from 1st April to Till date.
The database Fields are like
Col.A Col.B Col.C Col.D Col.E
Goods Recepit Note No. Recpt Date Item Code Recd. Qty Unit Rate
Col.F Col.G Col.H
Basic Value Grand Total Supplier Name
I have another worksheet which contents master item list say Workbook 2.
The Master Item List - Fields are like
Col. A Col.B Col.C
Item Code Description Basic Rate(answer would be latest purchased unit
rate from workbook1)
Col.D Col.E
Rate as on (answer would be GRN Date) Ref. No. (answer would be GRN No.)
Col. F
Cumulative Basic Value (The Answer would be running total of Basic Value
field as on latest date)
If any particular Item Code has not been purchased on any particular date
the answers would be get from the
previous / last receipt date for that particular item and so on.
The List of Items is almost 500 rows.
Now I wish the pull the latest data from workbook 1 in resp. col. of C,D,E,F,G
The dat or values in Col.A & Col.B of workbook2 are fixed.
Could anybody write the code to get the desired results.
Thanks in advance.
--
Thanks,
Vikram P. Dhemare
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 510
Default How to get the latest data from a workbook


Hi,

LastRow = Cells(Cells.Rows.Count,"A").End(xlUp).Row
would give you the integer representing the last row used in column A

LastRowValue = Cells(LastRow,1).Value
would give you the Value of the last cell in column A ( 1 represents
first column, i.e A )

HTH
Cheers
Carim

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 44
Default How to get the latest data from a workbook

Hi Carim,

Actually I do not want the last row value or cell value, I want to retrieve
the data from latest or last updated data.
Say - If Item 'A' being purchased on 13/10/2006 at $1500 /-
and the same item purchased on previous date (i.e 12/10/2006) at $ 1600/-
In this case, the result in master workbook should be

Item description Rate Rate as on
A Matl. $1500/- 13/10/2006 (i.e. the data from latest
purchased date).

Items & Description columns are the fixed or say master list & col. c
onwards should be the desired answers.
Hope this make sense.



--
Thanks,
Vikram P. Dhemare


"Carim" wrote:


Hi,

LastRow = Cells(Cells.Rows.Count,"A").End(xlUp).Row
would give you the integer representing the last row used in column A

LastRowValue = Cells(LastRow,1).Value
would give you the Value of the last cell in column A ( 1 represents
first column, i.e A )

HTH
Cheers
Carim


  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 510
Default How to get the latest data from a workbook

Hi,

Have a go with following array formula : (to be entered with
Control+Shift+Enter)

=MAX(IF(($A$1:$A$4000=A1),$D$1:$D$4000))

Provided your items in column A and your dates in column D

HTH
Cheers
Carim

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
Latest Taxation Books available at jain book depot LATEST BOOKRELEASES JACK ANDERSON Excel Worksheet Functions 0 May 29th 10 01:25 PM
Copy latest date from one workbook to another Meltad Excel Programming 23 September 21st 06 12:10 PM
Copying latest date from weekly workbook Meltad Excel Programming 12 September 13th 06 01:26 AM
Using Macro to copy latest data from one Workbook to another Kayote[_5_] Excel Programming 1 June 13th 06 07:01 PM
Locating Latest Workbook teresa Excel Programming 1 December 12th 04 08:43 PM


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