You must Sign In to post a response.
  • Category: ASP.NET

    Slideshow of collection of dynamic images using C#.net

    Hi friends,



    We are doing website with C#.
    When i click on image it should give slideshow of collection of dynamic images.


    Please suggest me how can i do?

    Thanks in advance

    Sucharitha
  • #648599
    You can make use of Ajax slide show extender control that are easy to use and have a good UI. just maintain a list of images to be passed to it.


    <ajaxToolkit:SlideShowExtender ID="SlideShowExtender1"
    runat="server"
    TargetControlID="imgPhotos"
    SlideShowServiceMethod="GetSlides"
    SlideShowServicePath="MyWebService.asmx"
    AutoPlay="true"
    NextButtonID="btnNext"
    PlayButtonText="Play"
    StopButtonText="Stop"
    PreviousButtonID="btnPrev"
    PlayButtonID="btnPlay"
    Loop="true"/>


    Thanks & Regards
    Anil Kumar Pandey
    Microsoft MVP, DNS MVM

  • #648601
    In ASP.NET :

    add a Slideshow Extender Control:
     

    <asp:SlideShowExtender ID="SlideShowExtender1" runat="server" AutoPlay="true"
    ImageDescriptionLabelID="lbldatails" TargetControlID="Image1" Loop="true" StopButtonText="Stop"
    PlayButtonText="Play" NextButtonID="buttonNext" PreviousButtonID="buttonPrev"
    PlayButtonID="buttonPlay" SlideShowServiceMethod="GetSlides" UseContextKey="True"></asp:SlideShowExtender>


    select Add Slideshow page method and write the following code:

    [System.Web.Services.WebMethodAttribute(), System.Web.Script.Services.ScriptMethodAttribute()]
    public static AjaxControlToolkit.Slide[] GetSlides()
    {
    AjaxControlToolkit.Slide[] slides = new AjaxControlToolkit.Slide[4];
    slides[0] = new AjaxControlToolkit.Slide("images/a.png", "", "images");
    slides[1] = new AjaxControlToolkit.Slide("images/b.png", "", "images");
    slides[2] = new AjaxControlToolkit.Slide("images/c.png", "", "images");
    slides[3] = new AjaxControlToolkit.Slide("images/d.png", "", "images");
    return slides;
    }

    Regards
    Mr.Rajesh
    Software Engg.

  • #648693
    Hi Anil & Rajesh,

    thanks for your reply,

    I need full code for this, can you please send me the code
    because i am working with slideshow extender but i am getting error.

  • #648780
    Hi Rajesh,

    I an getting the images from database, retrieving into datatable.


  • This thread is locked for new responses. Please post your comments and questions as a separate thread.
    If required, refer to the URL of this page in your new post.