Link with outlook

I am trying to export data to MS Outlook via automation (i.e. appointments) but the date and time format of MS Outlook is different than the NF format. Any suggestions?

I have seen the subject discusses on mynavision.net

Tx

Great, tx.

I want to read messages from Outlook for treatment in Navision. What i do that ? Thanks Ph TORRES

Philippe, For reading e-mails I would use the Outlook Automation but rather MAPI automation. The reason is simple: You want to be able to read e-mails no matter which program (Outlook, Outlook Express, Pegasus, Lotus Notes) is the default MAPI client. You find examples about allocating the necessary variables in Codeunit 397. Processing an incoming mail is only possible if the data you want is either stored as attachment or the body-text has < 250 Characters. I didn’t figure out any way to store a >250 Character Message-body within one or more Navision variables. Marcus Marcus Fabian phone: +41 79 4397872 m.fabian@thenet.ch

I think you can increase it to 1 Kb if you add strings: txt1 + txt2 + txt3 + txt4.

No luck, Augustin. None has yet found a way to get more than 250 characters in the message body. I did some playing with the binary type of variable (can hold 2000 bytes), but even then the text is truncated at 250 characters. Some searching in other sources learned me that the length of the bodytext message “can be restricted by the maximal length of textvariables in the development environment” As we all know, text variables in Navision are limited to 250 characters, so it is by now quite safe to assume that you can not get beyond. John

So again you could maken an OCX that reads the entire mail-body, counts the number of Chars, and devides the body in strings with a maximum length of 250. Should’mt be a problem in Visual Basic, I think. Martin Pennings Sittard Netherlands

Martin, Again no luck. It the passing of the text in whole to the Automation controller that’s restricted. Concenating strings has been (obviously) the first thing to experiment with. For your interest, it was the VB MSDN Help that pointed me to the said Automation limitations. In VB you won’t have the problem, as there strings can be 2 GB if you want. Might be a solution to create an OCX in between NF and Automation, which you can feed with as much text as you like. Or you might want to look up previous discussions on this topic. It has been noted that a single text attachment will show up as body text. Just an idea, but then you could create a temp text file, attach it and delete after the mail has been sent. John (ook uit Holland :slight_smile: )

I managed to put an unlimmited amount of text in the mailbody. This should also work the otherway around: You could import an unlimmited amount of text,with only one restriction: You have to determine the size of the text in advance. This is simply done by using arrays, and an OCX. The method is as following: You can e.g. Export 2500 char by making an 10-dimensional array. Since Navision can handle a total length of 1000000 in an textarray, it should be possible to read about any mailbody. The problel is that you have to make 1000000/250=4000 textboxes on a form, just to make sure you can read everything. …still working on that. Martin Pennings Sittard Netherlands Edited by - anolis on 10/20/00 11:55:01 AM