Hello!
I have a table called "Invoice".
Inside it i have the fields "Code", "Dep" and "Account".
In the "code" field I either type a two caracter number or a eight caracter number. I.e. "77", "34" or "32090123", "50112112".
The "Dep" field uses the function "left" to find the two first caracters. I.e: "Code"="73159112" = "Dep"="73" or "Code"="34" = "Dep"="34".
Then comes my problem;
If I type "34" or "35" or "77" in the "code" field the "Account" should say "43430".
If I type a number between "34000000" and "34999999" or between "35000000" and "35999999" or "77000000" and "77999999" the "Account" field should say "22343"
Else the "Account" field should say "50111".
I have tryed several settings, but somehow it will not work, so I need your help...
Regards
Christian
I have a table called "Invoice".
Inside it i have the fields "Code", "Dep" and "Account".
In the "code" field I either type a two caracter number or a eight caracter number. I.e. "77", "34" or "32090123", "50112112".
The "Dep" field uses the function "left" to find the two first caracters. I.e: "Code"="73159112" = "Dep"="73" or "Code"="34" = "Dep"="34".
Then comes my problem;
If I type "34" or "35" or "77" in the "code" field the "Account" should say "43430".
If I type a number between "34000000" and "34999999" or between "35000000" and "35999999" or "77000000" and "77999999" the "Account" field should say "22343"
Else the "Account" field should say "50111".
I have tryed several settings, but somehow it will not work, so I need your help...
Regards
Christian