SlideShow Demonstration


SlideShow Description:

SlideShow is an extender that targets image controls. You can provide it with buttons to hit previous, next and play. You can configure the slideshow to play automatically on render, allow it loop through the images in a round robin fashion and also set the interval for slide transitions. You can use a page method to supply images to the slide show or use a webservice. In the sample above we have provided you with a slideshow that plays automatically on render and loops around to the first picture if you hit next on the last picture and vice versa if you hit previous on the first picture. The slideshow transitions pictures after 3 seconds.

SlideShow Properties:

The control above is initialized with this code. The italic properties are optional:

<ajaxToolkit:SlideShowExtender ID="SlideShowExtender1" runat="server"
    TargetControlID="Image1"
    SlideShowServiceMethod="GetSlides"
    AutoPlay="true"
    ImageTitleLabelID="imageTitle"
    ImageDescriptionLabelID="imageDescription"
    NextButtonID="nextButton"
    PlayButtonText="Play"
    StopButtonText="Stop"
    PreviousButtonID="prevButton"
    PlayButtonID="playButton"
    Loop="true" />

    * SlideShowServicePath - Path to the webservice that the extender will pull the images from.
    * SlideShowServiceMethod - The webservice method that will be called to supply images. The signature of the method must match this:

          [System.Web.Services.WebMethod]
          [System.Web.Script.Services.ScriptMethod]
          public AjaxControlToolkit.Slide[] GetSlides() { ... }

      Note that you can replace "GetSlides" with a name of your choice, but the return type and parameter name and type must exactly match, including case.
    * ContextKey - User/page specific context provided to an optional overload of the web method described by ServiceMethod/ServicePath. If the context key is used, it should have the same signature with an additional parameter named contextKey of type string:

          [System.Web.Services.WebMethod]
          [System.Web.Script.Services.ScriptMethod]
          public AjaxControlToolkit.Slide[] GetSlides(string contextKey) { ... }

      Note that you can replace "GetSlides" with a name of your choice, but the return type and parameter name and type must exactly match, including case.
    * UseContextKey - Whether or not the ContextKey property should be used. This will be automatically enabled if the ContextKey property is ever set (on either the client or the server). If the context key is used, it should have the same signature with an additional parameter named contextKey of type string (as described above).
    * NextButtonID - ID of the button that will allow you to see the next picture.
    * PlayButtonID - ID of the button that will allow you to play/stop the slideshow.
    * PreviousButtonID - ID of the button that will allow you to see the previous picture.
    * PlayButtonText - The text to be shown in the play button to play the slideshow.
    * StopButtonText - The text to be shown in the play button to stop the slideshow.
    * PlayInterval - Interval in milliseconds between slide transitions in play mode.
    * ImageTitleLabelID - ID of Label displaying current picture's title.
    * ImageDescriptionLabelID - ID of Label describing current picture.
    * Loop - Setting this to true will allow you to view images in a round-robin fashion.
    * AutoPlay - Setting this to true will play the slideshow automatically on render.

Category:

0 comments:

Post a Comment