On 07/26/10 13:06, Terry McFall wrote:
> Somebody must have run across this situation before…
>
> We’re migrating IL 3.4 to PDML and need to create a parameter in each part having a value equal to the part’s name. The problem is our parts have a dash symbol (xxxxxx-xx) and we must remove it to
> match the equivalent name in SAP.
>
> Our brute force solution is pretty brutal… hiring an intern to manually enter a IL/ProE parameter value equal to the part no. but w/out the dash.
>
> Is there a way to script the value of a parameter as being equal to the filename minus one character?
Several options:
1. jlink
or
2. weblink
or
3. relations
ie
Assuming you have filename = 12345-xy and you want partno = 12345xy
beforeDash = extract(rel_model_name(), 1, search(rel_model_name(), "-") - 1)
afterDash = extract(rel_model_name(), search(rel_model_name(), "-") + 1, string_length(rel_model_name()) - search(rel_model_name(), "-")
partno = beforeDash + afterDash
>
> -Ter
>
> Terrence (Terry) McFall
> CAD Systems Administrator
>
> Varian Medical Systems
> 911 Hansen Way
> Palo Alto, CA 94304
> 650-424-6039 desk
> 650-799-0179 cell
--
------------------------------------------------------------------------
Randy Jones
Systems Administrator
Great Plains Mfg., Inc.
1525 E North St
PO Box 5060
Salina, KS USA 67401
email: -
Phone: 785-823-3276
Fax: 785-667-2695
------------------------------------------------------------------------