10-05-2017 01:52 PM
Hello .
In my project i created a user interface where the user chooses multiple images.
Then there is a button "attach files" . Basically when the user presses this button i want an indicator of all those pictures to popup in a new window.(he will then choose for example an image that he wants another file to be "attached" to it ( I'll just keep track of the index of the chosen image ).
So i don't want the indicator to be part of the main vi front panel.Instead i want it to have it's own separate window.
I'd appreciate your help.
Solved! Go to Solution.
10-05-2017 01:58 PM
10-05-2017 02:21 PM - edited 10-05-2017 02:24 PM
Here's an image of how the project looks.
From what i understand from your answer, i should turn the part encircled with red into a subvi ?
Should i do this in the current project, or create a new vi and then drop it in my main project?
edit: i forgot to mention that the subVi that you see inside the for loop is just resizing the images
10-05-2017 02:43 PM
ok, turns out i had to create the subVI as a new VI and then drop it in the original.
Thanks
10-05-2017 02:46 PM
That looks rather incomplete (e.g. no while loop, etc.). All the popup VI needs to have is an indicator for an array of pictures and some wait and UI code. Do you always have exactly four pictures? Is the user supposed to be able to interact with the popup, e.g. click on one of the images? Cancel it?
What does the button have to do with "audio files"? What's in the other cases? What is the overall program architecture?
10-05-2017 02:47 PM
@johnvoyager wrote:
ok, turns out i had to create the subVI as a new VI and then drop it in the original.
Why?
10-05-2017 03:03 PM - edited 10-05-2017 03:20 PM
@altenbach wrote:
That looks rather incomplete (e.g. no while loop, etc.). All the popup VI needs to have is an indicator for an array of pictures and some wait and UI code. Do you always have exactly four pictures? Is the user supposed to be able to interact with the popup, e.g. click on one of the images? Cancel it?
What does the button have to do with "audio files"? What's in the other cases? What is the overall program architecture?
First of all sorry, i am fairly inexperienced with LabView .
Yes the project is still very incomplete. So let me describe it with more details:
Main VI : has a choose images button and an "attach audio/video files". When he presses the first button he is given the ability to choose multiple images.Then i want the user to be able to associate some multimedia files with some of the above images. So when he presses the "attach audio/video files" button, i want a popup window where all the previously chosen images will be shown. Then when he clicks on an image, another file selector will appear , with which he will choose some multimedia files to associate with the image.
edit : number of pictures is not fixed, although i'll set a maximum number ( about 15-20 )
edit2: as for the way the images will be shown i was thinking of turning them into thumbnails( thus the need to resize ) and then showing them like a list ,either 1 column N rows, or 2 columns N rows (in second case some math will be needed ).
10-05-2017 03:07 PM - edited 10-05-2017 03:14 PM
@altenbach wrote:
@johnvoyager wrote:
ok, turns out i had to create the subVI as a new VI and then drop it in the original.
Why?
when i turned the part of the code into a subvi while still on the main vi i couldn't get a separate front panel to show up. when i created a new vi which obviously had its own front panel , copy pasted the code there, then dropped it in the main VI managed to get it to show its separate front panel.
I am very sorry if i mislead other users. I don't know if that was really the reason why it worked . I have a long way to go, i asked for help because i really had no idea how to get it to work as a popup.
edited: vain-->VI
10-05-2017 03:27 PM