Options

PopUp when notified

BeliasBelias Member Posts: 2,998
edited 2009-10-21 in NAV Three Tier
NAV 2009 SP1, SQL, 3 tiers

Hi everyone, this is a thing a customer ask us (and i already didn't suggest him to do it)...
Anyway, i think it would be cool to know how to do it, and we can learn something if we solve this (in my opinion).

Request: they want a popup message with ("you have been notified!") when a customer is notified (with standard notification system: e.g. adding a note on a sales order)

How Can I achieve this?
i thought to automatically open the notification page and then use a controladdin with a timer event in this page to check if there are new lines for my userid in table 2000000068. It works, but it can generate problems like ("multiple requests have been sent...etc etc)...and i don't like timers :whistle:

Then i thought to add a controladdin with event "onchangetext" (or something similar, i don't remember the exact name of the event) with the counter of the lines for my user...no luck, if the form is minimized, and if the notification is sent by a colleague of mine, i don't receive any message...

Someone has ideas?thanks in advance
-Mirko-
"Never memorize what you can easily find in a book".....Or Mibuso
My Blog

Answers

  • Options
    matttraxmatttrax Member Posts: 2,309
    I think your best bet is to think outside NAV. My thought would be to create a small outside application, like the NAV Search feature from the VPC if you remember that.

    In a very limited, basic way, you're trying to make an instant messenger client. Or something similar to the "You have an email" thing that pops up in Outlook. Probably don't want a message to pop open as that could be kind of annoying to the user (or could just be my preference).

    Anyway, just an idea. Hope it helps.
  • Options
    TroelshTroelsh Member, Microsoft Employee Posts: 79
    Agree, use Microsoft Office Communicator, Live Messenger or Outlook to do the trick - they are far better at doing messaging :wink:

    A simple sample that will create a mail - to be used in OnInsert trigger in table 2000000068 :

    Create an Automation varaible : "mailshell" type:Automation subtype: 'Microsoft Shell Controls And Automation'.Shell

    OnInsert()
    IF Notify THEN
    BEGIN
    CREATE(mailshell,FALSE,ISSERVICETIER);
    mailshell.Open('mailto:' + "To User ID" + '&subject=Notified&body=this is the mail body');
    CLEAR(mailshell);
    END;

    - hope this will get you started. Do also take a look at 'Messenger API Type Library' for Messenger interfaces

    Troels Bent Hansen
    Senior Program Manager
    Microsoft Dynamics NAV


    ****** This posting is provided "AS IS" with no warranties, and confers no rights ******
  • Options
    BeliasBelias Member Posts: 2,998
    i proposed to use an e-mail, but they don't want...i'll try with messenger, if they've not locked it with websense or similar...
    For clarity, in the previous system they had popup messages, maybe they're used to receive them...
    BTW, as i said, i tried to make them use standard notification functionality: i can open a page with notifications on the login (cu 1), and force the user to answer a CONFIRM in order to close this minipage...the page is automatically refreshed if you receive a notification: you have only to reclick the page if you've minimized it...
    -Mirko-
    "Never memorize what you can easily find in a book".....Or Mibuso
    My Blog
  • Options
    kinekine Member Posts: 12,562
    I was thinking about small Gadget for that to see the notifications in it and when you want, you open NAV 2009 through hyperlink directly to the page. Than users which needs to open the NAV only when needed doesn't "block" one session just to know if they need to do something... ;-)
    Kamil Sacek
    MVP - Dynamics NAV
    My BLOG
    NAVERTICA a.s.
  • Options
    BeliasBelias Member Posts: 2,998
    good point, kine...unfortunately, i think this gadget should be a .NET application, which i don't know at all :whistle:
    -Mirko-
    "Never memorize what you can easily find in a book".....Or Mibuso
    My Blog
  • Options
    kinekine Member Posts: 12,562
    No, it is just simple "web page" (HTML, Java Script, CSS)... :-)
    Kamil Sacek
    MVP - Dynamics NAV
    My BLOG
    NAVERTICA a.s.
  • Options
    BeliasBelias Member Posts: 2,998
    to be more specific: i only know c/al and a little (very little) of SQL... :oops:
    -Mirko-
    "Never memorize what you can easily find in a book".....Or Mibuso
    My Blog
  • Options
    kinekine Member Posts: 12,562
    May be time to learn something new... 8)

    I do not know if SingleInstance codeunits are working on RTC or not... :-k
    Kamil Sacek
    MVP - Dynamics NAV
    My BLOG
    NAVERTICA a.s.
  • Options
    BeliasBelias Member Posts: 2,998
    May be time to learn something new...
    you're right, i think i'll focus on c# when i've some free time...up to now, i've got so much work that in the evening i only want to go out or do something else other than studying
    I do not know if SingleInstance codeunits are working on RTC or not...
    this is a question i want to answer before or after...will the values remain on the middle tier (for all users)? or on the client or not at all?
    -Mirko-
    "Never memorize what you can easily find in a book".....Or Mibuso
    My Blog
  • Options
    kinekine Member Posts: 12,562
    What I remember, singleinstance CU are problematical one, because the connection to NST is state-less if I remember correctly, it means each request to NST is without context to something else. But I am not sure about that. There is lot of things which were changed since that...
    Kamil Sacek
    MVP - Dynamics NAV
    My BLOG
    NAVERTICA a.s.
  • Options
    BeliasBelias Member Posts: 2,998
    just tried with a colleague of mine...the SingleInstance works client by client as expected (in other words, my message returns 1 and her message returns 0)...it would have been cool to be able to save a value for everyone
    -Mirko-
    "Never memorize what you can easily find in a book".....Or Mibuso
    My Blog
  • Options
    kinekine Member Posts: 12,562
    Belias wrote:
    just tried with a colleague of mine...the SingleInstance works client by client as expected (in other words, my message returns 1 and her message returns 0)...it would have been cool to be able to save a value for everyone

    You mean to save the value into table that others could read it? :-D
    Kamil Sacek
    MVP - Dynamics NAV
    My BLOG
    NAVERTICA a.s.
  • Options
    BeliasBelias Member Posts: 2,998
    kine wrote:
    Belias wrote:
    just tried with a colleague of mine...the SingleInstance works client by client as expected (in other words, my message returns 1 and her message returns 0)...it would have been cool to be able to save a value for everyone

    You mean to save the value into table that others could read it? :-D

    Exactly!(i already tried with real tables, but it works only for notifications form me to me...which is quite useless :) )
    -Mirko-
    "Never memorize what you can easily find in a book".....Or Mibuso
    My Blog
Sign In or Register to comment.