2012年3月22日星期四

How to Create a Java Slide Show

A Java applet runs on a internet browser utilizing the Java Virtual Machine or Applet Viewer. Written in the Java program writing language, an applet provides interactive features to web applications. The applet, embedded within an HTML page, reacts predicated on user response. Quite simply, once the viewer clicks a button, the Java program flips to a brand new image without moving to a brand new web site. Applet design could be complicated. Utilizing a ready-made applet makes the duty of making a slide show presentation for the Webpage possible.


Setup the look Down load Sureshot Java Slideshow Applet. This really is freeware provided by the Sureshot Company. Unzip the files with a zip extractor such as for example Winzip. Open an HTML editor program like Dreamweaver. Open manual. html from the file supplied with the SureShot application. Add the applet code to a brand new HTML page. The code can be found in the SureShot manual. Highlight the written text starting <APPLET CODE and ending at </APPLET>. Right-click in your mouse and choose "Copy" from the menu, navigate to your HTML page. Right-click again and choose "Paste. " The code can look in your HTML scripting. Save yourself the HTML page in your hard disk and close your editor. Open a graphical design program and create the pictures for the slide show. Pictures should all function as the same size. Save yourself the pictures in a single folder in your hard disk and close the editor. Configure the Applet Open a brand new text file in a text editor, like NotePad. Cut and paste from the script for the manual to your text file beginning at "Configuration template declare the Slideshow Applet" and ending at "image5=image5. gif. " Setup the frame number on the written text file. This is actually the quantity of pictures you'll be displaying in the slide show. Move right down to the line in your text file that reads "frames=. " Change the amount to match the amount of pictures you're displaying. In the event that you have 10 images for the slide show, change 20 to 10. Move right down to "Slideshow images" in your text file. Change the "=image" text to the names of one's images. If the very first picture is myroom. gif, then your first line should read: Image0=myroom. gifYou can truly add more lines if necessary. For instances, if you've got a sixth image, type image6= to include more lines. Configure Resources. jar Proceed to the main directory of one's hard disk. The main directory may be the first directory in your hard disk. Click MyComputer or Computer, based on which version of Windows you're running. Double-click on the "C: " drive. Now you're at the main directory. Right-click on a blank section of your root directory and choose "New" then "Folder, " name the folder "tmp. " Save your valuable text file to the tmp folder in your root drive. Name the written text file "config. txt. " Move the pictures for the slideshow to the tmp directory. Click "Start" at the end of one's desktop. Choose the search text box from the beginning menu. For XP users, click "Run" to open the search box. Vista and Windows 7 users can access the written text box from the beginning menu. Type "CMD" in the search text box, this can open the command screen on your pc. Proceed to the c: prompt. Key in the next command: 'cd c: \tmp\slideshowtem\' and hit enter. Key in the next command on the following line at c: prompt: 'jar cf resources. jar *' and hit enter. Close the command screen. You need to are in possession of a file titled "resources. jar" in your tmp folder. Upload Files Upload your HTML file, image files and resources. jar file to your server. Upload all files to exactly the same directory. Locate and upload "slideshow. jar" in the files downloaded with the SureShot application. Upload to exactly the same directory since the other files. Test thoroughly your slideshow by opening your HTML file within an Web browser.



没有评论:

发表评论