So I have a composite control that allows me to generate a form with our having to write out all the table stuff. It looks some thing like:
<cc2:FieldList ID="flUsers" runat="server" LabelCellCssClass="labelCell"> <Fields> <LDAPField FieldID="NetID" Label="Net ID:" Required="true" OnLDAPFieldClick="LoadLDAPFields" /> <TextField FieldID="FirstName" Label="First Name:" Required="true" /> <TextField FieldID="LastName" Label="Last Name:" Required="true" /> <TextField FieldID="Email" Label="Email:" Required="true" /> <TextField FieldID="Phone" Label="Phone #:" Required="true" /> <TextField FieldID="Room" Label="Room #:" Required="true" /> <DropDownField FieldID="Departments" Label="Dept:" DataSourceID="sqldsDepartments" DataTextField="DepartmentName" DataValueField="ID"> </DropDownField> <DropDownField FieldID="UserTypes" Label="User Type:" DataSourceID="sqldsUserTypes" DataTextField="UserType" DataValueField="ID"> </DropDownField> </Fields> <Buttons> <Button ID="btnAddUser" runat="server" Text="Add User" OnClick="btnAddUser_Click"> </Button> <Button ID="btnClearFields" runat="server" Text="Clear" CausesValidation="false" OnClick="btnClearFields_Click"> </Button> </Buttons></cc2:FieldList>At this point in time, we have the ability to assign events to all the buttons, and onchange events to the drop down lists. Everything works fine when there is no update panel surrounding it. We, however, would like it to work with an update panel. The control renders fine on the initial page load. It also works fine on the first event we fire such as clicking a button or changing drop down index. We run into problems when we click buttons or change indexes after that. Nothing works after. Does anyone have any ideas?
in the updatepanel do you have "ChildrenAsTriggers="false"" and do you have "UpdateMode="Conditional""? If not try UM=f first, then UM=f & CAT=f and see if that solves your problem...
p.s. setting UM=c means you'll need to use triggers to update the updatepanel fromoutside the updatepanel. anything inside that calls a postback will automatically cause the updatepanel to do an async postback
No comments:
Post a Comment