AJAX :: Display Hyperlinks Inside Of Slideshow?
Mar 16, 2011Is it possible to display hyperlinks inside an AJAX slideshow window?... that is a different hyperlink in each "slide"
View 1 RepliesIs it possible to display hyperlinks inside an AJAX slideshow window?... that is a different hyperlink in each "slide"
View 1 Replieson another post i mentioned the problem but simplified it here! I am using ajax slideshow extender and getting images from my database
Datbase table file path example
/ ImageURL
/Members/matt//jeanette4.jpg
Code Behind
//here i open sql connection to database and retrieve images based on GUID of UserId which i add as sql parameter.//
// set the initial image
if (tblData.Rows.Count > 0)
{
imgShowImage.ImageUrl =tblData.Rows[0]["ImageUrl"].ToString();
imageLabel1.Text = tblData.Rows[0]["FirstName"].ToString();
}
}
}
[System.Web.Services.WebMethod]
[System.Web.Script.Services.ScriptMethod]
public static AjaxControlToolkit.Slide[] GetSlides()
{
AjaxControlToolkit.Slide[] slides = new AjaxControlToolkit.Slide[tblData.Rows.Count];
for (int i = 0; i < tblData.Rows.Count; i++)
{
DataRow dr = tblData.Rows[i];
slides[i] = new AjaxControlToolkit.Slide(
dr["ImageUrl"].ToString(),
dr["FirstName"].ToString(),
dr["LastName"].ToString());
}
return slides;
}
ASPX
Page shows the image
<asp:Image ID="imgShowImage" runat="server"
Height="300px" ImageAlign="Middle" />
This all works fine/ but when i set up the web config with Intelligencia.UrlRewriter code the slideshow images do not appear but the page gets divirted correctly
<rewriter>
<rewrite url="~/Matt" to="~/MembersClub/PublicProfile.aspx?Id=a8742959-aa5e-4830-9fc1-94f1b3d0bc41"/>
</rewriter>
The images are stored in a file directory named "Members".
My slideshow extender work perfectly fine, but I want to retrieve the current display picture's information on the server side.
So I added a normal asp button on the same page as the slideshow extender. When button clicked, it fire off a server side function. In the function I grabbed the SlideShow's name label, description label or the Image, but none of them contain any current information of the picture displayed at slideshow extender.
Is there another way to obtain the slideshow extender current state? Or am are those name, description label text value should be updated?
I'm currently using Aspose PDF Kit to split a 'master PDF' up into individual documents + thumbnails. This works well at the moment, but the device I'll be rendering the PDF on won't know about the annotations/links within the PDF.I understand there is a way to parse the PDF document to detect the X/Y position of a hyperlink etc, is there an simple way to extract/iterate across the document data so I can write it to an external XML file?
View 1 RepliesI use .NET C# , I dynamically create folder to store the image I upload, ex:
strFolder = Server.MapPath("./folder/folder_"+folid+"/")
So I could create different folders according to the page unique id. I have also created a thumbnail image from the image I have upload (cropped ones).
The problem I am trying to figure out is to display these images as a slide show from these dynamically created folder (display thumbnail in the page and clicking the thumbnail need to see the full size image just like slideshow).
I was trying to see examples in jQuery but its just client side. So is there any way to load these images and display as a slide show from the directory. Should I deal with DirectoryInfo in C#? Expecting a simple one.
I have a list of strings where by each string is a url to a pdf document. All I want to do is cycle through this list and display each url as a hyperlink on my page. I've seen this done before in MVC where the collection is made avaliable to the view and you can just do a foreach etc etc but I don't know how to do it on a normal asp.net page...
View 2 RepliesI'm new to Ajax and use MS Visual Web Developer 2008 Express edition with VB and SQL Server Express.
I have a number of photos stored in individual folders and wish to use the Slideshow extender to display all images in a selected folder.
I've set up a small test slideshow which is similar to the Ajax Video tutorial but cannot get autoplay to work.
The page displayed show the "Play button" and the first image in my set of photos.
I've pasted my code below.
Also as I'm new to this I don't understand Namespace - Do I just replace this with my website URL?
Web Service file
mports System.Web
Imports System.Web.Services [code]....
I wonder if it is possible to have a clickevent for the SlideShow control. In this case I am now showing 2 images.
Is it possible in any way have a clickevent or to handle a click on the images that is showing to open up a browser with a URL like www.google.com ?
I beleive the Click event then should be in the Image Control in somehow ?
[Code]....
I'm using Visual Studio 2010.
Are there any step by step tutorials on how to use the SlideSHowExtender to create a slideshow?
I have had a look before posting but couldn't find any step by step info.
Each time I try to drag the SlideShowExtender to a web form I get a round black circle with a black line through the middle, in other words it won't let me use it and I must be trying to use this control incorrectly.
I'd like to create a slideshow that goes through 4 pictures with some text that pops up on to each picture. An example of this is here - [URL]
I think this is using AJAX slideshow and animation? where I can find a tutorial to do this? I've not been able to find one that mixes images and text in this way.
I'm using the slideshow extender, however the images are not a standard size. The images are user supplied, and they are often displayed full size, so I can't standardize them. I need a way to resize them on the fly, and have them look good.
I've been working on this slide show off and on for some time. I've had many false starts, finding out after putting in quite a bit of time and work that there is just one thing or another that I cant't get to work. I'm hoping this ajax extender will be the answer. It won't be if I can't rezise the images.
what the extender can use as image sources? I know it can use an image on the hard drive, which is where my images are, but then I have the size problem. I tried using a webpage that uses a third party control to resizde the image, but that didn't work. I'm looking at this site: [URL] for resizing the images, can the output be used by the extender?
I use the BetterImage Control [URL] to display my images. It allows me to add copyright text to the image and I can set maximum width and maximum height and have the image display without stretching. They have their own slideshow, but the documentation is very limited and I think it displays everything in the specified folder. I need to create slideshows on the fly.
I want to use the ajax slideshow extender, but I need to resize the images on the fly, and add the copyright text. Is there a way to use the slideshow extender with the Better Image Control? I'm going to look into adding the copyright text and do the resizing myself, but I'd rather not have to.
The Slideshow isnt looping, however, it appears that the page is trying to refresh itself for each loop interval (I can see this at the bottom: downloading ...)
This should work because Im basically used the same code thats in the demo, minus the labels and buttons, and modified the web.config to be identical as well.
[Code]....
Here is the web.config:
[Code]....
I would like to use the ajax slideshow extender and getting the Image Url stored in a databaseso far my webserivice look like this..but I think im making a mistake somewhere..its not working
<WebMethod()> _
Public Function GetSlides() As AjaxControlToolkit.Slide()
Dim Connection As SqlConnection
[code]...
An Ajax Toolkit SlideShow used to work in .NET 2.0. After being upgraded to 3.5 the same slideshow stops working as before. It always pops up "Object reference not set to an instance of an object.". Different rewrites cause different errors at embedded Jscript level that cannot be fixed. I have added the AjaxToolkit.dll 3.5 under bin folder and placed its items in the VS2008 toolkit.
View 5 RepliesI'm using Visual Web Developer 2008 Express Edition, coding in C#. I think that the framework that I am aiming for is 2.0.
I am working on some old projects here where I work. However, I do not have access, nor do I know what the original programmer used to write this code.
The following code gives me an error:
[Code]....
(note that SlideList is an ArrayList that is being assigned to a DataSource. Also, this code is found inside a function named "CreateFeaturedSlideShow", which is called by the function "Page_Load" in "default.aspx.cs")
When I try to compile the project I get this error code: "The type or namespace name 'slideShow' could not be found (are you missing a using directive or an assembly reference?)"
When I comment out the code, the project compiles. However, when I try to run it, I get another error message: "Only one of AdvertisementFile, DataSource, or DataSourceID properties can be set on AdRotator 'AdRotator1'. "
From examing the rest of the code, it seems like this part of the project is populating a database with advertisement data, and selecting an ad at random, and keeping track of various statistics.
My problem is that I am having difficulty locating anything that will give me a slideShow namespace. The top result seems to be the SlideShow Extender, but after adding this toolkit to my toolbox nothing changed, which leads me to believe that I have something else.
Does anybody know where I can find this 'slideShow' that is referred to in the code?
i am working on ajax slideshow extender.
1) implement transformations between slide to slide.
2) and the direction means orientation in changing of slides.
I have the following problem with a slideshow in Ajax. Hope I have put it in the right Ajax forum. Some info: I do use MS Access and in the 'autos table' i do have the following fields:
field 1: nummer (text field) - this is the name of the image
field 2: cat (integer) - this is the category of the cars
field 3: naam (text field) - this is the name of the car
field 4: model (text field - this is the model of the car
In my masterpage i do have a menu where you can make the choice of a certain category of cars. This is done by a call to: slideshow.aspx?cat=100 In Slideshow.aspx a panel is setup and also buttons to manipulate the found images. Also the AjaxToolkit:Slideshowextender is defined as follows:
<ajaxToolkit:SlideShowExtender ID="SlideShowExtender1" runat="server"
TargetControlID="Image1"
SlideShowServicePath="slideservice.asmx"
SlideShowServiceMethod="Getslides"
AutoPlay="true"
ImageTitleLabelID="Name"
ImageDescriptionLabelID="Desc"
NextButtonID="NextButton"
PlayButtonID="PlayButton"
PlayButtonText="Play"
StopButtonText="Stop"
PreviousButtonID="PrevButton"
PlayInterval="4000"
Loop="true"
ContextKey="catid" />
As you can see the contactkey is also defined.
Inside the codebehind of slideshow.aspx.vb their is a sub defined:
Partial Class Slideshow
Inherits System.Web.UI.Page
Protected Sub Page_Load(ByVal sender As Object, ByVal e As EventArgs) Handles Me.Load
SlideShowExtender1.ContextKey = Request.QueryString("catid")
End Sub
End Class
The call from slideshow.aspx is to a slideservice.asmx which contains:
<%@ WebService Language="VB" CodeBehind="~/App_Code/SlideService.vb" %>
Here we call slideservice.vb.
The coding of the slideservice.vb file is:
Imports System.Web
Imports System.Web.Services
Imports System.Web.Services.Protocols
Imports System.Data.OleDb
Imports System.Web.UI.Page
<WebService(Namespace:="http://vancouver.com/")> _
<WebServiceBinding(ConformsTo:=WsiProfiles.BasicProfile1_1)> _
<Global.Microsoft.VisualBasic.CompilerServices.DesignerGenerated()> _
<System.Web.Script.Services.ScriptService()> _
Public Class SlideService
Inherits System.Web.Services.WebService
<WebMethod()> _
Public Function GetSlides(ByVal contextKey As String) As AjaxControlToolkit.Slide()
Dim strconn As String = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=|DataDirectory|Vancouver.mdb"
Dim cn As New OleDbConnection(strconn)
Dim SQLStr As String
SQLStr = "SELECT nummer, naam, model FROM Autos WHERE ((Autos.cat) = @catid)"
Try
cn.Open()
Dim cmd As New OleDbCommand(SQLStr, cn)
Dim sCatid As String = ""
' Give the value to sCatid from contextkey
If sCatid.Trim().Length = 0 Then sCatid = contextKey
cmd.Parameters.AddWithValue("@catid", sCatid)
Dim thisReader As OleDbDataReader = cmd.ExecuteReader()
Dim photoCounter As Integer
While thisReader.Read()
photoCounter = photoCounter + 1
End While
If (photoCounter > 0) Then
'we now know how many pictures there are in this category of the database
Dim MySlides(photoCounter - 1) As AjaxControlToolkit.Slide
'set up the command string
Dim photoLookupCmd As New OleDbCommand(SQLStr, cn)
'and add the parameters to it for the category
photoLookupCmd.Parameters.AddWithValue("@catid", sCatid)
thisReader = photoLookupCmd.ExecuteReader()
Dim i As Integer
For i = 0 To photoCounter - 1
thisReader.Read()
Dim number As String = thisReader.GetString(0)
Dim name As String = thisReader.GetString(1) + " - " + thisReader.GetString(2)
MySlides(i) = New AjaxControlToolkit.Slide(("pictures" + number + ".jpg"), name, "")
Next
thisReader.Close()
Return MySlides
Else
Dim MySlides(0) As AjaxControlToolkit.Slide
MySlides(0) = New AjaxControlToolkit.Slide("pictures99999.jpg", "sorry - not available", "pls. mail us to report")
thisReader.Close()
Return MySlides
End If
Catch x As Exception
Dim MySlides(0) As AjaxControlToolkit.Slide
MySlides(0) = New AjaxControlToolkit.Slide("pictures99999.jpg", "Exception error", "pls. mail us to report")
Return MySlides
Finally
cn.Close()
End Try
End Function
End Class
When i run the code i will get an exception error and when following the code in debug mode i do see that inside the first loop in FOR i = 0 to photocounter - 1 : The first loop gets the right info from the database inside Myslide(1) fields. Going into the second loop i will get after dim name as string .....
the program goes to catch x as exception. I did see that number was found correctly during the previuous line. During an other debug session i noticed that the Parameter.item has the following error (which I do not understand), saying: Overload resolution failed because no accessible 'Itemī accepts this number of arguments.
I'm using ajax slideshow extender for a slideshow. How do I use an imagebutton to play/pause slideshow. I would have to change the imageurl with the corresponding action...
View 1 Replies am using Slideshow ajaxcontrol and its works perfect in the VS2008 in the local system, where as when I move to server (production) it is not working, I was getting different issues, I solved few by refering some forums, where as still it is not wroking or no error can any one help me here.Here is the URL of production: http://74.55.115.122/$sitepreview/focusedreader.com/demo/Default.aspxCode of Default.aspx is
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Default.aspx.cs" %>
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-
[code]...
I'm using the Slideshow extender and have a vexing problem that I can't see to solve. The slidehow itself works fine, but I am trying to get the value of the ImageDescriptionLabelID into a javascript variable when the slide changes. Using this code in a javascript function:
[Code]....
It appears that the add_slideChanging event fires BEFORE the image (and accompanying label) change. Is there an event that occurs AFTER the image changes?If not, any ideas on how I can make the number I'm successfully passing in the lblDesc control available to javascript?
how can we have the ajax slide show which take the image path from database, instead of define the image path static in service method.
View 1 Replieswhat i am trying to achieve is a single image control with slideshow extender attached which when of the category option buttons are pressed the SlideService goes get the images for that category from the image folder sub folders and starts to display them i have got the code to work as to, the point that i have to hardcode the images sub folders path in to the webmethod - but i want the image folder name to be passed as a parameter when the webmethod GetSlides is called - the code i have so far is From the aspx page - (the category name will be a string retrieved from the button text when clicked
[Code]....
I have found all kinds of tutorials on the web showing how to implement the AJAX slideshow extender, but can't get them to work. All I want to do is put a simple slideshow on a master page. I want to use a code behind file for the c# (do not want the script on the page itself.
I ran into a couple of problems with the samples on the web. Specifically when I try to add System.Web.Services.WebMethod and System.Web.Script.Services.ScriptMethod - VS 2010 doesn't know what the "WebMethod" or the "ScriptMethod" are. Further, VS2010 express keeps telling me "{" expected - on the line AjaxControlToolkit.Slide[] slides = new AjaxControlToolkit.Slide[5];
Every tutorial on the web seems to be for ASP.net 2.0 - and is at least 2 years old. Is there an easier way in ASP.Net 4 to implement the slideshow control? I am new to c# in general, so if someone could provide a simple cs codebehind file - and the code on the aspx page, that would be great. I understand more than I can write.
I have a slideshow extender, I will change the slideshow extender's contextkey value by a button click event. So that after button click the slideshow will display different set of image. Originally with postback everything work fine, but I don't want the whole page to refresh.
So I put the slideshow extender inside an updatepanel with triggers target the button click event. Now the whole page didn't refresh and the slideshow extender's contextkey value did change (same code as before) after button click event. However the image set on the slideshow didn't change.
I think I am missing some sort of slideshow extender reload or refresh call but I am not sure how to do this? I didn't see any related property with slideshow extender...