Hi!
oEvent.needPostBack=false;
oEvent.cancelPostBack=true;
We will just do your way...But on Header Click Event..
To cancel postback can you use oEvent.cancel = true;
I think this way will cancel the event as well as also postback of the page.
Well, maybe in this case you can also try using the BeforeGroupSelected and see if it helps in your case. If it does not, then maybe the child controls nested in the Group template will be able to take care of that - e.g. cancel the postback event when clicked upon - but this really depends on the controls you are nesting.
If these two ideas do not help, maybe pasting the ASPX setup of your UltraListWebBar instance + the javascript event handler you are creating here may provide additional clues.
I tried the code you gave and nothing is happening. I mean there is no postback and even the client side event is not fired. I placed an alert in the client side event handler and it is never called.
Any ideas what couldbe wrong. I donot have items in the groups.. instead i have other controls.
So i guess the selected Item event never comes into the picture
Ahmad
Hello,
Could you please try wiring the BeforeItemSelected event handler of your UltraWebListBar instance and setting the cancel property of the client-side event passed to the handler? This worked for me just fine in v7.3 of the product. You can find the source code of my test scenario below:
<script type="text/javascript"> function beforeItemSelectedHandler(listBar, item, igEvent) { igEvent.cancel = true; } </script> <iglbar:UltraWebListbar ID="UltraWebListbar1" runat="server" BorderWidth="" Height="200px" onitemclicked="UltraWebListbar1_ItemClicked" Width="124px">
<ClientSideEvents BeforeItemSelected="beforeItemSelectedHandler" /> <Groups> <iglbar:Group Text="Group" TextAlign="Left"> <Labels Expanded="" Collapsed="" Selected=""> </Labels> <Items> <iglbar:Item Text="Item"> <Labels Selected="" /> </iglbar:Item> <iglbar:Item Text="Item"> <Labels Selected="" /> </iglbar:Item> <iglbar:Item Text="Item"> <Labels Selected="" /> </iglbar:Item> </Items> </iglbar:Group> <iglbar:Group Text="Group" TextAlign="Left"> <Labels Collapsed="" Expanded="" Selected="" /> </iglbar:Group> <iglbar:Group Text="Group" TextAlign="Left"> <Labels Collapsed="" Expanded="" Selected="" /> </iglbar:Group> </Groups>
</iglbar:UltraWebListbar>