How to change Transition Speed and Effects at runtime

Feb 9, 2009 at 6:30 AM
I would like to modify the Slide.Show2 project, so as to add a Textbox for entering the time interval between two images in a Album and an option to change the Transition effects at runtime. Any ideas ??
Feb 9, 2009 at 10:59 PM
The transition effects can be set at runtime by creating an httpHandler that generates the appropriate album xml at runtime... this is one that I made... notice this line writer.WriteAttributeString("transition", _Transition)   

    ''' <summary>  
    ''' Slide Show HttpHandler (SlideShowData.xml)  
    ''' </summary>  
    Friend Class SlideShowData : Implements IHttpHandler  
 
        ''' [ Methods ]  
        Public Sub ProcessRequest(ByVal context As HttpContext) Implements IHttpHandler.ProcessRequest  
   
            context.Response.Buffer = False 
            Dim _AlbumID As Integer = context.Request.QueryString("ID")  
            Using writer As New XmlTextWriter(context.Response.Output)  
 
                Dim SlideShowDC As New SlideShowDataContext  
                Dim r = SlideShowDC.GetSlideShowImages(_AlbumID).ToList  
 
 
                writer.Formatting = Formatting.Indented  
                writer.WriteStartDocument()  
                writer.WriteStartElement("data")  
                writer.WriteAttributeString("transition", _Transition)  
                writer.WriteStartElement("album")  
 
                For Each record As Object In r  
                    writer.WriteStartElement("slide")  
                    writer.WriteAttributeString("title", record.Title)  
                    writer.WriteAttributeString("thumbnail", record.Path)  
                    writer.WriteAttributeString("source", record.Path)  
                    writer.WriteAttributeString("description", record.Description)  
                    writer.WriteEndElement()  
                Next 
 
                writer.WriteEndElement()  
                writer.WriteEndDocument()  
                writer.Flush()  
            End Using  
        End Sub  
       
        ''' [ Properties ]  
        Public ReadOnly Property IsReusable() As Boolean Implements IHttpHandler.IsReusable  
            Get 
                Return False 
            End Get 
        End Property 
 
        Protected Shared _Transition As String = SlideShowPlayer._Transition   
  
    End Class 



As for changing the speed... sorry but I have not gotten that far.

You can see my blog post on setting Slide.Show2 settings via a database at http://www.dotnetblogger.com/post/2009/02/04/SlideShow2-Database-Config-(Singleton).aspx... it might help you with some of your ideas.
Feb 10, 2009 at 3:52 AM
Thanks.