01-10-2011 12:03 AM
Hi miu,
That code will not run now. You will have to implement same idea in your code. Item list would be names of all items.
You may be having list of it. So that user can replace any image.
Idea is like this, You have a folder now which contains current images of food items. Now you/user want to add new image for a particular item.
So he will cal this vi say on a button event. He will select item for which he has new image. Then he will have to select new image path.
when he will click "change" button then old file will be replaced bye new one.
Now you got it?
01-10-2011 12:40 AM
Hi Gak,
Yes I get the whole idea now. But do I have to create some sort of a list first to store the names of the pictures of all the food items before I use the program that you'd given me? And if I do have to create a list, what kind of method can I use to create the list?
Can I just enter the names of all the picture food items using the same method that you did by using the"Item List" method? Will it work?
Miu
01-10-2011 12:56 AM
You don't have list of items?
You can use text file or excel to list down.Then read that file and give strings array to "strings[]" property of text ring.
01-10-2011 01:59 AM
01-10-2011 02:15 AM
Hi Miu,
I have a feeling that you missed something in gak's example.
At the beginning, you were using a picture ring, but that didn't do the trick because you needed to add a picture for every item you needed.
Then, Gak proposed to use an image indicator, and to browse an image folder in order to find the needed picture without having to create a customized control and to be really flexible with importing new images as you wish.
But if we look at your last screenshot, you finally use custom OK controls with replaced frames by pictures. I think you can't understand what Gak is explaining if you don't use his solution (wich is probably the best by the way). You should probably take a closer look at his example, spend some time to really understand what it does, and you'll probably find the answer to your problem.
Regards,
Olivier L. | Certified LabVIEW Developer
01-10-2011 02:34 AM
Thanks Olivier L to highlight this point...I actually did not notice what he has done...
I thought he has taken previous reference.
01-10-2011 03:29 AM
01-10-2011 03:34 AM
My solution will not work with customize button.
01-10-2011 03:37 AM
01-10-2011 03:37 AM
" user has to select his/her food by clicking on those pictures itself" ...You can do it with picture control as well.
You can track event on picture control. Mouse click event.
And you can implement functionality of changing picture as well with the solution I just posted as an answer.
Don't you think so?