473,473 Members | 1,757 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Accordion control for .net 3.5 sp1 is broken?

I am trying to use an accordion control from the ajax control toolkit for
..net3.5 sp1. When I put a link in one of the accordion pannel
headerTemplates to open and close the content, I always get an "index of /"
page that shows the files and folders in the folder the current page is in.
The link looks like this: <a href="">Open/close test</aAny idea why this
happens and how to fix it?

Nov 13 '08 #1
6 2159
Can u post your accordion code?
will be much clearer to figure out...

tks..
"Andy B" <a_*****@sbcglobal.netescreveu na mensagem
news:%2***************@TK2MSFTNGP06.phx.gbl...
>I am trying to use an accordion control from the ajax control toolkit for
.net3.5 sp1. When I put a link in one of the accordion pannel
headerTemplates to open and close the content, I always get an "index of /"
page that shows the files and folders in the folder the current page is in.
The link looks like this: <a href="">Open/close test</aAny idea why this
happens and how to fix it?

Nov 13 '08 #2
Can u post your accordion code? will be much clearer to figure out...
WebForm1.aspx accordion code:
<asp:ScriptManager ID="ScriptManager1" runat="server">

</asp:ScriptManager>

<div>

<cc1:Accordion ID="Accordion1" runat="server" RequireOpenedPane="false"
SelectedIndex=0>

<HeaderTemplate>

<a href=""><%#Eval("Title")%></a>

</HeaderTemplate>

<ContentTemplate>

<%#Eval("Body")%>

</ContentTemplate>

</cc1:Accordion>

</div>

WebForm1.aspx.cs code for accordion:

Imports Test.eternityrecordsonlineEntities

Partial Public Class WebForm1

Inherits System.Web.UI.Page

Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs)
Handles Me.Load

Dim NewsContext As New eternityrecordsonlineEntities()

Accordion1.DataSource = NewsContext.GetAllNews()

Accordion1.DataBind()

End Sub

End Class
Nov 13 '08 #3
<a href='<%#Eval("FieldWithURL")%>'><%#Eval("Title")% ></a>

you are not filling the url tag..

"Andy B" <a_*****@sbcglobal.netescreveu na mensagem
news:%2****************@TK2MSFTNGP02.phx.gbl...
>Can u post your accordion code? will be much clearer to figure out...
WebForm1.aspx accordion code:
<asp:ScriptManager ID="ScriptManager1" runat="server">

</asp:ScriptManager>

<div>

<cc1:Accordion ID="Accordion1" runat="server" RequireOpenedPane="false"
SelectedIndex=0>

<HeaderTemplate>

<a href=""><%#Eval("Title")%></a>

</HeaderTemplate>

<ContentTemplate>

<%#Eval("Body")%>

</ContentTemplate>

</cc1:Accordion>

</div>

WebForm1.aspx.cs code for accordion:

Imports Test.eternityrecordsonlineEntities

Partial Public Class WebForm1

Inherits System.Web.UI.Page

Protected Sub Page_Load(ByVal sender As Object, ByVal e As
System.EventArgs) Handles Me.Load

Dim NewsContext As New eternityrecordsonlineEntities()

Accordion1.DataSource = NewsContext.GetAllNews()

Accordion1.DataBind()

End Sub

End Class


Nov 13 '08 #4
Yea I know. I don't want this to load a new page, I just want it to
open/close the content of the pannel. The old versions of the control have
<a href="">blah</afor opening/closing the pannel. What kind of URl would I
put in the href= section if the entire control is bound to a resultset from
a database? More direction would be helpful here.
"Christiano Donke" <cd****@digiexpress.com.brwrote in message
news:O4**************@TK2MSFTNGP04.phx.gbl...
<a href='<%#Eval("FieldWithURL")%>'><%#Eval("Title")% ></a>

you are not filling the url tag..

"Andy B" <a_*****@sbcglobal.netescreveu na mensagem
news:%2****************@TK2MSFTNGP02.phx.gbl...
>>Can u post your accordion code? will be much clearer to figure out...
WebForm1.aspx accordion code:
<asp:ScriptManager ID="ScriptManager1" runat="server">

</asp:ScriptManager>

<div>

<cc1:Accordion ID="Accordion1" runat="server" RequireOpenedPane="false"
SelectedIndex=0>

<HeaderTemplate>

<a href=""><%#Eval("Title")%></a>

</HeaderTemplate>

<ContentTemplate>

<%#Eval("Body")%>

</ContentTemplate>

</cc1:Accordion>

</div>

WebForm1.aspx.cs code for accordion:

Imports Test.eternityrecordsonlineEntities

Partial Public Class WebForm1

Inherits System.Web.UI.Page

Protected Sub Page_Load(ByVal sender As Object, ByVal e As
System.EventArgs) Handles Me.Load

Dim NewsContext As New eternityrecordsonlineEntities()

Accordion1.DataSource = NewsContext.GetAllNews()

Accordion1.DataBind()

End Sub

End Class



Nov 13 '08 #5
hhmm i think i got it...

maybe <a href="#">blah</a>, but it will reload the page...

try to do it without the link... just plain text...

<HeaderTemplates>

<%#Eval("Title")%>

</HeaderTemplates>
I gotta check it at home... but i think the Accordion creates the open/close
statements by itself...

"Andy B" <a_*****@sbcglobal.netescreveu na mensagem
news:%2****************@TK2MSFTNGP04.phx.gbl...
Yea I know. I don't want this to load a new page, I just want it to
open/close the content of the pannel. The old versions of the control have
<a href="">blah</afor opening/closing the pannel. What kind of URl would
I put in the href= section if the entire control is bound to a resultset
from a database? More direction would be helpful here.
"Christiano Donke" <cd****@digiexpress.com.brwrote in message
news:O4**************@TK2MSFTNGP04.phx.gbl...
><a href='<%#Eval("FieldWithURL")%>'><%#Eval("Title")% ></a>

you are not filling the url tag..

"Andy B" <a_*****@sbcglobal.netescreveu na mensagem
news:%2****************@TK2MSFTNGP02.phx.gbl...
>>>Can u post your accordion code? will be much clearer to figure out...
WebForm1.aspx accordion code:
<asp:ScriptManager ID="ScriptManager1" runat="server">

</asp:ScriptManager>

<div>

<cc1:Accordion ID="Accordion1" runat="server" RequireOpenedPane="false"
SelectedIndex=0>

<HeaderTemplate>

<a href=""><%#Eval("Title")%></a>

</HeaderTemplate>

<ContentTemplate>

<%#Eval("Body")%>

</ContentTemplate>

</cc1:Accordion>

</div>

WebForm1.aspx.cs code for accordion:

Imports Test.eternityrecordsonlineEntities

Partial Public Class WebForm1

Inherits System.Web.UI.Page

Protected Sub Page_Load(ByVal sender As Object, ByVal e As
System.EventArgs) Handles Me.Load

Dim NewsContext As New eternityrecordsonlineEntities()

Accordion1.DataSource = NewsContext.GetAllNews()

Accordion1.DataBind()

End Sub

End Class




Nov 13 '08 #6
This is now fixed. I had to do the following to get it to work:

1. In the HeaderTemplate, use a # for the url of the link. This is a code
telling the accordion control to open/close the pannels.
2. Set the SuppressHeadersPostback property to true. This stops the page
from reloading all the time.

There is still a bug in the control where setting some properties like
RequireOpenPane and SuppressHeaderPostback will create an accordion_extender
control and insert it into the accordion control source. This results in an
error 'The control Accordion1 doesn't have a public property
'accordion_extender''. Moving the accordion_extender control outside of the
accordion control results in a parse error: 'Only 1 control with the ID
'accordion_extender1' can exist on the page at a time...'. Totally deleting
the extender from the aspx source fixes the problems with the "extender
properties". I think this is a bug and should be fixed somehow.
"Christiano Donke" <cd****@digiexpress.com.brwrote in message
news:ew**************@TK2MSFTNGP02.phx.gbl...
hhmm i think i got it...

maybe <a href="#">blah</a>, but it will reload the page...

try to do it without the link... just plain text...

<HeaderTemplates>

<%#Eval("Title")%>

</HeaderTemplates>
I gotta check it at home... but i think the Accordion creates the
open/close statements by itself...

"Andy B" <a_*****@sbcglobal.netescreveu na mensagem
news:%2****************@TK2MSFTNGP04.phx.gbl...
>Yea I know. I don't want this to load a new page, I just want it to
open/close the content of the pannel. The old versions of the control
have <a href="">blah</afor opening/closing the pannel. What kind of URl
would I put in the href= section if the entire control is bound to a
resultset from a database? More direction would be helpful here.
"Christiano Donke" <cd****@digiexpress.com.brwrote in message
news:O4**************@TK2MSFTNGP04.phx.gbl...
>><a href='<%#Eval("FieldWithURL")%>'><%#Eval("Title")% ></a>

you are not filling the url tag..

"Andy B" <a_*****@sbcglobal.netescreveu na mensagem
news:%2****************@TK2MSFTNGP02.phx.gbl.. .
Can u post your accordion code? will be much clearer to figure out...
WebForm1.aspx accordion code:
<asp:ScriptManager ID="ScriptManager1" runat="server">

</asp:ScriptManager>

<div>

<cc1:Accordion ID="Accordion1" runat="server" RequireOpenedPane="false"
SelectedIndex=0>

<HeaderTemplate>

<a href=""><%#Eval("Title")%></a>

</HeaderTemplate>

<ContentTemplate>

<%#Eval("Body")%>

</ContentTemplate>

</cc1:Accordion>

</div>

WebForm1.aspx.cs code for accordion:

Imports Test.eternityrecordsonlineEntities

Partial Public Class WebForm1

Inherits System.Web.UI.Page

Protected Sub Page_Load(ByVal sender As Object, ByVal e As
System.EventArgs) Handles Me.Load

Dim NewsContext As New eternityrecordsonlineEntities()

Accordion1.DataSource = NewsContext.GetAllNews()

Accordion1.DataBind()

End Sub

End Class




Nov 13 '08 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: noneya22 | last post by:
I have an accordion control with a dynamically generated asp.net checkbox server-side control in each accordion pane. On postback I loop through all of the controls on the page, and I never find...
3
by: srilakshmim | last post by:
Hello I want to create Accordion (Ajax Control Tool Kit)dynamically. My Code is as follows Code: ( cpp ) protected void Page_Load(object sender, EventArgs e) { try ...
1
by: anjali.lourda | last post by:
Hi, We are trying to use the accordion control from ajaxcontroltoolkit by databinding to an sqldatasource. The accordion binds to the datasource perfectly. However, We are not able to access the...
0
by: axxon | last post by:
hi, I am having a huge problem here! the scenario is i am trying to create dynamic accordion Panes to a accordion control inside a tab panel in a content page. It works just fine in a regular...
0
by: rcon | last post by:
I'm creating a user control to prompt for crystal reports parameters. The individual controls work fine, and the over all control works fine too. However, I'm not really that experienced in the...
1
by: David Lazos | last post by:
Hi, I'm using the HeaderTemplate and the ContentTemplate of the Accordion control and binding it to a DataTable. But it doesn't display any data. If i bind the same datatable to a datalist it...
8
by: Tomasz J | last post by:
Hello developers, After migrating my web project application (using the old model) to .Net Framework 3.5 and Ajax Control Toolkit release 20820 the Accordion control no longer works correctly....
3
by: Allen Chen [MSFT] | last post by:
Hi Richard, Quote from Richard================================================== However I also want to be able to remove the panes. I have tried to include this, but find that when I first...
0
by: Andy B | last post by:
I am using an accordion for some different views. The datasource for the one below is hooked up to a entity framework datacontext function import and works just fine. The problem is I can't...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.