Easy to Create, Easy to Change - Easy to use!

Function::CDF

Message



Parameters


Returns/Result


Examples


Reference

REFERENCE FOR MSGBOX.DLL

DISCLAIMER:

This CDF is provided for illustration purposes only of the uses for a Custom Defined Function within DataEase for Windows. This

CDF is provided 'As is' with no warranty whatsoever, either expressed or implied. DataEase International, Inc. does not

warrant the CDF to be error free, nor does it warrant the CDF to meet your specific requirements. In addition, this CDF is not

approved for use, nor is it subject to Technical Support by DataEase International, Inc.

FUNCTION:

MESSAGE ( Message Text , Caption Text , Icon , Buttons , Beep )

PURPOSE:

Displays a custom Windows message box allowing the application developer to specify a custom message, message box title, a message

icon, various button combinations for dispatching the dialog and an audible beep. This function can be used alone or in conjunction with

other DataEase for Windows functions. The function returns an integer value corresponding to the Users response in dispatching the dialog.

PASSING ARGUMENTS:

1. Message Text: a text message the application developer wishes to display.

2. Caption Text: a 50 character string used as the title for the message dialog.

3. Icon: an integer value that specifies what type of icon to display in

the message box.

1 Information Icon ( i )

2 Exclamation Icon ( ! )

3 Stop ( Stop sign )

4 Question ( ? )

5 No icon

4. Buttons:

an integer value that specifies what combination of buttons to

be displayed in the message dialog for the user to use in

dispatching the dialog and sending return values back to the

function.

0 (default) OK

1 OK CANCEL

2 RETRY CANCEL

3 ABORT RETRY CANCEL

4 YES NO

5 YES NO CANCEL

5. Beep:

an integer values that specifies what type of audible beep to

generate according to a given system alert level. The sound for

each alert level is determined by an entry in the [sounds]

section of WIN.INI.

0 or 1 (default) no sound

2 System sound

3 Information sound

4 Exclamation sound

5 Stop sound

6 Question sound

7 OK sound

RETURN VALUES:

Each message dialog you display will include at least one push button

for the user to dispatch the dialog. When a button is pressed, the

Message function returns an integer value indicating that it received

a user response and DataEase will continue processing. The following

return values correspond to the available buttons for display:

1 ABORT

2 CANCEL

3 IGNORE

4 NO

5 OK

6 RETRY

7 YES

0 Out of Memory

TIP:

Since the function returns an integer value, it may be awkward when

using Message in field derivations. The following example

illustrates one way to use Message:

SCENARIO:

We have a form with a date field called DEPARTURE DATE, and we

want to display a message when the user enters a date that is

prior to today's date (e.g. it's difficult to leave when you

already have). However, if the user enters a date after Today's

date, we want to display a message that indicates on what day of

the week that date occurs.

Field: DEPARTURE DATE

Derivation Formula:

if ( DEPARTURE DATE < current date ,

if ( Message

( jointext ( "The date you entered: " ,

jointext ( DEPARTURE DATE , " is invalid. \n\t

Do you want today's date?" )

) ,

"Invalid Date Message" , 4, 4, 6 ) = 7 ,

if ( Message

( jointext ( "Your entry date will be replaced with

today's date: " , current date ) ,

"Enter Current Date", 1, 0, 3 ) = 5, current date ,

current date ) ,

if ( Message

("Your entry will be discarded and the field will be

left blank." ,

"Discard Entry Date" , 2, 6, 4 ) = 5 , blank, blank )

) ,

if ( Message

( jointext ( "The date you entered: " ,

jointext ( DEPARTURE DATE,

jointext ( " is a " ,

spellweekday ( weekday ( DEPARTURE DATE ) ) ) ) )

"Day of the Week", 4, 4, 6 ) = 5 ,

DEPARTURE DATE , DEPARTURE DATE ))

NOTE: the symbols /n/t on line 4 tell Windows to display a

<newline> and <tab>.

FUNCTION:

BEEP ( Beep )

PURPOSE:

Generates an audible sound from the PC's speaker.

PASSING ARGUMENTS:

1. Beep:

an integer values that specifies what type of audible beep to

generate according to a given system alert level. The sound for

each alert level is determined by an entry in the [sounds]

section of WIN.INI.

0 or 1 (default) no sound

2 System sound

3 Information sound

4 Exclamation sound

5 Stop sound

6 Question sound

7 OK sound

RETURN VALUE:

The return value means nothing and can be discarded or ignored.

INSTALLATION OF MSGBOX.DLL AS A DataEase for Windows CDF:

Open the application within which you wish to integrate the function.

From the Menu Bar, select APPLICATION - CUSTOM FUNCTIONS. Fill in the

form as shown below and press F2 for each function (both functions are

contained in the same DLL).

Function Name: MESSAGE

OS Type: WINDOWS

Description: DISPLAYS CUSTOM MESSAGE BOX

CDF Library Name: MSGBOX.DLL

Return Type: INT

DOS Mem Req't:

DOS Entry Point:

Parm 1 Name: TEXT MESSAGE

Parm 1 Type: STRING

Parm 2 Name: CAPTION TITLE

Parm 2 Type: STRING

Parm 3 Name: ICON DISPLAY

Parm 3 Type: INT

Parm 4 Name: BUTTON SELECTION

Parm 4 Type: INT

Parm 5 Name: BEEP SOUND

Parm 5 Type: INT

Parm 6 Name:

Parm 6 Type:

Parm 7 Name:

Parm 7 Type:

Parm 8 Name:

Parm 8 Type:

Parm 9 Name:

Parm 9 Type:

Parm 10 Name:

Parm 10 Type:

Function Name: BEEP

OS Type: WINDOWS

Description: MAKES AN AUDIBLE BEEP

CDF Library Name: MSGBOX.DLL

Return Type: INT

DOS Mem Req't:

DOS Entry Point:

Parm 1 Name: BEEP SELECTION

Parm 1 Type: INT

Parm 2 Name:

Parm 2 Type:

Parm 3 Name:

Parm 3 Type:

Parm 4 Name:

Parm 4 Type:

Parm 5 Name:

Parm 5 Type:

Parm 6 Name:

Parm 6 Type:

Parm 7 Name:

Parm 7 Type:

Parm 8 Name:

Parm 8 Type:

Parm 9 Name:

Parm 9 Type:

Parm 10 Name:

Parm 10 Type:

See Also


On the forum about Message

Help with Displaying Instruction / Help message text in a fields

Hey folks - I've seen where DE8 can display an instruction / help message in a field when the field is blank or when the cursor is not in the field. &nbsp;This is not the typical Help message that appears in the bottom Help message display area. &nbsp...

Product: Dataease [{8}]FIVE. Written by dtagcayman@yahoo.com 30/08/14 at 08:05:55

Re:Help with Displaying Instruction / Help message text in a fields

HiTo display a message in the field do as follows:Click on the Help tab withing the field definitionType: &nbsp; &nbsp;&nbsp;...

Product: Dataease [{8}]FIVE. Written by Josef Vella 31/08/14 at 15:30:29

Re:Re:Help with Displaying Instruction / Help message text in a fields

Hi Josef - Your instructions worked Perfectly ! &nbsp; Simple yet effective feature. &nbsp;Now&nbsp;I'm now adding the prompts and it will be a great help for the users.&nbsp;Many thanks!-Robert...

Product: Dataease [{8}]FIVE. Written by dtagcayman@yahoo.com 01/09/14 at 03:56:36

error message

I am currently working on a database developed in DataEase Version 7.2.3.947 and run a procedure on a workstation generates sisguiente me Error.---- Sat February 01 2014 12:01:05 ---- OPERACIONES_NOVEDADES_PUESTOS: - running procedure: #...

Product: DataEase for Windows 7.x. Written by diego fernando Ocampo 09/09/14 at 16:04:21

User Level error message

I am using Version 8.2.0.1631.When trying to save the DQL shown I am getting an error message referring to the user level (Which is high in this case) and I cannot see the relevance of the user level here - Any suggestions as to what might be h...

Product: Dataease [{8}]FIVE. Written by Peter Birney, PB Associates 01/10/14 at 11:19:35

Re:User Level error message

We will need the application to have any educated guess. I was using the "exact" same DQLi.e. copy all from yesterday without any problems in the same version so this most be app specific. To make sure just make a simple sample and see if &nbsp;you ge...

Product: Dataease [{8}]FIVE. Written by DataEase Tech Sup. 01/10/14 at 11:32:10

Re:Re:User Level error message

Here is a simple database containing just the forms referenced and any needed to satisfy relationships (The relationships also exist as in the original).&nbsp; The username is Peter with no password.&nbsp; Go into DQLs, load "pobtest" and try and save...

Product: Dataease [{8}]FIVE. Written by Peter Birney, PB Associates 01/10/14 at 14:27:59

Re:Re:Re:User Level error message

Sorry, should have spotted this on your first message but it is always easier when one can play with a sample."Can't see&nbsp;the forest for all the trees" is a saying and this is exactly what we have here.<br...

Product: Dataease [{8}]FIVE. Written by DataEase 01/10/14 at 15:15:04

No messages during import or export operation

It's possible to avoid to display this message during an import or export operation? I suggest to use a "silent" parameter if it's possible. Thanks....

Product: Dataease [{8}]FIVE. Written by Marco Marchesi 01/12/14 at 09:10:22

Re:No messages during import or export operation

Dear Marco.Just to elaborate on this.&nbsp;Why is it a problem that the import show this information? What is the use case where you don't want it displayed?...

Product: Dataease [{8}]FIVE. Written by DataEase Development 01/12/14 at 18:31:59

Re:Re:No messages during import or export operation

I use import on some automatic procedure during the night and such procedures are blocked until I reconnect to the server again the next morning. I suspect that import/export use GUI that it's not available when the I'm not connected to the server. I...

Product: Dataease [{8}]FIVE. Written by Marco Marchesi 02/12/14 at 07:15:07

Re:Re:Re:No messages during import or export operation

Hello Marco. The problem with running Import on a schedule on the server is not related to the GUI messages. These messages for Import do not demand user interaction. When setting up the schedule you need to run the job with a...

Product: Dataease [{8}]FIVE. Written by DataEase 02/12/14 at 08:31:21

DBA Missing Error Message

One of my client getting DBA files are missing error in his database. This is only happening on few tables. And when he reorganize the database.Question is, is there an easy way to fix this via RDRR edit?...

Product: Dataease [{8}]FIVE. Written by Jeyarajah Arulrajah 30/01/15 at 16:15:02

Re:DBA Missing Error Message

This basically means that the .TDF is missing. Message is just so old that it say .DBA.in 8.2 you can delete a table even when the table is missing, so simply go to Tables in Catalog and delete the "offensive" tables.You will get a lot...

Product: Dataease [{8}]FIVE. Written by DataEase 30/01/15 at 16:40:43

Is MsgBox libray still available in DE8.2 ? If not, how messages should be handled?

[@EOF@]...

Product: Dataease [{8}]FIVE. Written by Francesco Toma 14/02/15 at 16:34:38

Re:Is MsgBox libray still available in DE8.2 ? If not, how messages should be handled?

MsbBox library was never an intergral part of DataEase. You always needed to add it to the application after creation.However in DE8 they get pre-loadedi&nbsp;n new applications so it is there but the problem is that it can be doubly defined i...

Product: Dataease [{8}]FIVE. Written by DataEase 15/02/15 at 12:59:05

Re:Re:DBA Missing Error Message

After working with my client, this is fixed now. All of these message came out of TEMP tables.Once we deleted those tables, everything is good....

Product: Dataease [{8}]FIVE. Written by Jeyarajah Arulrajah 16/02/15 at 01:19:28

Re:Re:Re:DBA Missing Error Message

It is normally temp tables that has been created in RDRR but where the .TDF/.DBM has successfully been removed, so simply to delete them in the Table View of the Catalogue will almost always be successful....

Product: Dataease [{8}]FIVE. Written by DataEase 16/02/15 at 09:34:04

Error message when trying to save DQL with .export

I have simple procedure that works both in Dataease for Dos and DEW 7.2. I have converted a customer database from 7.2 to 8.5 and get the following error. The procedure reads: for Subsriptions with Internet ID No. not = blank and any Customer...

Product: Dataease [{8}]FIVE. Written by Wim 19/02/15 at 09:03:19

Re:Error message when trying to save DQL with .export

Dear Wim.When you get a GPF on something like this the problem is most likely in the underlying table, as this happens when you compile/save the DQL it is most likely in the table structure. Try to open the table in design mode, add a text fiel...

Product: Dataease [{8}]FIVE. Written by DataEase 19/02/15 at 09:06:21

Re:Re:Error message when trying to save DQL with .export

I have tried as suggested and&nbsp;added a text&nbsp;field in the table but when I try to save it as suggested it returns "Error 503 Adding Field - Missing operator in formula" . I have tried this several time but each time I get the same message.&nbs...

Product: Dataease [{8}]FIVE. Written by Wim von der Becke 23/02/15 at 11:06:42

Re:Re:Re:Error message when trying to save DQL with .export

It sounds like the problem is in you exiting table. Is this a migrated or converted table?If there is a pre-existing problem then it will typically GPF.If it is a migrated app it can be related to , or . in numbers in derivations etc....

Product: Dataease [{8}]FIVE. Written by DataEase 23/02/15 at 11:18:40

GPF Message

Actually, I want to talk about this message. This message does not make any sense to me. Also I am sure, If I send this over to the programmer. It might take ages to tell where exactly problem...

Product: Dataease [{8}]FIVE. Written by Jeyarajah Arulrajah 02/06/15 at 15:18:46

Re:GPF Message

Hi Arul.I think we have talked about this message a lot before ;-)You can talk as much as you like but there is nothing anyone can do about this message.DataEase obviously have error trapping too, this is not part of that.<...

Product: Dataease [{8}]FIVE. Written by DataEase 03/06/15 at 08:06:29

F2 Functionaliaty in DFW vs DFD. Save new record with new Sequence number, no message.

I have a case related to the messages that DFW displays. If i have a form with Sequence ID, and it is a unique filed. In DFD if you don't make changes to the form and by mistake press the F2 button, you will be warned that no changes happened and ask...

Product: Dataease [{8}]FIVE. Written by Fatma Adel 05/11/15 at 17:30:42

Re:F2 Functionaliaty in DFW vs DFD. Save new record with new Sequence number, no message.

Hi Fatma. DFW is not DFD, and the DFD “feature” is more annoying in general than the fact that “Save as New” which is the name for F2 in DFW is. It is no secret that the biggest problem for DFW was that it was NOT DFD, a...

Product: Dataease [{8}]FIVE. Written by DataEase 05/11/15 at 17:32:38

Re:Re:Re:Re:Error message when trying to save DQL with .export

I'm having this same issue with error 503. I'm working in DE8.5 with a new build. ie not a migration or conversion. The table i'm working with was just created a few days ago.Has anyone else run into this issue?Kevin...

Product: Dataease [{8}]FIVE. Written by Kevin O'Donnell 15/06/16 at 13:06:42

What does this message mean when I am trying to define a relationship ? How do I fix it ? Please specify the Bound Field when trying to create a Lookup Field

[@EOF@]...

Product: Dataease [{8}]FIVE. Written by peadar Kearney 26/02/19 at 13:57:27

Re:What does this message mean when I am trying to define a relationship ? How do I fix it ? Please specify the Bound Field when trying to create a Lookup Field

Hi.&nbsp; DataEase has been managed by several different teams over the years and not all of them have been to into the lingo. I remember myself whe...

Product: Dataease [{8}]FIVE. Written by DataEase 27/02/19 at 09:42:38

Re:Re:What does this message mean when I am trying to define a relationship ? How do I fix it ? Please specify the Bound Field when trying to create a Lookup Field

Excellent.Thank you for the explanation, It is appreciated.Best Regards,Peadar...

Product: Dataease [{8}]FIVE. Written by peadar Kearney 27/02/19 at 23:19:40

Migration failure with Access Violation message

When investigating a customer's database to see if it will easily migrate to V8.5 from V6.52 I am getting failures of the migration when it is Reorganising Application Documents.For some reason even simple DQLs are failing with this error messa...

Product: Dataease [{8}]FIVE. Written by Peter Birney, PB Associates 08/03/19 at 17:22:44

Re:Migration failure with Access Violation message

Try to do a backup/restore of the 6.x application before migrating it.&nbsp;The problem in DFW is that everything is stored in Binary code which are loaded directly into memory. So if its corrupt it can cause all kinds of problems. GPFs does n...

Product: Dataease [{8}]FIVE. Written by DataEase 12/03/19 at 15:09:48

Re:Re:Migration failure with Access Violation message

A Backup/Restore had been done but the problems remained.The system is running successfully under 6.52 with no operational problems.I think that there must be a corruption somewhere not just because of the Access Violation errors but bec...

Product: Dataease [{8}]FIVE. Written by Peter Birney, PB Associates 14/03/19 at 12:09:50

Error Message

I am trying to modify an existing record in DE 8.5 and I'm getting this error message:Error 903 Saving Current ChangesRecord not modifiedAnyone know why this is happening and how I can fix it?...

Product: Dataease [{8}]FIVE. Written by Colleen Sienkiewicz 20/01/20 at 21:51:47

Re:Error Message

Hi. This simply means that the record could not be changed, specifically it means that the row in question was not changed.It can be a number of reasons for this.&nbsp;Is this something that happens all the time, or is it just one reco...

Product: Dataease [{8}]FIVE. Written by DataEase 21/01/20 at 11:45:37

Re:Error Message

We did some testing here and you will get this message if there is a problem with your data files or your data disk or server connection.If Dataease for any reason loose the file handle (timeout etc) it will not recover and you will get this e...

Product: Dataease [{8}]FIVE. Written by DataEase 21/01/20 at 16:16:30

Re:Re:Error Message

It was happening throughout the day&nbsp;yesterday to several users.&nbsp; Changes were being made to the main form only.Desktops are windows 10 The data resides on a Windows 2016 server...

Product: Dataease [{8}]FIVE. Written by Colleen Sienkiewicz 21/01/20 at 17:00:00

Re:Re:Re:Error Message

Hi again Coleen.We need to establish a timeline here. When was the first time this was experienced and what changed around this time?When did you change to Windows Server 2016 for instance or when did users get Windows 10 etc.Th...

Product: Dataease [{8}]FIVE. Written by DataEase 22/01/20 at 10:45:34

Error Messages

Can anyone assist with these error messages?&nbsp; The first comes up when I search.&nbsp; When I hit OK, the second one comes up and then the program crashes.&nbsp; &nbsp;Using version 8.5.1.2674<img src="data:image/png;base64,iVBORw0KGgoAAAAN...

Product: Dataease [{8}]FIVE. Written by Colleen Sienkiewicz 07/09/21 at 13:43:01

Re:Error Messages

Hi Colleen,I would reorganise the table referenced by CARD2-AS as a first step (Best to take a copy of the data beforehand in case of problems)....

Product: Dataease [{8}]FIVE. Written by Peter Birney, PB Associates 08/09/21 at 17:34:31

MemoExecDQL and Message

Hi all again,I've the code as follows in an DQL :DQL 677"define "act" text .define "imagem" text 30 .define "cod" text 13 .define "msg" number .Msg := message ( concat ( "Atencao! Detectada Producao em...

Product: Dataease [{8}]FIVE. Written by afonso santos 12/12/21 at 11:23:50

Re:MemoExecDQL and Message

One thing I forgot,If we remove the message function, the for and enter&nbsp;sequence are well executed .afonso...

Product: Dataease [{8}]FIVE. Written by afonso santos 12/12/21 at 11:34:38

Re:MemoExecDQL and Message

When I use that message I use it a slightly different way.Instead ofMsg := message </...

Product: Dataease [{8}]FIVE. Written by Paul Cheeseman 15/12/21 at 13:15:31

Re:Re:MemoExecDQL and Message

I just tested it, and it works the same both ways.&nbsp;...

Product: Dataease [{8}]FIVE. Written by Paul Cheeseman 15/12/21 at 13:23:45

Odd error message

Hello helpers.&nbsp; We are getting an error message, which prevents our accessing and running reports on an important part of our database.&nbsp; The message is AGRERAAH.DBA not found.&nbsp; How do I fix this?Background.&nbsp; We do have sever...

Product: Dataease [{8}]FIVE. Written by Bonnie Clarke 18/02/22 at 16:07:10

Error Message

Does anyone have any idea why I am getting this error pop up , my system has worked for many years without out issue, come in this morning and started to get this, I have tried re- install but issue still happens....

Product: LegEasy 6 Windows. Written by Handles 17/03/22 at 11:24:09

Re:Error Message

OK , tried everything with regards to updates etc, the only way around it was to system re-install to earlier date solved the problem. But would be interested to know if anyone else has also had this problem - message, and why. ...

Product: LegEasy 6 Windows. Written by Handles 17/03/22 at 13:51:59

Image and DataEase message

Any suggestion please:I fully understand why I am getting these messages , but I would like to know if there is anyway of stopping them, if a picture is not located in the file I am pointing DataEase too , could I just have a dummy message show...

Product: LegEasy 6 Windows. Written by Handles 25/03/22 at 20:18:15

Open Dataease and get error message "Table Name Already Exists"

[@EOF@]...

Product: DataEase 8.5 Runtime. Written by 01/02/24 at 11:45:58

On the blog about Message

New Small Sample - Self populating Dropdowns, Dynamic labels and messages (Ver 8.0.0.1298)

Download SampleThis small Sample is just a study as part of our new Sample App that will be a fully working CRM/Order/Invoicing system.8 is...

Product: Dataease [{8}]FIVE. Written by DataEase 24/05/13 at 17:28:25

DataEase 8.5 - New Function : Alert() - Simple Message function like Message (Command DQL) Ver 8.5.0.2453)

Nothing is more useful when you "debug" code than a simple message box that pop up and give you feedback.In DQL this has been there since forever but in Derivation/ Action etc. there has never...

Product: Dataease [{8}]FIVE. Written by DataEase 08/08/16 at 11:36:42