martes, 4 de octubre de 2016

Sending SMS from Dynamics NAV with 5 lines of code


Step 1

Setup the mobile to synchronize all with the exchange, mainly the SMS. Just follow standard procedure.

Step 2

Create code in NAV, which will send the SMS. It is easy:
SendSMS(ToNumbers : Text[30];Body : Text[1000])
  if ISCLEAR(OutlookApp) then
  MobileItem := OutlookApp.CreateItem(11); //11 – SMS, 12 – MMS
  MobileItem.”To” := ToNumbers; //e.g. +420666777555
  MobileItem.Body := Body;
OutlookApp    Automation    ‘Microsoft Outlook 14.0 Object Library’.Application   
MobileItem     Automation    ‘Microsoft Outlook 14.0 Object Library’.MobileItem   

Step 3

Call the function where you need. You need to just run it under profile, which have outlook set to syncing SMS with phone. It will create the sms, and after the sms is synced into the mobile phone, the mobile phone will send the SMS for your wherever you want. If you want to have central sending machine, use the NAS or WebServices to send SMS based on some queue…

Some examples of usage:

Sending SMS to admin when session limit is reached (using NAS).
Sending SMS to customer when order is prepared to ship.

No hay comentarios.:

Publicar un comentario

Dynamics Community Victor Parada's Activities

Entrada destacada

Plex, o que é e como funciona?

Certamente, em mais de uma ocasião, você ouviu falar do Plex como uma ferramenta que as pessoas chamam de solução definitiva para assis...

Crypto Currency News

Crypto Currency News

Jornal de Notícias - Nacional

Crypto Currency News

Crypto Currency News

Colombia News | Colombia Reports

Crypto Currency News

Playboy Enterprises


Microsoft Research Downloads Latest Stories Latest Stories

2016 USA Election Central

Gaming - NVIDIA Newsroom

Latest Xbox One Game Metascores on Metacritic

Latest Xbox 360 Game Metascores on Metacritic

Latest PC Game Metascores on Metacritic