PC Review


Reply
Thread Tools Rate Thread

How do I turn the message off?

 
 
vincent
Guest
Posts: n/a
 
      27th Nov 2008
I get following message every time my program execute.

"A program is trying to access e-mail addresses you have stored in Outlook.
Do you want to allow this?"

How do I turn the message off?

Following is the message
http://cid-29b22a6e2be1baca.skydrive...%20message.JPG

Following is my source code.
private void button_Start_Click(object sender, EventArgs e)
{
MAPI.Session oSession;

// Create session and logon
Object[] argsLogon = new Object[7];

oSession = new MAPI.Session();

// Will use vEmpty for Empty parameter
Object vEmpty = Missing.Value;

// Logon
oSession.Logon(vEmpty, vEmpty, false, false, vEmpty, vEmpty,
vEmpty);

// Get the folder
MAPI.Folder inboxFolder = oSession.Inbox as MAPI.Folder;

// Enumerate messages
MAPI.Messages messages = (MAPI.Messages)inboxFolder.Messages;
MAPI.Message message = (MAPI.Message)messages.GetFirst(null);
int findedCounter = 0;

while (message != null)
{
// do stuff with the message
if (GetRK(message.Text.ToString(), this.textBox_RK.Text))
{
findedCounter++;
this.label_Result.Text = "Found";
//display data
//DisplayData(message);
this.label_Subject.Text = message.Subject.ToString();
MAPI.AddressEntry Sender =
(MAPI.AddressEntry)message.Sender;
this.label_Sender.Text = Sender.Address.ToString();

MAPI.Recipient recipient;
int i = 1;
object index = i;
MAPI.Recipients Recipients =
(MAPI.Recipients)message.Recipients;
int totalRecipientCount = (int)Recipients.Count;
string recipients = string.Empty;

for (int j = 0; j < totalRecipientCount; j++)
{
recipient =
(MAPI.Recipient)Recipients.get_Item(index);
recipients = recipients + recipient.Name.ToString()
+ ", ";
i++;
index = i;
}
recipients = recipients.TrimEnd(',');
this.label_Recipients.Text = recipients;

this.label_Text.Text = message.Text.ToString();
}
message = (MAPI.Message)messages.GetNext();
}

if (findedCounter <= 0)
{
this.label_Result.Text = "not found";
}
}
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
How do you turn message off The Old Fart Windows XP Help 1 12th Dec 2007 02:25 AM
How do I turn this message off? Barry Watzman Microsoft Outlook 0 9th Sep 2006 05:08 PM
Choose this to turn on encryption for this message. The message will be sent in encrypted form. However, it can't be sent unless you have valid certificates for all recipients. 34 Microsoft Access 1 27th Nov 2005 08:58 PM
Turn Off Message Box Owen WIlson Microsoft Access Form Coding 1 3rd Jan 2005 04:33 PM
Turn Off Pop-Up Message Jolly Ollie Microsoft Outlook Third-Party Utilities 3 6th Sep 2004 02:23 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 06:38 PM.