NetTalk Central

Author Topic: MessageBox problem?  (Read 4487 times)

ccordes

  • Sr. Member
  • ****
  • Posts: 384
    • View Profile
    • Email
MessageBox problem?
« on: August 29, 2010, 09:06:06 AM »
I just started using messagebox in this C7 project and came across some problems with the dictionary. I'm wondering is it me or have others seen this.
The dictionary TXA file would not import. Kept giving me duplicate field error.
So I created a new C72 dictionary and imported it.Then imported it into my dictionary. Same error.
Then I used the synchronizer, which brought the logfile over, but pointed out the error.
Longs had no lengths.
Back in the C72 dictionary, I changed all the longs to strings and then back to longs.
Now both the text and sync import worked.

MessageBox is now logging errors.

Chris
Real programmers use copy con newapp.exe

rjolda

  • Sr. Member
  • ****
  • Posts: 329
    • View Profile
    • Email
Re: MessageBox problem?
« Reply #1 on: August 30, 2010, 05:02:28 PM »
Hi Chris,
How are you using Message box to log errors?
Sample code?
THanks,
Ron Jolda

ccordes

  • Sr. Member
  • ****
  • Posts: 384
    • View Profile
    • Email
Re: MessageBox problem?
« Reply #2 on: August 31, 2010, 07:32:28 AM »
Ron,
First you need to import the messagebox txd into your dictionary. Let me know if you need my updated one.
Then run the MB import application Utilty

Add the global extension and
set to Use Threaded
check the use MB for All message types
MB with features
Automatically Log Messages

In Features, Set thet imeout for messages - I use a global variable here so I can change it to sit for a while for debugging.

Then in code, if there is an error I want to log, I just use message('Here is an error!')
Done- it goes to the log.
In my data.dll, if there is a situation like renumber or automatically increment fails and the default answer is button:yes to retry - this would cause the system to log the error and retry
So in the messagebox procedure, ds_messagebox, in the ThisMessageboxLogInit embedI put
    if instring('RETRY?',upper(LMBD:MessageText),1,1)
        LMBD:Defaults=BUTTON:NO
    END
That sets the default to retrying things to NO automatically.
The timed response to a message is always the default.
HTH
chris
Real programmers use copy con newapp.exe

rjolda

  • Sr. Member
  • ****
  • Posts: 329
    • View Profile
    • Email
Re: MessageBox problem?
« Reply #3 on: August 31, 2010, 05:01:51 PM »
Kewl,
Did you update the MB dct?  Did you add a table for your messages?
Can you make the updated MB dct available?
THanks,
Ron

ccordes

  • Sr. Member
  • ****
  • Posts: 384
    • View Profile
    • Email
Re: MessageBox problem?
« Reply #4 on: August 31, 2010, 05:57:47 PM »
Here is the C72 exported MB dictionary
Rename it to .dctx for use in C72

HTH,
chris

[attachment deleted by admin]
Real programmers use copy con newapp.exe

rjolda

  • Sr. Member
  • ****
  • Posts: 329
    • View Profile
    • Email
Re: MessageBox problem?
« Reply #5 on: September 01, 2010, 04:10:49 AM »
Thanks,
WIll give it a try!
Ron