Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Cross reference summation and offset <- sorry can't think of better way to describe!

Hi - its kind of hard to explain this one in a subject.

Basically I need some help to write a macro to perform the following
pls:

Data is in following format:

Account Ref Cost CrossRef Comment
------- --- ---- --------
--------
1 QTIM 100 Football
1 QTIM 100 Football
2 Football -200 QTIM
1 QPHIL 2000 Chocolate
2 Chocolate -1000 QPHIL
2 Chocolate -2000 QPHIL
1 QPETE -500 Horse
1 QPETE 500 Horse

What I am looking to do is to identify where a unique ref's total cost
(e.g. QTIM's total 200) is offset by corresponding equal and opposite
entry that matches its crossRef and is on account other than its own
(there are only 2 accounts).
For example QTIM has total cost of 200 with crossref Football (all
crossrefs for QTIM will always be Football- it is unique to the ref).
There is a football entry on account 2 that offsets the 200 with -200
making it zero. I'd like to indentify this and copy something similar
to another sheet and add a constant comment (e.g. "Clear") to the
original worksheet.

Acc Ref TotalCost OffsetAcc OffsetRef OffsetCost

1 QTIM 200 2 Football -200


Not entirely sure the best practice to get this done efficiently. I
have made a script that so far sorts the data in Ref order so that all
refs are next to each other. Any help, direction would be very much
appreciated.
Thanks
Will

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 459
Default Cross reference summation and offset <- sorry can't think of better way to describe!

wrote:
Hi - its kind of hard to explain this one in a subject.

Basically I need some help to write a macro to perform the following
pls:

Data is in following format:

Account Ref Cost CrossRef Comment
------- --- ---- --------
--------
1 QTIM 100 Football
1 QTIM 100 Football
2 Football -200 QTIM
1 QPHIL 2000 Chocolate
2 Chocolate -1000 QPHIL
2 Chocolate -2000 QPHIL
1 QPETE -500 Horse
1 QPETE 500 Horse

What I am looking to do is to identify where a unique ref's total cost
(e.g. QTIM's total 200) is offset by corresponding equal and opposite
entry that matches its crossRef and is on account other than its own
(there are only 2 accounts).
For example QTIM has total cost of 200 with crossref Football (all
crossrefs for QTIM will always be Football- it is unique to the ref).
There is a football entry on account 2 that offsets the 200 with -200
making it zero. I'd like to indentify this and copy something similar
to another sheet and add a constant comment (e.g. "Clear") to the
original worksheet.

Acc Ref TotalCost OffsetAcc OffsetRef OffsetCost

1 QTIM 200 2 Football -200


Not entirely sure the best practice to get this done efficiently. I
have made a script that so far sorts the data in Ref order so that all
refs are next to each other. Any help, direction would be very much
appreciated.
Thanks
Will


Hi Will,

I think the best way should be split the rows of the two accounts on to two
separate sheets, then with SUMIF you can sum on the two sheets and then with
VLOOKUP you can check the crossreferences and their sums...


--
Hope I helped you.

Thanks in advance for your feedback.

Ciao

Franz Verga from Italy


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6
Default Cross reference summation and offset <- sorry can't think of better way to describe!

Thanks - so I get to the stage where I have two dynamically created
worksheets each with entries for each account. How do I go about using
SUMIF to get each ref's total?


Franz Verga wrote:
wrote:
Hi - its kind of hard to explain this one in a subject.

Basically I need some help to write a macro to perform the following
pls:

Data is in following format:

Account Ref Cost CrossRef Comment
------- --- ---- --------
--------
1 QTIM 100 Football
1 QTIM 100 Football
2 Football -200 QTIM
1 QPHIL 2000 Chocolate
2 Chocolate -1000 QPHIL
2 Chocolate -2000 QPHIL
1 QPETE -500 Horse
1 QPETE 500 Horse

What I am looking to do is to identify where a unique ref's total cost
(e.g. QTIM's total 200) is offset by corresponding equal and opposite
entry that matches its crossRef and is on account other than its own
(there are only 2 accounts).
For example QTIM has total cost of 200 with crossref Football (all
crossrefs for QTIM will always be Football- it is unique to the ref).
There is a football entry on account 2 that offsets the 200 with -200
making it zero. I'd like to indentify this and copy something similar
to another sheet and add a constant comment (e.g. "Clear") to the
original worksheet.

Acc Ref TotalCost OffsetAcc OffsetRef OffsetCost

1 QTIM 200 2 Football -200


Not entirely sure the best practice to get this done efficiently. I
have made a script that so far sorts the data in Ref order so that all
refs are next to each other. Any help, direction would be very much
appreciated.
Thanks
Will


Hi Will,

I think the best way should be split the rows of the two accounts on to two
separate sheets, then with SUMIF you can sum on the two sheets and then with
VLOOKUP you can check the crossreferences and their sums...


--
Hope I helped you.

Thanks in advance for your feedback.

Ciao

Franz Verga from Italy


  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6
Default Cross reference summation and offset <- sorry can't think of better way to describe!

Anybody have a couple of minutes to help me out on this, bit of a
beginner over here :)


wrote:
Thanks - so I get to the stage where I have two dynamically created
worksheets each with entries for each account. How do I go about using
SUMIF to get each ref's total?


Franz Verga wrote:
wrote:
Hi - its kind of hard to explain this one in a subject.

Basically I need some help to write a macro to perform the following
pls:

Data is in following format:

Account Ref Cost CrossRef Comment
------- --- ---- --------
--------
1 QTIM 100 Football
1 QTIM 100 Football
2 Football -200 QTIM
1 QPHIL 2000 Chocolate
2 Chocolate -1000 QPHIL
2 Chocolate -2000 QPHIL
1 QPETE -500 Horse
1 QPETE 500 Horse

What I am looking to do is to identify where a unique ref's total cost
(e.g. QTIM's total 200) is offset by corresponding equal and opposite
entry that matches its crossRef and is on account other than its own
(there are only 2 accounts).
For example QTIM has total cost of 200 with crossref Football (all
crossrefs for QTIM will always be Football- it is unique to the ref).
There is a football entry on account 2 that offsets the 200 with -200
making it zero. I'd like to indentify this and copy something similar
to another sheet and add a constant comment (e.g. "Clear") to the
original worksheet.

Acc Ref TotalCost OffsetAcc OffsetRef OffsetCost

1 QTIM 200 2 Football -200


Not entirely sure the best practice to get this done efficiently. I
have made a script that so far sorts the data in Ref order so that all
refs are next to each other. Any help, direction would be very much
appreciated.
Thanks
Will


Hi Will,

I think the best way should be split the rows of the two accounts on to two
separate sheets, then with SUMIF you can sum on the two sheets and then with
VLOOKUP you can check the crossreferences and their sums...


--
Hope I helped you.

Thanks in advance for your feedback.

Ciao

Franz Verga from Italy


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
Cross Reference fgwiii[_2_] Excel Worksheet Functions 1 July 21st 09 05:06 PM
cross reference damegood New Users to Excel 1 July 7th 09 05:18 PM
Cross reference Edward[_3_] Excel Discussion (Misc queries) 7 November 10th 08 08:42 AM
cross reference two auntieb New Users to Excel 3 September 8th 08 05:17 PM
Cross reference LaRana! Excel Worksheet Functions 1 March 6th 08 12:22 AM


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