ASP.net Library | Error Handling

9 views
Skip to first unread message

gseagull

unread,
Aug 5, 2009, 10:48:08 AM8/5/09
to completeui
Hi guys,

i'm using your beta-.net Library in a customer-project and have some
problems using the js-api. Whatever, i've done some workarounds, now
all's working fine.

But i've not found some properties or events for error-handling. If an
error occurs within the DataHandler/DataProvider the grid is either
loading all the time or it shows js-errors.
How to handle server-side errors?

Thanks in advance,
gseagull

fil_nitobi

unread,
Aug 5, 2009, 1:51:35 PM8/5/09
to completeui
Hi gseagull,

Thanks for taking the time to test out our new CUI.NET beta wrappers.
If you have any feedback for us, suggestions, comments, things that
you were expecting would be there but are missing, it would be great
if you could let Nitobi know directly. This Google Group is aimed at
development, support and discussion related to the JavaScript source
code of Complete UI. If you have questions, comments or need support
with the CUI.NET beta wrappers, feel free to submit a ticket with us
at http://nitobi.zendesk.com. I'm particularly interested in the
problems you mentioned you had with the JavaScript API.

As for error handling, unfortunately you are absolutely right about
lack of error handling for the Data Handler / Provider object. For the
vanilla Complete UI open source components, you can set an error
message from within your data handler using the following calls:

* Classic ASP: EBAGetHandler_SetErrorMessage(ErrorMessage) and
EBASaveHandler_SetErrorMessage(ErrorMessage)
* PHP: EBAGetHandler::setErrorMessage($message) and
EBASaveHandler::setErrorMessage($message)
* JSP: GetHandler.setErrorMessage(String message) and
SaveHandler.setErrorMessage(String message)

At this time, the CUI.NET beta wrappers do not have this
functionality. However, our aim is to make our .NET wrappers as close
to the JavaScript components as possible, so this is a feature we
definitely want to incorporate before the full release. I will add it
to our internal feature/issue tracker and update the known issues list
(wiki.nitobi.com) to reflect this.

gseagull

unread,
Aug 17, 2009, 3:18:50 AM8/17/09
to completeui
Thanks for your answer. But is there any workaround to solve this
issue? I want to use your grid for a protype for one of our biggest
customers.
It absolutely a knock-out-criterium to be unable to show possible
server-side-errors...

Thx in advance!

On 5 Aug., 19:51, fil_nitobi <filip....@nitobi.com> wrote:
> Hi gseagull,
>
> Thanks for taking the time to test out our new CUI.NET beta wrappers.
> If you have any feedback for us, suggestions, comments, things that
> you were expecting would be there but are missing, it would be great
> if you could let Nitobi know directly. This Google Group is aimed at
> development, support and discussion related to the JavaScript source
> code of Complete UI. If you have questions, comments or need support
> with the CUI.NET beta wrappers, feel free to submit a ticket with us
> athttp://nitobi.zendesk.com. I'm particularly interested in the
> > gseagull- Zitierten Text ausblenden -
>
> - Zitierten Text anzeigen -

filmaj

unread,
Aug 17, 2009, 12:26:21 PM8/17/09
to completeui
Hey,

The beta components do come with the source code for the ASP.NET beta
wrappers, so one 'workaround' would be adding that functionality in
yourself ;)

Essentially all that is required are a few modifications:
a) The XmlDataHandler class needs to be extended with a
setErrorMessage method. This method simply needs to add an 'error="my
error message here"' attribute to the <root> XML element in the XML
that is returned from the server to the Grid.
b) I believe the ClientEvents class needs to be extended so that you
can specify a JavaScript callback method to hook into the
OnErrorEvent. This extension would simply right out the
onerrorevent='JSCallbackFunction' attribute to the <ntb:grid>
element.
c) Finally, your callback should take as parameter an 'eventArgs'
parameter that contains some Nitobi-specific properties. In the case
of the OnErrorEvent, there should be an error property attached to
eventArgs which contain the error message that you set on the server.
Reply all
Reply to author
Forward
0 new messages