Showing results for 
Search instead for 
Do you mean 
Community Home Request Access Read Blogs Share Your Ideas Search Community View My Settings
Reply
Nickel Elite Contributor
Posts: 107
Registered: ‎03-09-2011
Accepted Solution

Application.BasicFunctions.QueMessage not creating attahment

I'm sending a custom generated order confirmation via email to a contact with a cc to the account manager.

 

The email message opens in the editor, with all of the fileds properly populated, just no attachment.

 

Message editor is Outlook 2010 

Sales Logix is SLX LAN Client 7.5.4.7048

 

Here is the code which right now is triggered from a button click on a form. attachment path is a paramter and the value I'm passin is valid.

 

Sub SendEmail(attachmentPath)
stop
    dim emailSQL
'get the email address of the account manager
    emailSQL = "SELECT EMAIL FROM sysdba.USERINFO WHERE USERID = '" & lveacctmgr.Text & "'"
    dim acctMgrEmail
    acctMgrEmail = GetStringFromSQLSatement(emailSQL)
'get the email address of the contact
    emailSQL = "SELECT EMAIL FROM sysdba.CONTACT WHERE CONTACTID = '" & lvebillcontact.LookupID & "'"
    dim contactEmail
    contactEmail = GetStringFromSQLSatement(emailSQL)

'use the path of the newly created attachment
    Application.BasicFunctions.QueMessage  contactEmail, acctMgrEmail, "", "Confirmation for Order #" & txtQDBQuoteNumber.Text, "", attachmentPath

End Sub

 

Silver Super Contributor
Posts: 801
Registered: ‎03-24-2009

Re: Application.BasicFunctions.QueMessage not creating attahment

Check the number of params. I think you have ie too many - so attach path would be blank.
Nickel Elite Contributor
Posts: 107
Registered: ‎03-09-2011

Re: Application.BasicFunctions.QueMessage not creating attahment

From the dev reference

 

Parameters

 

 

ToAddress

To Address for the e- mail contactEmail

 

CCAddress

CC Address for the e-mail acctMgrEmail

 

BCCAddress

BCCAddress for the e-mail ""

 

Subject

Subject for the e-mail "Confirmation for Order #" & txtQDBQuoteNumber.Text

 

Body

Body of the e-mail ""

 

Attach

Attachment path for the e-mail attachmentPath

 

I would like to think that invalid parameter count would throw an error, but a nice thought, unless the order of the parameters ahs changed....

 

 

 

 

Highlighted
Silver Super Contributor
Posts: 801
Registered: ‎03-24-2009

Re: Application.BasicFunctions.QueMessage not creating attahment

Right. I don't have a machine on so was from memory!. However, I can confirm this function is fine as I use it a lot (just this morning in fact).

Is the path the path+filename ? Can you show what it actually is (unc or local?)
Is Outlook 2010 preventing it ? (do you have acces to another email client vsn)?
Nickel Elite Contributor
Posts: 107
Registered: ‎03-09-2011

Re: Application.BasicFunctions.QueMessage not creating attahment

The path currently is a local file for development 

 

"C:\testoutput\2001003-1\OrderDetails20111521.pdf"

I can attach this once the editor is open

 

Is there a setting in Outlook 2010 that would prevent other application for automatically attaching items?? I'm no outlook expert.

 

I'm not sure what you mean by  (do you have acces to another email client vsn)?

 

I am creating the order confirmation using a .Net Extension but the System.Net.Mail is even more challenging for attachments.  I also want an editor to display so our Customer Service reps can customize the message. I'd rather not have to create a form to do all of that when an email editor is readily acessible.

 

The code above is dev only just to get things working.

Silver Super Contributor
Posts: 801
Registered: ‎03-24-2009

Re: Application.BasicFunctions.QueMessage not creating attahment

Path and attachment look fine (is the editor that creates the file closing it ?)
I was thinking an earlier version of Outlook - like 2003 if you had it to hand/setup.
Nickel Elite Contributor
Posts: 107
Registered: ‎03-09-2011

Re: Application.BasicFunctions.QueMessage not creating attahment

Are there any known issues with this method and outlook versions past 2003??

 

Silver Super Contributor
Posts: 801
Registered: ‎03-24-2009

Re: Application.BasicFunctions.QueMessage not creating attahment

Provided version of SLX is up to date its fine. Prior versions didn't use extended mapi and would create a security message (the old address book security message).
Nickel Elite Contributor
Posts: 107
Registered: ‎03-09-2011

Re: Application.BasicFunctions.QueMessage not creating attahment

Ok, I figured it out.

 

This may be basic, but if it helps anyone else out there...

 

In Administrator on the Client System tab. The Mail System needs to be set to “Microsoft Outlook”.  If set to None, the attachments won’t work.

 

It's working now.