Hiccup
❔ Create a picturebox_clicked event for each picturebox created
What I'm trying to achieve: I'm trying to look in a specific directory for text files, then I want to read the files and extract the URL present in them. After I got all of the URLs of all the text files present in my folder, I added them into a list so I could use them with their respective picturebox
For example, when URL1 has picture1 and URL2 has picture2, I want to set the text of the clipboard to URL1 when picturebox1 that has picture1 applied to it is clicked.
What I have tried: I have tried making a new picturebox_Clicked event in the pictureCreator for loop but the problem is that the event is always applied to the last picturebox created.
Any help is much appreciated
3 replies
❔ Decoded bitmap images aren't set in the photoboxes correctly
Then I wrote this code where it selects all three base64 strings from the SQLite database, decodes them and puts them in their pictureboxes respectively, the first base64 string --> the first picture box, second base64 string --> second picture box, and third base64 string --> third picture box.
However, when the program decodes the base64 strings and applies the images to the pictureboxes, the order is messed up. The second decoded image is set in the first picturebox, and the third decoded image is set in the second picturebox and the first decoded image is not set in any of the pictureboxes.
I have tried debugging and changing the value of i, but sadly they did not help.
3 replies