NetTalk Central

Author Topic: How to Trap and Display RI Error to end user  (Read 2810 times)

Neil Porter

  • Jr. Member
  • **
  • Posts: 88
    • View Profile
    • Email
How to Trap and Display RI Error to end user
« on: July 16, 2012, 05:03:22 AM »
I've seen a few threads on here about error messages, but I can't see any that refer to capturing ABC error messages.

Assuming that I have setup my RI in my clarion dictionary, to prevent a parent record being removed if a child record exists, is there any way that I can pass the standard clarion RI warning message back to my end user if they try to delete the parent record?

At present the error displays on the Webserver, and the client just fails to see their record being removed. Do I have to build in additional checking in my app to display a message to the user before my standard clarion error gets raised?

I don't want to build in a load of extra code if I'm missing a trick somewhere.

TIA,

Neil.

Clarion 11.0.13244
NetTalk 11.04

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11250
    • View Profile
Re: How to Trap and Display RI Error to end user
« Reply #1 on: July 16, 2012, 07:53:52 AM »
it's not easy to display this meesage to the user, because there's no route back from inside the ABC library.

so what I would do is;
a) suppress ABC messages  (using MessageBox or whatever)
or
b) Make the Delete button "conditional" - ie make the dele button "in row" and then do your own check to see if a delete is allowed on that row.

cheers
Bruce

Neil Porter

  • Jr. Member
  • **
  • Posts: 88
    • View Profile
    • Email
Re: How to Trap and Display RI Error to end user
« Reply #2 on: July 16, 2012, 08:08:21 AM »
Thanks Bruce,

I'll give that a go. I guessed that it wouldn't be trivial to pass the error back, but I wanted to be sure that you hadn't built in some "trick" that I hadn't noticed.

Cheers!
Clarion 11.0.13244
NetTalk 11.04