LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Scripted Justification of Block Diagram Control Terminals

I was writing some VI Analyzer tests and came up with some behavior that is annoying. When I programmatically modify the justification of the terminal label it doesn't stick when I save the VI.

 

I read Setting Default Label Position and understand the where the label is stuck on the terminal will affect text entry regardless of justification, but it's still annoying.

 

I am wondering if I'm doing something wrong or if this behavior is expected.

Regards,
Dan King

0 Kudos
Message 1 of 6
(2,513 Views)

@Dan_K wrote:

When I programmatically modify the justification of the terminal label it doesn't stick when I save the VI.


What do you mean with "it doesn't stick"?

 

Also, did you look "Move Labels.vi" Quick Drop (CTRL+Space, CTRL+T) in \resource\dialog\QuickDrop\plugins\?

0 Kudos
Message 2 of 6
(2,471 Views)

When the property is changed through scripting and the file is saved the justification of the terminal label doesn't actually change. I can change the justification to the terminal label manually, but when I do so programmatically, it doesn't work.

 

Now, I may be doing something wrong in my VI, but I don't think so.

 

I looked at the Move Labels.vi Quick Drop plugin, but I'm not trying to move the labels in relation to the terminal, just change the text justification from Left to Right.

Regards,
Dan King

0 Kudos
Message 3 of 6
(2,459 Views)

Hi  Dan_K

Only for a recap, you create the Fix BD Terminal Justification.llb ‏42 KB  and when you set the justification of the terminal label and save it, it doesn't change. Only if you do it manually? 

0 Kudos
Message 4 of 6
(2,448 Views)

Sorry, haven't looked at the code jet.

 

Do you wrap the scripting in an undo transaction?

If you leave the VI open and unsaved, does it get a change mark (* behind title)?

When it's open, and you make a manual change and then save, is the justification saved or not?

 

First thing I would try to find out is if the save is ignored (because it thinks there are no changes?) or if the property change is ignored.

 

It does ring a bell somewhere in my head. I think I hear this problem before (years ago), but can't find it. EDIT: Maybe I remembered this bug: 48BCQAXA.

0 Kudos
Message 5 of 6
(2,433 Views)

wiebe@CARYA wrote:

Sorry, haven't looked at the code jet.


It's in 18, I'm still at 17...

0 Kudos
Message 6 of 6
(2,426 Views)