Re: How to fire an event
- From: "Daniela Roman" <danielaroman@xxxxxxxxxx>
- Date: Sun, 12 Nov 2006 18:20:58 -0500
There are 2 scenarios:
- checking the boxes with the mouse
- checking them by code.
The same code for Save calls the event only when I click them with the
mouse. Looping through the rows with a for() doesn't do the expected
behaviour. What can I possibly do in the for() so that I misuse it?
The other page does the checking of the boxes in a javascript, that is
client side.
"Dave Sexton" <dave@jwa[remove.this]online.com> wrote in message
news:%23KxypsqBHHA.1220@xxxxxxxxxxxxxxxxxxxxxxx
Hi Daniela,
Well it could be a bug in the grid, but it's probably just misuse.
I assume that the "other pages' structure" performs different actions than
your page and that's why you are observing different behavior. If you are
not doing the same thing on your page then you might need to handle the
save operation differently as well - without use of the event.
This is an Infragistics-related problem. It has to do with performing the
appropriate action to cause a particular event to be raised. Again, you
need to figure out what actions cause the event to be raised and perform
them.
As an alternative, you can iterate the rows in your own code.
If the documentation is poor then I suggest looking for
Infragistics-related forums.
GL
--
Dave Sexton
"Daniela Roman" <danielaroman@xxxxxxxxxx> wrote in message
news:OhZxUwpBHHA.4024@xxxxxxxxxxxxxxxxxxxxxxx
Unfortunately the Infragistics documentation is very poor, that means it
doesn's say anything about what triggers the event and when.
Why I used the Update RowBatch? I wanted to keep the same structure as
the other pages have (I came into project half way) and this event
handles the looping automaically, the programmer only provides the action
for one row (updating the record), the event will do then the process for
each row in the grid. I did not understand why when I click the check
boxes with the mouse and then click Save button it triggers the
UpdateRowBatch, but when I change the value of the check boxes thru C#
code it doesn't.
"Dave Sexton" <dave@jwa[remove.this]online.com> wrote in message
news:OLLI$ciBHHA.140@xxxxxxxxxxxxxxxxxxxxxxx
Hi Daniela,
It's my bad I did not provide enough details on the matter.
The ideea is: I have an Infragistic datagrid control, one of the
columns is a check box. One of the buttons is Check All, which will
check all the check boxes in the grid. Then the option is to either
cancel the process and uncheck them or go ahead and save the changes.
For this there are 2 other buttons, Save and Cancel. Under save I need
to trigger the UpdateRowBatch event.
Thank you for the background information, but it's still not clear why
you want to raise the UpdateRowBatch event. What do you expect it to
do?
You might want to check out some Infragistics forums and documentation
pertaining to the UpdateRowBatch event if you're not sure why it's not
being raised when you expect it to be.
Realize though that forcing the event to be raised might not cause the
grid to perform the expected actions that are associated with the event.
In other words, events notify subscribers of an action - raising the
event yourself (if you could) would not cause the action to occur.
Instead, if you perform the appropriate action on the grid then the
event will be raised. This is normally how controls behave, although I
have to admit that I'm not familiar with the Infragistics grid and it
may behave differently.
So you should try to figure out:
1. how to perform the appropriate action on the grid to raise the event
2. whether the action required to raise the event is even necessary in
the first place
A collegue suggested that it does not trigger because the code is doing
the changes on the client side, which sincerely did not make much sense
to me.
What changes?
When the Save button is clicked, if your C# code in the Save button
click event handler is executed, then there is either a post-back or
AJAX at work here. In either case, the Save button's click event is
certainly being raised on the server.
It's possible that there are changes occurring on the client-side
before, after and even during (if AJAX is used) the server click event.
Although, I suspect that there is a full post-back occurring when the
Save button is clicked (meaning AJAX isn't being used).
--
Dave Sexton
.
- Follow-Ups:
- Re: How to fire an event
- From: Dave Sexton
- Re: How to fire an event
- References:
- How to fire an event
- From: Daniela Roman
- Re: How to fire an event
- From: Dave Sexton
- Re: How to fire an event
- From: Daniela Roman
- Re: How to fire an event
- From: Dave Sexton
- Re: How to fire an event
- From: Daniela Roman
- Re: How to fire an event
- From: Dave Sexton
- Re: How to fire an event
- From: Daniela Roman
- Re: How to fire an event
- From: Dave Sexton
- Re: How to fire an event
- From: Daniela Roman
- Re: How to fire an event
- From: Dave Sexton
- Re: How to fire an event
- From: Daniela Roman
- Re: How to fire an event
- From: Dave Sexton
- How to fire an event
- Prev by Date: Re: Relation between "KeyPress" and form focus (Vb.Net)
- Next by Date: Custom Implementation
- Previous by thread: Re: How to fire an event
- Next by thread: Re: How to fire an event
- Index(es):
Loading