Visual Basic contains a slide show control where you can insert scrolling Web pages or images into your software. Visual Basic has a long list of controls compatible with the programming language, and one of these controls is the "SlideShow" control. Find the control in your toolbox; it requires only a few lines of code to scroll through each page or image you want to display.
- Skill level:
Other People Are Reading
Create your Visual Basic variables. One variable is used as the array of slide show images or pages. The second one is used to loop through each element to process the slide show. The following code shows you how to use these variables:
Add the pages or images to your "pictures" array. In this instance, the array contains a slide show of three pages. The following code shows you how to save each page to your array:
aPicturePages(0) = "myvacation1.htm"
aPicturePages(1) = "myvacation2.htm"
aPicturePages(2) = "myvacation3.htm"
Loop through each slide show element and display it to the user. The slide show is displayed in a frame, and it continues to loop until all images are shown. You can also do a continuous loop so that images always display for the reader. The following code loops through each slide show image:
while picture_count <> 3
parent.frames("slideshow").location = pictures(picture_count)
picture_count = picture_count+1
- 20 of the funniest online reviews ever
- 14 Biggest lies people tell in online dating sites
- Hilarious things Google thinks you're trying to search for