spartacus
19th July 2007, 11:07
Hi all,

does anybody know, to which table "attr.rotate" actually is pointing? "BaanHelp" writes something about "currency table"! Is that tcmcs002? I don't think so, because I tried it with "tfacp100.amth" and get no "out of range" for the index. "tfacp100.amth" is an array of three fields. tcmcs002 has much more entries than 3? I can't imagine that there is a relation.
IMO there could be a relation to the fields "local currency", "report currency1" and "report currency2" in tcemm170!?

madan.meegada
19th July 2007, 19:03
In Baan Help it is not mentioned that attr.rotate is directly linked with tcmcs002 table. There is no relation between tcmcs002 and attr.rotate. In fact, Baan Help says as follows: "Use this function to create and fill the multicurrency table". As per my knowledge, attr.rotate is linked with tcemm170 values.

Leerkes
20th July 2007, 11:16
Hi there,

In sessions where you have a multi currency field, you can switch on the standard command for rotating the currencies.
Tools keeps track of an internal array, which you should fill yourself in preferably the before.program section.
This internal array is filled with the function set.currencies(), see the programmer's manual for a good explanation.
Note that most tcemm.dll5000 functions which determine the home currencies of a certain company (tcemm170) always internally call the tool's function set.currencies(), so that this array is filled and can be used in the UI script.

The variable attr.rotate is filled with the current array number and the variable attr.currency$ is filled with the currency code on that position.

Regards,
Michiel

madan.meegada
23rd July 2007, 12:30
Thanks for the detailed explaination Michiel.

Regards,
Madan.

spartacus
23rd July 2007, 16:51
Hi Michiel,

thanks for your support. So I think the table which Baan uses for that ist tcemm170.

But is there a standard command for rotating currencies? Are you sure, that is also on Baan 5?

Leerkes
25th July 2007, 09:18
Hi,

Also in Baan5 this works the same. On a form you can switch on the standard command for rotating currency. The form field itself needs to have the element set to -1. After this the rotate currency command is enabled.
The tools function set.currencies() works also the same. Attr.currency$ gives the currency code on the current position in the array and attr.rotate gives the position in that array.
Normally all tcemm functies will call the set.currencies function for you and the array is filled with the home currencies from tcemm170.

Regards,
Michiel

spartacus
30th July 2007, 10:33
Ahhh OK OK!!

I see, you mean the "standard command: rotate.curr" not one of the commands in ttadv3110s000 (standard commands for the form)!

OK thanks a lot,
Richard