-
August 6th, 2009, 10:49 AM
#1
Need Help with Record Selection Formula
Hello Everyone,
I am trying to create a record selection formula which loops through all the selected values in the parameter list and checks whether the parameter values starts with "P-" string.
But, it seems the record selection does not support for loop.
//Not Working with for loop
NumberVar Limit := UBound({?Enter Vendor});
Numbervar Indx ;
For Indx := 1 To Limit Do
(
local StringVar Txt := ToText({?Enter Vendor}[Indx]);
if Txt startswith "P-" Then Txt := Mid (Txt, 3) ;
{vendor.name} = Txt
);
//Working if I select a particular parameter value
if {?Enter Vendor}[1] startswith "P-" Then {vendor.name} = Mid ({?Enter Vendor}[1], 3)
Not sure how to check the string against all selected parameter values. Your help will be greatly appreciated. Thanks a million in advance.
-
August 6th, 2009, 01:51 PM
#2
Re: Need Help with Record Selection Formula
Never tried but :
Code:
if {?Enter Vendor}[1] startswith "P-" Then {vendor.name} = Mid ({?Enter Vendor}[1], 3) Else
if {?Enter Vendor}[2] startswith "P-" Then {vendor.name} = Mid ({?Enter Vendor}[2], 3)
and so on...
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|