Jump to content

Passing Control References to Sub VI


Recommended Posts

The attached vi [Testsubvi].vi works OK by itself, but when used as a sub vi to 'TestDirectoryTree3.vi', I am unable to pass the control references to the sub vi.

Notwithstanding much effort, I still cannot find the error, and would appreciate any help.

The purpose of the code is to have the user select or create a root directory, and a directory tree and its folders is then generated automatically.

Regards, GraemeJ

Link to comment

I haven't tested the VI, but I see you are waiting events for refnum value changes. The refnum value won't change until the reference is disposed, since is just the memory address. I think you are looking for a value change event and, in addition, don't use events in the subVI but in the top VI since it's there where the controls are.

Saludos,

Aitor

Link to comment

QUOTE (Aitor Solar @ Sep 19 2008, 06:23 PM)

I haven't tested the VI, but I see you are waiting events for refnum value changes. The refnum value won't change until the reference is disposed, since is just the memory address. I think you are looking for a value change event and, in addition, don't use events in the subVI but in the top VI since it's there where the controls are.

Saludos,

Aitor

Thanks for your help Aitor. The modified VI's are attached and seem to work.

I have posted them again in case they might of use to someone.

Regards, GraemeJ

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.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  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...

Important Information

By using this site, you agree to our Terms of Use.