Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Visual Basic 2008; Array of Images

Name: Anonymous 2009-05-20 15:58

Need some help /prog/


How would you store 10+ images in an array from the same folder using Visual Basic 2008?
The images are named 1.jpg, 2.jpg, etc..


The reason I need to do this is because I need to know how many times the picture has been displayed.
For example,
1. Program Start--> Image[0][0]
2. Image[0] is used once--> Image[0][1]


Image[0][1]
[0] is the image
[1] is an integer counting how many times it has been used

Name: Anonymous 2009-05-20 16:01

First, you have to load each picture into memory. Take a byte array to hold the data, for example. Next, you set the first few bytes to zero. Those bytes represent an integer, so to speak, which will be your counter.

Now you can simply use the first bytes each time an image has been used, and at the same time you also have the image ready for displaying at any given time.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List