 |
|
|
Hi Can You please tell me how to do the same in Asp.Net. I am using Asp.Net 2.0 with C# and MS Outlook 2007.
Sagar Pattnayak Software Developer Sun-Dew Solutions +91-9831169962
|
| Sign In·View Thread·PermaLink | 1.00/5 (1 vote) |
|
|
|
 |
|
|
Hello,
I am still searching for a method which can convert the X.400 / X.500 e-mail adress into "smtp e-mail adress".
Is it possible to show the e-mail adress in smtp-Format.
I was not able to find in the net a good solution.
Is there a method for C# existing.
It would be great if someone can help me.
Thanks alot...

|
| Sign In·View Thread·PermaLink | |
|
|
|
 |
|
|
Any idea how to extract those free timing from microsoft outlook calendar (those timing that is without appointment) using visual basic or C#?
Btw...can it be done without using Microsoft Exchange Server?
Please Help... Thanks in advance
Best Regards, ClaudeX
-- modified at 5:31 Thursday 7th June, 2007
|
| Sign In·View Thread·PermaLink | |
|
|
|
 |
|
|
Hi Mathias,
This is a great article and I am keen to implement your OutlookCOnnector in my applications.
I have added references to both Microsoft.Office11 and Microsoft.Outlook11 into your code and I am still getting the "Namespace Outlook could not be found" error.
Do you have any further advice that will help me with this?
cheers, Mark Chimes
|
| Sign In·View Thread·PermaLink | |
|
|
|
 |
|
|
Hi All,
I solved this issue by place "Microsoft.Office.Interop." in front of every reference to "Outlook".
I guess this means my solution is not reading the added references properly, butat least it works this way.
cheers, Mark Chimes
|
| Sign In·View Thread·PermaLink | |
|
|
|
 |
|
|
I don't want any existing Outlook window to close after program execution, so i deleted the line: if (objOutlook != null) objOutlook.Quit(); New problem: tried exporting my contacts 3 times in a row first time: all 137 contacts exported second time: something between 4 and 124 contacts exported third time: always 0 contacts exported tried to open outlook -> error message, couldn't open my inbox anymore had to kill outlook.exe in the task manager to make it work properly again.
so my question is: isn't it possible to check for an existing outlook instance, and use this one instead of creating a new one ?
Any ideas ?
|
| Sign In·View Thread·PermaLink | |
|
|
|
 |
|
|
Hi,
While trying this code I encountered into a bug. The following code in OutlookConnector.cs, method getCalendarDataSet:
for (int i=0; i < objFolder.Items.Count; i++) { item = (Outlook.AppointmentItem) objFolder.Items.GetNext(); rv.Tables[0].Rows.Add(new object[] { item.Subject, item.Location, item.Start, item.End, item.AllDayEvent, item.Duration, item.Organizer, item.Importance, item.Sensitivity, item.Body }); this.ItemProcessed(); }
should be replaced with:
foreach (Outlook.AppointmentItem item in objFolder.Items) { rv.Tables[0].Rows.Add(new object[] { item.Subject, item.Location, item.Start, item.End, item.AllDayEvent, item.Duration, item.Organizer, item.Importance, item.Sensitivity, item.Body }); this.ItemProcessed(); }
and the definition of item earlier in this method should also be removed.
Cheers, Nadav
|
| Sign In·View Thread·PermaLink | |
|
|
|
 |
|
|
also 4 contacts imo
/*for (int i=0; i < objFolder.Items.Count; i++) { item = (Outlook.ContactItem) objFolder.Items.GetNext(); rv.Tables[0].Rows.Add(new object[] { item.FirstName, item.LastName, item.CompanyName, item.Email1Address, item.HomeTelephoneNumber, item.BusinessTelephoneNumber }); this.ItemProcessed(); }*/
foreach (Outlook.ContactItem item1 in objFolder.Items) { rv.Tables[0].Rows.Add(new object[] { item1.FirstName, item1.LastName, item1.CompanyName, item1.Email1Address, item1.HomeTelephoneNumber, item1.BusinessTelephoneNumber }); this.ItemProcessed(); }
old one return one value.. you should remove this one and repeate to my modification
my modification gives correct values
you should also correct other functions
-- modified at 7:27 Thursday 31st August, 2006
|
| Sign In·View Thread·PermaLink | |
|
|
|
 |
|
|
Hiya,
I am a bit Novice user here. i am trying to export data from a perticular folder from outlook to an access database or a sql server. Is it possible with this code. If yes i am not able to get my head around it. Can anybody help me.
Thanks
Ash
|
| Sign In·View Thread·PermaLink | |
|
|
|
 |
|
|
Hi,
I'm writing a similar application that retrieves contacts and appointments from a database to create them in Outlook 2003.
On some machine, I got an error of COMException when I try to retrieve the folder with the method GetDefaultFolder(OlDefaultFolders);
Example of code : objNamespace.GetDefaultFolder(OlDefaultFolders.olContacts);
I would like to know if you had experiment this kind of problem with your application and how to solve this.
Thanks
|
| Sign In·View Thread·PermaLink | |
|
|
|
 |
|
|
I am using Outlook similar to your example, but pulling in shared folders from Exchange. It is all working except that I cannot cast Items.Item to Contact.Item. I instead need to keep them as Object - which then uses late binding.
Since I am processing over 500,000 entries, I would like the performance boost of early binding.
Any ideas why Exchange won't allow the cast?
(I am also using the exact same code with the default Outlook folder and there the cast works fine. Just not with any shared folders.) Thanks!
|
| Sign In·View Thread·PermaLink | |
|
|
|
 |
|
|
hey howzit?
its easy to import contacts from outlook in code...but what i wanna do is be able to drag an outlook contact straight from the running Outlook Application itself into my running C# application...can anyone help?
So far I am able to drop random files into a listbox using this tutorial: http://www.csharphelp.com/archives2/archive365.html but its still doesn't provide me will the ability described above
|
| Sign In·View Thread·PermaLink | |
|
|
|
 |
|
|
Hi,
When I run the Outlook Connector and I want to export the appointments, I became always one appointment.
Where is the failure?
Greetz
|
| Sign In·View Thread·PermaLink | |
|
|
|
 |
|
|
Could this be modified to access any PST? I output PST files from kvs enterprise vault but then want to read each PST and parse out the data I need.
|
| Sign In·View Thread·PermaLink | 2.33/5 (3 votes) |
|
|
|
 |
|
|
While I was debbuging I found to an ineresting bug and exception that is swolen inside the code 
In class methods eg. LoadInboxItems and others where you are going to get next, at the last item objItems.GetNext() returns null value. The result is exception that is written to Console so without carefull looking it wanish and possibly won't be seen 
So the resolution is to modify code like this (in all methods working with GetNext() method of Outlook.Items collection of course):
outlookItem = objItems.GetNext(); if (outlookItem ==null) break;
P.S. It is wise to show Exception message to the user in such cases, or throw some custom message or handle it in some way that would be obvious to the user or fellow programer.
P.S.S Great work tough!!! Thx for the code!
Preky
|
| Sign In·View Thread·PermaLink | |
|
|
|
 |
|
|
When i try to run the code it is count the number of calendar items as 2 and contacts as 5 etc(and these figures are correct). But when the data is exported to xml both the items are same. That means under contacts there are 5 items but all the 5 are the same record. ie. the first record. Why is this happening like this. Also i did an iteration through the code runtime and i am storing subject and body in a temp variables. But those values are always having the same values (the 1st record). Can anybody tell me what is the change to be made to read record by record in contacts or calendar. Please help .
for (int i=0; i < objFolder.Items.Count; i++) { item = (Outlook.AppointmentItem) objFolder.Items.GetNext(); string sub = item.Subject; string bd = item.Body; rv.Tables[0].Rows.Add(new object[] { item.Subject, item.Location, item.Start, item.Body }); this.ItemProcessed(); }
|
| Sign In·View Thread·PermaLink | |
|
|
|
 |
|
|
I ran into the same problem and changed the code to make it work. Alternately, try getting version 1.0. In the release notes 1.1 he said he stopped using the the Enumerator and changed it to a for loop for compatibility with office 10. However, I think that broke the program for Office 11 (2003) as the GetNext() method on the Items collection doesn't seem to work properly, I kept getting the same item repeated over and over. This is what I did to get 1.1 to work. It worked for me but YMMV and all the usual disclaimers. Get rid of the For loop in the get*DataSet methods and make them while loops with the IEnumerator like this (this is for the OutlookConnector.GetInboxData() method)
System.Collections.IEnumerator MsgEnum = objFolder.Items.GetEnumerator(); while (MsgEnum.MoveNext()) { item = (Outlook.MailItem) MsgEnum.Current; rv.Tables[0].Rows.Add(new object[] { item.SenderName, item.To, item.CC, item.Subject, item.ReceivedTime, item.Body }); this.ItemProcessed(); }
|
| Sign In·View Thread·PermaLink | 5.00/5 (1 vote) |
|
|
|
 |
|
|
It changed the code bold line
for (int i=1; i <= objFolder.Items.Count; i++) {
item = (Outlook.MailItem) objFolder.Items.Item(i);
rv.Tables[0].Rows.Add(new object[] { item.SenderName, item.To, item.CC, item.Subject, item.ReceivedTime, item.Body });
this.ItemProcessed(); }
|
| Sign In·View Thread·PermaLink | |
|
|
|
 |
|
|
The code as written returns the same first item each time.
The reason is that every time GetNext is called the code retrieves a new instance of the Items object.
Solution: Store the Items object in a local variable to make sure you are always using the same instance
new code objFolder = objNamespace.GetDefaultFolder(Outlook.OlDefaultFolders.olFolderInbox); Outlook.Items Items= objFolder.Items; item = (Outlook.MailItem) Items.GetFirst(); while (null != item) { item = (Outlook.MailItem)Items.GetNext();
rv.Tables[0].Rows.Add(new object[] { item.SenderName, item.To, item.CC, item.Subject, item.ReceivedTime, item.Body }); this.ItemProcessed(); }
RDerby
|
| Sign In·View Thread·PermaLink | |
|
|
|
 |
|
|
I tried to execute the getting calendar items and contracts items from the code and i am always getting only the first record. In debug mode i have inserted a a string variable to get the exception and the exception you can see in this screenshot. http://www.guidant-cor.com/tempfiles/exceptionscreen.jpg
Can anybody help me with this. Please reply as when is the cause of the error.
|
| Sign In·View Thread·PermaLink | 2.60/5 (2 votes) |
|
|
|
 |
|
|
 |
|
|
hi.. i'm fairly new with the .net technology. can i display the exports on a web page using asp.net? is it also possible to "parse" the subject and when it found a "CRITICAL" string, i would have to color code the whole row with red, and if "WARNING" yellow? any idea? thanks
|
| Sign In·View Thread·PermaLink | |
|
|
|
 |
|
|
Could you please help to send fax from my C# application through FaxMaker for Exchange ( NO SMTP )?
Thanks in advance.
Best Regards, Fayeez
|
| Sign In·View Thread·PermaLink | 1.33/5 (2 votes) |
|
|
|
 |
|
|
i Use OutlookConnector Project and Outlook.MailItem in my program .i have outlook xp.I want to access to sendername or to or cc of it .I want To "GET" Item.To And I dont want to "Set" it. but when i want to read them i got this prompt:A program is trying to access e-mail addresses you have stored in outlook. how can i disable this prompt.
|
| Sign In·View Thread·PermaLink | 1.89/5 (8 votes) |
|
|
|
 |
|
|
For fully integrating into Outlook, you might do as MIRo2K4 suggests and implement an Outlook.Namespace.Logon() through a custom prompt or initialization process. The default prompt is meant to protect access (read or write) and not authorization (possibly in Mailbox Profiles?).
|
| Sign In·View Thread·PermaLink | 2.00/5 (13 votes) |
|
|
|
 |