Subject: | |
From: | |
Reply To: | |
Date: | Tue, 26 Sep 2000 14:30:01 -0700 |
Content-Type: | text/plain |
Parts/Attachments: |
|
|
[log in to unmask] wrote:
> My Salaam to all,
>
> The possible combinations of values for a particular variable TEMPVAR could
> be as follows:
>
> 1. TEMPVAR = "[log in to unmask]"
> 2. TEMPVAR = "@.GROUP2.ACCT2@"
> 3. TEMPVAR = "@[log in to unmask]"
> 4. TEMPVAR = "[log in to unmask]@.ACCT4@"
>
> How do I break this up into 3 different variable TEMPVAR1, TEMPVAR2,
> TEMPVAR3 such that the results should be as follows:
>
> 1. TEMPVAR1 = "AI@J", TEMPVAR2 = "GROUP1", TEMPVAR3 = "ACCOUNT1"
> 2. TEMPVAR1 = "@", TEMPVAR2 = "GROUP2", TEMPVAR3 = "ACCT2@"
> 3. TEMPVAR1 = "@J", TEMPVAR2 = "GRP3@", TEMPVAR3 = "ACCOUNT3"
> 4. TEMPVAR1 = "AI@", TEMPVAR2 = "GRP4@", TEMPVAR3 = "ACCT4@"
>
You could use the 'pos' command to set the length of each portion of the string
being tested.
e.i. setvar p1 pos(".","!tempvar")
setvar p2 pos(".","!tempvar",2) second period
setvar tempvar1 "!tempvar"[0:!p1-1]
setvar tempvar2 "!tempvar"[!p1+1:!p2-!p1]
setvar tempvar 3 "!tempvar[!p2+1:![len("!tempvar")]-!p2]
I have used something similar to this in the past, I'm not sure of the correct
syntax but this will get you into the ball park I believe. I would test this
but I have a frame circuit doing the yo-yo routine.
--
Larry Barnes
Director of I.T.
Mitek Corp.
602-438-4545 x1366
Phoenix, AZ 85040
Check Us Out !
http://www.mitekcorp.com
|
|
|