user defined expression in an UDF
user defined expression in an UDF
(OP)
I'm looking for a solution in an UDF. If created an hole feature and want to defined the values with userdefined expression with if else if structures:
my new expression:
m=10
the first feature expressions
p5= if (m=3) (3.5) else if (m=4) (4.5) etc.
p6= if (m=3) (6) else if (m=4) (8) etc.
.
.
.
question:
how can I get this work in an UDF
how can I define userdefined expression not shown in the UDF wizard in / into an UDF
thx in ad
my new expression:
m=10
the first feature expressions
p5= if (m=3) (3.5) else if (m=4) (4.5) etc.
p6= if (m=3) (6) else if (m=4) (8) etc.
.
.
.
question:
how can I get this work in an UDF
how can I define userdefined expression not shown in the UDF wizard in / into an UDF
thx in ad





RE: user defined expression in an UDF
You need to include "m" in the UDF creation. Either enter a range or set of values for "m".
Now coming to the value of "m",
If "m" is defined in the file in which u are CALLING udf, then udf will take this value.
If not udf will take the value of "m" that u will select while inserting UDF.
Note that UDF always PREFERS the expressions in the calling part. Suppose in calling part m=2 and while inserting if u have selected m=4 (from the udf dialog), UDF will take the value m=2. To avoid this u can lock the expression (Tools->Expressions->Lock) while u are CREATING UDF.
RE: user defined expression in an UDF
user defined expression in udf's in logic functions do not work. I works only when the expression is set directly in the udf in a parameter
tip to all udf programmers