ipart.changerow does not work well

ipart.changerow does not work well

skyngu
Collaborator Collaborator
590 Views
7 Replies
Message 1 of 8

ipart.changerow does not work well

skyngu
Collaborator
Collaborator

i am working on a project with ilogic and ipart. (window 7 & 2010 sp3)  i have a table similiar as follow:

                option         length

B-0024N  22-24         46        

B-0026N  25-27         52         

B-0028N   28-30         58  

       

my ilogic code works well with ipart.changrow command. when i select number from different row, such as 22, 25.6, 28....

but when i select number from same row, such as 22, 23, 23.5.....it doesnt work.

 

IF A>=22 AND A<=24 THEN
iPart.ChangeRow("TRACK:1", "B-0024N")

ElseIf A>=25 AND A<=27 THEN
iPart.ChangeRow("TRACK:1", "B-0026N")

ElseIf A>=28 AND A<=30 THEN
iPart.ChangeRow("TRACK:1", "B-0028N")
ENDIF

 

does anyone knows why?

Autodesk Inventor Professional 2019
0 Likes
591 Views
7 Replies
Replies (7)
Message 2 of 8

Anonymous
Not applicable

I tried this in Inventor 2009 with no problem.

Did you stabalize the component name in the Inventor browser?

How are you changing the value of parameter A?

0 Likes
Message 3 of 8

skyngu
Collaborator
Collaborator

thanks for your reply.

yes, i changed the name in browser.

i change value of A by inputing number in ilogic parameter box. it is fine when value of A in different row. there is error when number in same row. the error is "can not find row". such as 22, 22.5, 23....

 

Autodesk Inventor Professional 2019
0 Likes
Message 4 of 8

Anonymous
Not applicable

I used your code and it works for me. Only thing i changed was the parameter name. Inventor did not like me using "A" this is already assigned . I used A1 instead

0 Likes
Message 5 of 8

skyngu
Collaborator
Collaborator
So you can change value 22 then 22.4, then 23??? It seems that inventor can not find the row for next number because they use same row. Any idea?
Autodesk Inventor Professional 2019
0 Likes
Message 6 of 8

skyngu
Collaborator
Collaborator

is there anyone can help me on this? thanks

Autodesk Inventor Professional 2019
0 Likes
Message 7 of 8

Anonymous
Not applicable

As i said it works fine for me. I have attached my files they are INV 2009

0 Likes
Message 8 of 8

skyngu
Collaborator
Collaborator

thanks a lot!

 

i will look into it. I found out the problem may be i am using synergis adept and inventor together.

Autodesk Inventor Professional 2019
0 Likes