Jump to content
Developer Wiki and Function Reference Links ×

DImensions do not update when the object is reset from a external script.


Musisback

Recommended Posts

Hello,

I use PIO's that are modified by external scripts.

It works fine except for the associated dimensions.

Those do not update when the PIO does if it is modified by an external script.

However, if I modify it myself (with the Object info palette) it works normally.

Here is a example to make it clearer.

My PIO:

PROCEDURE Myrect;
BEGIN;
rect(0,0,PW,PH);
END;
run(Myrect);

If I add dimensions to a corner to another and if modify the PIO with the object info palette, the dimensions update.

If I modify it with a script:

setrfield(LSActLayer,getname(getrecord(LSActLayer,1)),'W', '300');	
setrfield(LSActLayer,getname(getrecord(LSActLayer,1)),'H', '300');	
resetobject(LSactlayer);

they do not update...

Does anyone know how to avoid this problem?

Thanks

Link to comment

Why is that?

It works just fine in most cases.

- 2D reshape the PIO

- Control points picking and dragging

- Changing parameter in the object info palette

.....

The only way it doesn't work is when it is modify by another script.

And still, if after updating it from a script, the dimension does not update right away , it does when I move or change anything from the PIO.

Link to comment

For path PIO's, the different verticles are recognize with there index.

I think also that the other sub-objects are recognized by there stacking order. (starting of front);

After lots of trouble not understanding it. I finally got why sometimes the same PIO would keep its dimension associated and why sometimes not : it was because the number of sub-object changed. (and then the stacking order)

I also noticed that it does not work with rectangle POI's and only on the 2 points defining the line for line PIO's. It works fine for path and point PIO's.

Why that?? No idea.

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...