My previous reply to this has not shown up on usenet, so I'm
repositing it. My apologies if you get this twice!
Hey Kyle, sorry for not getting back sooner. I'm working off the
OnInsertCommand event, which points to my method. Based on my testing
and fiddling, it almost seems that the OnInsertCommand is not firing
for reasons I can't determine.
Here's a really stripped down version of my control definition with
the event attribute settings:
<ajax:ReorderList ...
OnInsertCommand="onInsert"
OnUpdateCommand="onUpdate">
<EditItemTemplate>
<div class="editArea">
<asp:Button ID="cmdUpdate" runat="server"
Text="Update" CommandName="update" />
<asp

ropDownList ID="lstX" runat="server" ... />
...
</div>
</EditItemTemplate>
<InsertItemTemplate>
<div class="insertArea">
<asp

ropDownList ID="lstX" runat="server" ... />
<asp:Button ID="cmdAdd" runat="server" Text="Add"
CommandName="insert" />
</div>
</InsertItemTemplate>
...
</ajax:ReorderList>
Now, the funny this is that the update handler works fine, but the
insert handler does not. Here's what I mean. I have the following
little debug handler for the update command which writes the value
from one of the controls inside the reorderlist template to a label on
the form:
protected void onUpdate(object sender, ReorderListCommandEventArgs e)
{
DropDownList lstX = (DropDownList)e.Item.FindControl("lstX");
DebugLabel.Text = "Update: xID: " + lstX.SelectedValue;
}
When I click add, the DebugLabel get's the value from lstX, plus the
database stuff at the back end happens perfectly. Now, here's my
insert method:
protected void onInsert(object sender, ReorderListCommandEventArgs e)
{
DropDownList lstX = (DropDownList)e.Item.FindControl("lstX");
DebugLabel.Text = "Insert: UserID: " + lstX.Value;
}
As you can see, this is pretty much identical to the update method,
but it does not work at all. As far as I can tell, it does not even
run, because I tried setting a breakpoint on the code.
I know this issue has morphed a little from my original question
(since I've been investivating it), but I need to be able to access
the controls at runtime and manipulate their data programatically,
which is the point of all this.
Hope you can provide some insights!
Thanks,
Mark