(Msg. 1) Posted: Tue Jun 16, 2009 8:12 am
Post subject: "A program has attachment filename open" Message returns Archived from groups: microsoft>public>outlook>program_forms (more info?)
hi,
I'm using Outlook 2007 addin with VS2008. I can able to add the attachments
to mailitem,but after that i have got the following message from outlook .
"A program has attachment <filename> open.Changes to this file will be lost
unless you save your changes to another file by clicking the Microsoft Office
Button in the other program, and then clicking Save As."
Note:
1.No such file (<filename>) opened when i got this message.
2.Also i checked with saving mailitem and saving attachments,but the same
message will appear.
3.I also checked when attachment file is not opened,but i face the same
problem
4.I surfed with this problem, i didn't get any solution
(Msg. 2) Posted: Tue Jun 16, 2009 1:53 pm
Post subject: Re: "A program has attachment filename open" Message returns [Login to view extended thread Info.] Archived from groups: per prev. post (more info?)
Show the code you're using.
It's not intrinsic, I add attachments to items using code and never see that
message.
"Venugopal" <Venugopal.TakeThisOut@discussions.microsoft.com> wrote in message
news:19723F10-4224-429F-9ED2-1B14852A8D8E@microsoft.com...
> hi,
>
> I'm using Outlook 2007 addin with VS2008. I can able to add the
> attachments
> to mailitem,but after that i have got the following message from outlook .
>
> "A program has attachment <filename> open.Changes to this file will be
> lost
> unless you save your changes to another file by clicking the Microsoft
> Office
> Button in the other program, and then clicking Save As."
>
> Note:
> 1.No such file (<filename>) opened when i got this message.
> 2.Also i checked with saving mailitem and saving attachments,but the same
> message will appear.
> 3.I also checked when attachment file is not opened,but i face the same
> problem
> 4.I surfed with this problem, i didn't get any solution
>
> Help me as soon as possible
(Msg. 3) Posted: Wed Jun 17, 2009 10:57 pm
Post subject: Re: "A program has attachment filename open" Message returns [Login to view extended thread Info.] Archived from groups: per prev. post (more info?)
hi
i used the below code.And called this function using button click event.
Issues:
1.First time the function runs successfully without any outlook message.
2.If i called that function at second time,then the above mentioned message
will appear.I have cheked with task manager but no such file was run at that
time.
(Msg. 4) Posted: Thu Jun 18, 2009 9:14 am
Post subject: Re: "A program has attachment filename open" Message returns [Login to view extended thread Info.] Archived from groups: per prev. post (more info?)
If that's all the code then I don't see why that message is appearing.
However, see if this makes any difference. Since Attachments.Add() is a
function get the returned Attachment object. Then when the procedure ends
release both the mail and attachment objects. Also explicitly declare and
instantiate the Attachments collection so no invisible object variables are
created.
"Venugopal" <Venugopal DeleteThis @discussions.microsoft.com> wrote in message
news:D4552112-8782-41F7-B4AF-0553B87247F0@microsoft.com...
> hi
>
> i used the below code.And called this function using button click event.
>
> Issues:
>
> 1.First time the function runs successfully without any outlook message.
>
> 2.If i called that function at second time,then the above mentioned
> message
> will appear.I have cheked with task manager but no such file was run at
> that
> time.
>
> [Outlook 2007 Addin + VS2008]
>
> private void insertAttachments()
> {
> mail.Attachments.Add("filepath",
> OlAttachmentType.olByValue,1,"filename");
> mail.Display(true);
> mail = null;
> }
>
> by,
> Venugopal
(Msg. 5) Posted: Thu Jul 02, 2009 12:17 am
Post subject: Re: "A program has attachment filename open" Message returns [Login to view extended thread Info.] Archived from groups: per prev. post (more info?)
All times are: Eastern Time (US & Canada) (change)
Page 1 of 1
You can post new topics in this forum You can reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum