[Gambas-user] Replace (Internal) Error Message

Hans Lehmann hans at gambas-buch.de
Wed May 24 11:48:26 CEST 2023


Hello Lee.

Am 24.05.23 um 05:00 schrieb T Lee Davidson:
> I realize that you thought you needed to send your project to me 
> privately due to its size of 4.2MB which would not make it to the 
> list. And, that is the first reason I asked for a *small* project that 
> reproduces the error. The second reason is because, quite often, when 
> one isolates the issue in as small a project as possible that still 
> produces the error, the cause is found.
I had deleted almost all records - except for 2 - but had forgotten the 
command VACUUM;. That is why the database file remained so large, which 
is now only 650kB.
>
> However, in this case, a little more context, and accurate 
> information, from you in your original post would have been quite 
> helpful to prevent the misconception that we were dealing with an error.
> This helpful information would have been: 1) the procedure is handling 
> a DataControl Validation event, and 2) the the warning message is 
> being triggered by a STOP EVENT statement in the event handler - 
> however not actually in the procedure you told us, but in the 
> dcDate_Validation handler as you do not stop the dcFlower_Validation 
> event.
I will take this advice seriously and keep it in mind for further 
enquiries in the ML.
Right, I had forgotten the instruction `Stop Event `.
>
> It is not an error message. It is a warning message, and it is 
> expected behavior. And, BTW, the idea that the message is meaningless 
> is a matter of opinion.
> And so, to your question:
> Is there a way to replace the warning message, that is triggered when 
> a DataControl's value is invalidated, with a meaningful warning 
> message of my own?
All right, the message is a warning with a general reference. My only 
concern was to suppress this general warning and replace it with a 
separate, more meaningful message. This is obviously not possible 
without interfering with the Gambas source text.
>
> I don't see any way to do that - short of hacking on Gambas itself. 
> Maybe others have some ideas.
With kind regards

Hans
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.gambas-basic.org/pipermail/user/attachments/20230524/e0b40181/attachment.htm>


More information about the User mailing list