On Wednesday 16 August 2006 08:37, Victor Warner wrote: > Are you writing that I should be using two fields? One to contain the > first letter, and the second to contain the formula and post the resulting > text matching the letter?
Well, one problem here is that the single-letter text the user enters doesn't always match the first letter of the big string. And worse, some times the first letter of the big string is found elsewhere on the single-letter list. For instance, of the user enters 'X', that yields a big string that starts with 'O'. But 'O' is also on the single-letter list. To avoid all these problems, you could use two fields. One could be called the Code Field. It's a U1 field that has the following formula: eld with this formula: P3F3 CASES CASE CV ="A" OF "A" ENDOF CASE CV ="C" OF "C" ENDOF CASE CV ="D" OF "D" ENDOF CASE CV ="L" OF "L" ENDOF CASE CV ="O" OF "O" ENDOF CASE CV ="R" OF "R" ENDOF CASE CV ="X" OF "X" ENDOF DEFAULT "" ENDCASES Note that in the above formula, what the user enter never changes to a different letter, unless they enter something other than ACDLORX, in which case the field blanks. Then the next field would have this formula, which references the user entry in the above field: P3F3 CASES CASE CV ="A" OF "Apostille" ENDOF CASE CV ="C" OF "Certificate of Good Standing" ENDOF CASE CV ="D" OF "Print off documents at Companies House" ENDOF CASE CV ="L" OF "Legalisation service provided by agent" ENDOF CASE CV ="O" OF "Basic internet available info from Companies House" ENDOF CASE CV ="R" OF "Recorded Mail" ENDOF CASE CV ="X" OF "Other legalisation" ENDOF DEFAULT "" ENDCASES _______________________________________________ Dataperf mailing list [email protected] http://lists.dataperfect.nl/mailman/listinfo/dataperf
