Welcome! Log In Create A New Profile

Advanced

Accessing outlook via WebDev-12 Application

Posted by Shahine 
Shahine
Accessing outlook via WebDev-12 Application
August 20, 2008 12:59PM
Hi,

I am trying to read the contact list from Outlook in a WebDev-12 application and display the email addresses in a combo-box.

I have used the following code:

------------------------------
id is Int
email_add is string
profile_name is string

profile_name = "Outlook"
id = OutlookStartSession(profile_name)
IF id = 0 then
Error(ErrorInfo())
ELSE
ContactFirst(id)
ListDeleteAll(Combobox)
WHILE mContact.Out = False
email_add = mContact.Email
ListAdd(Combobox, email_add)
ContactNext(id)
END
END
EmailCloseSession(id)
---------------------------------

This works perfectly on my development pc (Vista SP1), but when I deploy the application to another identical Vista SP1 pc it fails with the error:

Unable to open session with the "Outlook" profile. Invaild window handle. id=0

I have tried it with blank profile name (instead of Outlook). On my development pc I get a list of profiles to choose from. On the destination pc I get the error:

Unable to open session with the "" profile. Invaild window handle. id=0


Is anybody else getting this? Any help will be very much appreciated.

Shahine
Mail@Shahine.co.uk

Author:

Your Email:


Subject:


Spam prevention:
Please, enter the code that you see below in the input field. This is for blocking bots that try to post this form automatically. If the code is hard to read, then just try to guess it right. If you enter the wrong code, a new image is created and you get another chance to enter it right.
Message: