Wednesday, March 28, 2012

Accordeon wont work - please help a newby

Hello,

I am new to Atlas and trying to use accordeon extension from the toolkit. I have installed the toolkit and AjaxControlExtender, then created a web site with ajax-toolkit template and added accordeon control from toolbox to the Default.aspx

I get a few error messages:

Error 1 Type 'AjaxControlToolkit.Accordion' does not have a public property named 'AccordionPane'. c:\inetpub\wwwroot\eBible-ajax\Default.aspx 13
Error 2 Type 'AjaxControlToolkit.Accordion' does not have a public property named 'AccordionPane'. c:\inetpub\wwwroot\eBible-ajax\Default.aspx 16
Error 3 Content ('</ajaxToolkit:AccordionPane> </ajaxToolkit:AccordionPane>') does not match any properties within a 'AjaxControlToolkit.Accordion', make sure it is well-formed. c:\inetpub\wwwroot\eBible-ajax\Default.aspx 16
Error 4 Accordion1:Type 'AjaxControlToolkit.Accordion' does not have a public property named 'AccordionPane'. c:\inetpub\wwwroot\eBible-ajax\Default.aspx http://localhost:8080/eBible-ajax/

I guess I am missing something, possibly a very simple thing that is well knows to you guys but not yet to me. Below is how the pages' code looks. Thanks for help!

<%@dotnet.itags.org. Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head runat="server"> <title>Untitled Page</title></head><body> <form id="form1" runat="server"> <asp:ScriptManager ID="ScriptManager1" runat="server" /> <div> <ajaxToolkit:Accordion ID="Accordion1" runat="server" Width="250px"> <ajaxToolkit:AccordionPane ID="AccordionPane1" runat="server" ContentCssClass="" HeaderCssClass=""> </ajaxToolkit:AccordionPane> <ajaxToolkit:AccordionPane ID="AccordionPane2" runat="server" ContentCssClass="" HeaderCssClass=""> </ajaxToolkit:AccordionPane> </ajaxToolkit:Accordion> </div> </form> </body></html>
Hi,


Sorry about that .

We dont see the @.Register tag in your page to register the AjaxControlToolkit process.

Can you add this line after the @.Page tag ?

<%@. Register Assembly="AjaxControlToolkit, Version=1.0.10123.0, Culture=neutral, PublicKeyToken=28f01b0e84b6d53e" Namespace="AjaxControlToolkit" TagPrefix="ajaxToolkit" %>

nope, doesn't help - same errors

it should be like this i believe

<ajaxToolkit:Accordion>

<Panes>

// panes in here

</Panes>

</ajaxToolkit:Accordion>



Figured this out, too. The Panes tag is not added for some reason when you add panes from properties box (panes -> collection -> add). Weird.

Thanks anyway.


Hi there,

you should check out the introductory video on this site

http://www.asp.net/learn/videos/view.aspx?tabid=63&id=87

cheers!

No comments:

Post a Comment