Solved

Element Triggers not supported

Posted on 2008-10-14
8
1,257 Views
Last Modified: 2012-06-27
I have a page based of the "Scotts to do list" tutorial(using adjax). Within this program I tried to use a trigger to update a update pannel.
<triggers>
            <asp:AsyncPostBackTrigger runat="server" EventName="SelectedIndexChanger" ControlID="DropDownList1" />
</asp:AsyncPostBackTrigger>
       
        </triggers>

But visual Web developer 2008 express says "Element triggers is not supported"

I have enabled 3.5 in visual studio.
0
Comment
Question by:soccerman777
  • 4
  • 4
8 Comments
 
LVL 22

Expert Comment

by:prairiedog
ID: 22712126
>>><asp:AsyncPostBackTrigger runat="server" EventName="SelectedIndexChanger" ControlID="DropDownList1" />
</asp:AsyncPostBackTrigger>           <===remove this line. You already have a close tag above it: "/>"
0
 

Author Comment

by:soccerman777
ID: 22712330
buy the way I am doing this on my development box (xp professional  iis 5.1). in iis 5.1 it only shows me using asp.net 2.05 but I do have .net framework 3.5 installed and I have set the file to 3.5 in visual studio.
0
 
LVL 22

Expert Comment

by:prairiedog
ID: 22712703
The Framework 3.5 uses the 2.0 CLR, so your settins are correct.
BTW, have your tried my comment?
0
 

Author Comment

by:soccerman777
ID: 22715209
yes I did try it. It did not work.  I am wondering if there is something to install that I need to use triggers.
0
What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

 
LVL 22

Expert Comment

by:prairiedog
ID: 22715949
Can you post more code?
0
 

Author Comment

by:soccerman777
ID: 22716334

Here is my content page
<%@ Page Language="VB" MasterPageFile="~/poMaster.master" AutoEventWireup="false" CodeFile="Default.aspx.vb" Inherits="_Default" Debug="true" title="Untitled Page" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
    <asp:ScriptManager ID="ScriptManager1" runat="server">
    </asp:ScriptManager>
    <asp:Label style="top: 300px; left: 150px; position: absolute; height: 22px; width: 42px"  
        ID="Label1" runat="server" Text="Vendor"></asp:Label>
    <asp:DropDownList style="top: 300px; left: 200px; position: absolute; height: 22px; width: 76px"
        ID="DropDownList1" runat="server" AutoPostBack="True">
        <asp:ListItem Selected="True"></asp:ListItem>
        <asp:ListItem Value="%ro%">ro</asp:ListItem>
        <asp:ListItem Value="%bo%">bo</asp:ListItem>
    </asp:DropDownList>
    <div class="divsmalltext2">
    <asp:Label ID="vendorLabel" style="top: 350px; left: 150px; position: absolute; height: 22px; width: 42px" runat="server" Text="Vendor Results"></asp:Label>
   
        <asp:UpdatePanel ID="UpdatePanel1" runat="server">
            <ContentTemplate>
       
                     
                   
        <asp:GridView ID="GridView1" runat="server" AllowPaging="True"
        AllowSorting="True" AutoGenerateColumns="False" DataKeyNames="pkey"
        DataSourceID="ObjectDataSource1"  CssClass="style1"
        alternatingrowstyle-CssClass="even" GridLines="None"
       
        style="top: 350px; left: 210px; position: absolute; height: 103px; width: 157px">
        <Columns>
            <asp:BoundField DataField="description" HeaderText="description"
                SortExpression="description" />
            <asp:BoundField DataField="pkey" HeaderText="pkey" InsertVisible="False"
                ReadOnly="True" SortExpression="pkey" />
            <asp:BoundField DataField="id" HeaderText="id" SortExpression="id" />
        </Columns>
        </asp:GridView>





       
       
       
       
       
       
       
       
       
           
            </ContentTemplate>
       
        </asp:UpdatePanel>
        <triggers>
        <asp:AsyncPostBackTrigger runat="server" EventName="SelectedIndexChanger" ControlID="DropDownList1" />
         </triggers>
    </div>
       
    <asp:ObjectDataSource ID="ObjectDataSource1" runat="server"
        OldValuesParameterFormatString="original_{0}" SelectMethod="Getvendors"
        TypeName="poDataSetTableAdapters.imtbl_contactTableAdapter">
        <SelectParameters>
            <asp:ControlParameter ControlID="DropDownList1" Name="search"
                PropertyName="SelectedValue" Type="String" />
        </SelectParameters>
    </asp:ObjectDataSource>
    </asp:Content>


Let me know if you need anything else
0
 
LVL 22

Accepted Solution

by:
prairiedog earned 500 total points
ID: 22716371
<Triggers> needs to be defined within <UpdatePanel> block, not outside it.
0
 

Author Closing Comment

by:soccerman777
ID: 31505923
Haha I did not even notice I had it outside the update panel.  
Hey keep a watch on my questions. I have been codeing asp.net for 3 weeks(I was a cold fusion developer) So I will be posting some pretty easy questions that I will need quick answers for.

Thanks
0

Featured Post

How to improve team productivity

Quip adds documents, spreadsheets, and tasklists to your Slack experience
- Elevate ideas to Quip docs
- Share Quip docs in Slack
- Get notified of changes to your docs
- Available on iOS/Android/Desktop/Web
- Online/Offline

Join & Write a Comment

A Change in PHP Behavior with Session Write Short Circuit (http://php.net/manual/en/book.session.php#116217) (Winter 2014)** With the release of PHP 5.6 the session handler changed in a way that many think should be considered a bug.  See the note …
International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
This video teaches viewers how to create their own website using cPanel and Wordpress. Tutorial walks users through how to set up their own domain name from tools like Domain Registrar, Hosting Account, and Wordpress. More specifically, the order in…
Use Wufoo, an online form creation tool, to make powerful forms. Learn how to choose which pages of your form are visible to your users based on their inputs. The page rules feature provides you with an opportunity to create if:then statements for y…

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now