Global User Messages

Is there any way to send a message to all the user, currently logged into the Navi database? In the form of pop-up form or message? Steve Florko NCPS,NCSD,NCDS,WSSD,WSWD Application Development

Add a new field to the User Table called Message. Created a unbound form with a global variable of text type 250 characters in length. Place a command button on the form called Send. Write code to populate each user record with the value from the global. Create a form Bound to the user table. Set the timer property of the Main Menu to 300,00 (5 mins) Add a global variable of record type called User attached to the system User table. Add code to the OnTimer trigger of the Main Menu such as: User.Get(USERID); if User.Message <> ‘’ Then Begin SETRANGE(“User ID”,USERID); FORM.RUNMODAL(Forms::“Message Form”,User); User.Message := ‘’; User.MODIFY; End; If have used the above idea before. In fact, I have developed a fully functional internal e-mail system that runs inside Navision. It’s based on the idea above but, much more complex. Bill Benefiel Manager of Information Systems Overhead Door Company billb@ohdindy.com (317) 842-7444 ext 117

Does anyone have idea, how it will be possible without ON_TIMER triger? With regards, AiNuKoVarNjemties

You could put the code into one of the static triggers (such as OnOpenForm). Of course it will fire only if the trigger is activated. Then, you could put it into table triggers, such as OnModify or onInsert. However, if a user is idling, the message will never be delivered. Be careful with onTimer - it hammers database with requests, which creates server utilization and network traffic ramifications. Regards, Alex

Without using ON Timer, you might be able to have the main menu form instantiate a code unit that listens to an event triggered by an external object. But why not just use message ability built into the OS, IM, or an email system? Any particular reason to build it inside Navision? Jim Hollcraft NCSD, NCSP, MCSE, CNE, MCP, MST aka Skater http://drilldot.com Unauthorized Navision News

Hi Jim

quote:


Without using ON Timer, you might be able to have the main menu form instantiate a code unit that listens to an event triggered by an external object.


Could you please explain it litter more with same exmaple about this concept. Regards Joseph Mathew

In version 3.0 (and apparently in a version also called 2.65 which I’ve not seen), you can define a variable of type automation and set that variable’s property “With Events” to True. That adds triggers to the form for the events of that object. When the autmotion object raises/triggers an event, the main menu might be able to take action to notify the user of something. This might work just like “on timer” suggested above but would not use “on timer” or require the main menu to execute code every few seconds. I’ve not tested this so I don’t know if it would work for sure. You might need to write an automation server with VB or something in order to notice a message exists and then raise the event to Navision. Jim Hollcraft NCSD, NCSP, MCSE, CNE, MCP, MST aka Skater http://drilldot.com Unauthorized Navision News Edited by - Jim Hollcraft on 2001 Jun 15 15:27:54