Trying to work with a multi-value array in LotusScript and sort of stuck

Posted by rrumaner on Stack Overflow See other posts from Stack Overflow or by rrumaner
Published on 2012-04-13T03:46:19Z Indexed on 2012/04/13 5:29 UTC
Read the original article Hit count: 276

Filed under:
|
|

I have to find a way to store a series of variables - MonthYear (the key) and a counter. The purpose of this is to track the number of documents processed by Month & Year. I was thinking of a list but I am not sure how to save the data so that it is readable and able to be shown in a table at a later date. I thought about using a multi-dimensional array - someArray(1,0 to 1) and ReDim'ing it each time I start a new MonthYear and then save it back to a field on the document but am not sure how that is going to play out. Does anyone have an idea of how I can accomplish this?

The first dimension will be the MonthYear (key) and the second will be a counter that is updated every time a new document is processed.

  1. The key will be based on a field on the document being processed. How can I make sure I am updating the right key/counter combination?

  2. How can I retrieve the existing counter from the field on the document, update the counter and then replace the value?

I thought about just adding a new element (ReDim) every time a document is processed and than somehow adding up all the counters for each key and storing that in an array, but that just seems real messy. There has to be a good way to do this.

Any and all ideas will be greatly appreciated

© Stack Overflow or respective owner

Related posts about lotus-notes

Related posts about lotus