Important Notice: Our web hosting provider recently started charging us for additional visits, which was unexpected. In response, we're seeking donations. Depending on the situation, we may explore different monetization options for our Community and Expert Contributors. It's crucial to provide more returns for their expertise and offer more Expert Validated Answers or AI Validated Answers. Learn more about our hosting issue here.

How are errors handled?

errors handled
0
Posted

How are errors handled?

0

All the RainierFun components handle errors using a similar mechanism. Each time a function is called, information is written to a.ERR file (eg RNWINFUN.ERR). This information includes the return code and any error text and is written whether the function succeeded or failed. The error information can be returned to the COOL:Gen action diagram with functions included in the components (e.g. rnGetLastErrorNumber and rnGetLastErrorText). Most functions return negative values in error situations so after a call to a function you may include logic like this: IF local ole return_code IS LESS THAN 0 SET local ole return_text TO local ole guiobject .rnGetLastErrorText … (error display and/or handling) This means that you can trap errors, display your own message boxes if you wish and take any other appropriate action. This is not generally possible when driving OLE servers natively with COOL:Gen.

Related Questions

What is your question?

*Sadly, we had to bring back ads too. Hopefully more targeted.