Home | Forums | Contact | Search | Syndication  
 
 [login] [create account]   Saturday, August 23, 2025 
 
slxdeveloper.com Community Forums  
   
The Forums on slxdeveloper.com are now retired. The forum archive will remain available for the time being. Thank you for your participation on slxdeveloper.com!
 Architect Forums - SalesLogix Scripting & Customization
Forum to discuss writing script in Architect plugins for SalesLogix & general SalesLogix customization topics (for Windows client only). View the code of conduct for posting guidelines.
Forums RSS Feed


 Back to Forum List | Back to SalesLogix Scripting & Customization | New ThreadView:  Search:  
 Author  Thread: Send Email
Bryan
Posts: 46
 
Send EmailYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 20 Mar 08 4:22 PM
Hello,

Does anyone know any SalesLogix function , to send an e-mail automatically without opening the Outlook?

Thanks for your help
[Reply][Quote]
Phil Sim
Posts: 16
 
Re: Send EmailYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 21 Mar 08 12:10 AM
Hi Brian,

If you are trying to send the email from inside SLX, you can use the Application.BasicFunctions.QueMessage to send an email via script.
[Reply][Quote]
Chris Burriss
Posts: 120
 
Re: Send EmailYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 21 Mar 08 8:58 AM
I'm unfamiliar with Application.BasicFunctions.QueMessage. When I want to send emails behind the scences, I use CDO. I've copied in some bits and pieces from some code to give you an idea.


'Email constants
Const cdoSendUsingMethod = "http://schemas.microsoft.com/cdo/configuration/sendusing"
Const cdoSendUsingPort = 2
Const cdoSMTPServer = "http://schemas.microsoft.com/cdo/configuration/smtpserver"
Const cdoSMTPServerPort = "http://schemas.microsoft.com/cdo/configuration/smtpserverport"
Const cdoSMTPAuthenticate = "http://schemas.microsoft.com/cdo/configuration/smtpauthenticate"
Const cdoBasic = 1
Const cdoSendUserName = "http://schemas.microsoft.com/cdo/configuration/sendusername"
Const cdoSendPassword = "http://schemas.microsoft.com/cdo/configuration/sendpassword"

Sub something
iMsgBoxResult = MsgBox("Would you like to notify the appraiser via email?", vbYesNo, "Appraisal Notification")

If iMsgBoxResult = vbYes Then

Dim objConfig ' CDO.Configuration
Dim strToEmailAddress ' To Address
Dim strCCEmailAddress ' CC Address; for SLX User assigning appraiser
Dim strFromEmailAddress ' From Address
Dim strEmailSubject ' Email Subject
Dim strEmailBody ' Email body

' Get a handle on the config object and its fields
Set objConfig = CreateObject("CDO.Configuration")

' Set config fields we care about

objConfig.Fields.Item(cdoSendUsingMethod) = cdoSendUsingPort
objConfig.Fields.Item(cdoSMTPServer) = " objConfig.Fields.Item(cdoSMTPServerPort) = 25
objConfig.Fields.Item(cdoSMTPAuthenticate) = cdoBasic
objConfig.Fields.Item(cdoSendUserName) = ""
objConfig.Fields.Item(cdoSendPassword) = ""
objConfig.Fields.Update

strToEmailAddress = GetField("Email", "UserInfo", "Username = '" & cboAppraiser.Text & "'")
strCCEmailAddress = GetField("Email", "UserInfo", "UserID = '" & Application.BasicFunctions.CurrentUserID & "'")
strFromEmailAddress = ""
strEmailSubject = "Notification of Assignment"
strEmailBody = BuildAppraiserEmailBody
Sendmail strToEmailAddress, strCCEmailAddress, strFromEmailAddress, strEmailSubject, strEmailBody, 2, objConfig

Set objConfig = Nothing

Msgbox "Email sent to Appraiser.", vbOKOnly, "Email Notification"
End If

End sub

Function SendMail(strTo, strCC, strFrom, strSubject, strBody, msgType, objConfig)

On Error Resume Next

Dim objMail

set objMail = CreateObject("CDO.Message")

set objMail.Configuration = objConfig

objMail.To = strTo
objMail.CC = strCC
objMail.From = strFrom
objMail.Subject = strSubject

if msgType = 1 then
objMail.TextBody = strBody
end if

if msgType = 2 then
objMail.HTMLBody = strBody
end if

objMail.Send

set objConfig = Nothing
set objMail = Nothing

On Error Goto 0

End Function

Function BuildAppraiserEmailBody

Dim strAssigningUser
Dim strOpportunityIDLink
Dim strPropertyName 'Property name is opp. desc.
Dim objProducts_RS
Dim strSQL

Set objProducts_RS = objDB.GetNewRecordSet

strSQL = "SELECT Family, Name, op.ProductID, Quantity, ExtendedPrice " & _
"FROM Opportunity_Product op " & _
"INNER JOIN Product p on op.ProductID = p.ProductID " & _
"WHERE OpportunityID = '" & Application.BasicFunctions.CurrentOpportunityID & "'" & _
"ORDER BY Quantity * ExtendedPrice DESC"

objProducts_RS.Open strSQL, objDB.Connection

strAssigningUser = GetField("UserName", "UserInfo", "Userid = '" & Application.BasicFunctions.CurrentUserID & "'")

strPropertyName = GetField("Description", "Opportunity", "OpportunityID = '" & Application.BasicFunctions.CurrentOpportunityID & "'")

strOpportunityIDLink = " ">Click Here to View the Project in SalesLogix"

BuildAppraiserEmailBody = "

You have assigned to the following project by " & _
strAssigningUser & ":

" & _
"

Appraisal Description:" & _
"
" & strPropertyName & "

" & _
"

Services:"

With objProducts_RS
While Not .EOF
BuildAppraiserEmailBody = BuildAppraiserEmailBody & "
" & _
.Fields("Family").Value & " - " & .Fields("Name").Value & _
"; Qty: " & .Fields("Quantity").Value & _
"; Fee: " & FormatCurrency(.Fields("ExtendedPrice").Value, 2, , True, True)
.MoveNext
Wend
End With

BuildAppraiserEmailBody = BuildAppraiserEmailBody & "

Due Date:" & _
"
" & dteAppraisal.Text & "

" & _
"

Link to SalesLogix Opportunity:
" & _
strOpportunityIDLink & "

" & _
"

Troubleshooting Link Problems:" & _
"
(1) The link must be clicked on a computer with SalesLogix." & _
"
(2) If the link is not active in your email provider, ensure that the " & _
"host email account () is added to your Safe Sender's List." & _
"
(3) If your Link appears as text, you must change to the HTML version of the email. In some rare cases, your " & _
"email program may not support HTML." & _
"
(4) If an Appraiser has not received their notifications, their account may have an invalid email address " & _
"entered. Notify your SalesLogix Administrator.

"

objProducts_RS.Close
Set objProducts_RS = Nothing

End Function
[Reply][Quote]
Matt Dockins
Posts: 159
 
Re: Send EmailYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 21 Mar 08 10:18 AM
You can actually use CDONTS in SalesLogix, but it's problematic. Each machine that willl potentially send an e-mail behind the scenes must have CDONTS installed.

If you have it, the best solution for something like this would be to simply implement a knowledgesync event. Most business partners try and package knowledgesync with SalesLogix- which is why I recommend that option if possible.
[Reply][Quote]
Bob (RJ)Ledger
Posts: 1103
Top 10 forum poster: 1103 posts
 
Re: Send EmailYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 21 Mar 08 7:30 PM
Quote:
Originally posted by Matt Dockins

You can actually use CDONTS in SalesLogix, but it's problematic. Each machine that willl potentially send an e-mail behind the scenes must have CDONTS installed.

If you have it, the best solution for something like this would be to simply implement a knowledgesync event. Most business partners try and package knowledgesync with SalesLogix- which is why I recommend that option if possible.

.. and also TaskCentre.. there's a lot of partners now that have switched from KS to TaskCentre

BUT in the specific case in this thread I'd recommend QUEUEMESSAGE.... Look at the code in Ticket Detail on the Email button... This way you avoid security issues.
--
RJLedger - rjlSystems
[Reply][Quote]
Matt Dockins
Posts: 159
 
Re: Send EmailYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 21 Mar 08 7:33 PM
QueMessage will pop up the outlook window though, which he's trying to avoid. I'll have to bone up on TaskCentre - any good resources out there RJ?
[Reply][Quote]
Bob (RJ)Ledger
Posts: 1103
Top 10 forum poster: 1103 posts
 
Re: Send EmailYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 21 Mar 08 7:50 PM
Hi Matt.. yep.. visit my site
--
RJLedger - rjlSystems
[Reply][Quote]
Ryan Farley
Posts: 2265
slxdeveloper.com Site Administrator
Top 10 forum poster: 2265 posts
 
Re: Send EmailYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 22 Mar 08 2:13 AM
Quote:
Originally posted by Bob (RJ)Ledger

Hi Matt.. yep.. visit my site
--
RJLedger - rjlSystems


Is there somewhere on your site that discusses TaskCentre in more detail? I can only find 6 bullet points. I'm not finding the resource you mention.
[Reply][Quote]
Bob (RJ)Ledger
Posts: 1103
Top 10 forum poster: 1103 posts
 
Re: Send EmailYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 22 Mar 08 8:21 PM
On the Product(s) page if you click on what is Taskcentre you will get a diagram (pdf) that will show you architectire. At the very bottom of the page there is a small letter "a".. it's a hyperlink to an "swf" file.. more architecture info.. and it responds to "mouse-over/click". On the RHS.. click on items and it shows you more "pages". Also on the same page, click on the Orbis Software Consulting Partner logo.. takes you to the Orbis (TaskCentre) site.. and there's tons of stuff there.

I'll be adding a bit more to my site in the near future since TC v4.5 is now out....
Key things.... word merge, OLEDB connector that allows direct connection to ANY OLEDB source.. including the "provider" .. "workflow" that puts the human in the loop via an aspx page... and then there's the resilience option... sort of like "clustering".. you have a "second" TC "server" that will be there for "fail-over"... not many folks out there can do that!
--
RJLedger - rjlSystems
[Reply][Quote]
Ryan Farley
Posts: 2265
slxdeveloper.com Site Administrator
Top 10 forum poster: 2265 posts
 
Re: Send EmailYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 22 Mar 08 11:25 PM
Quote:
Originally posted by Bob (RJ)Ledger

On the Product(s) page if you click on what is Taskcentre you will get a diagram (pdf) that will show you architectire. At the very bottom of the page there is a small letter "a".. it's a hyperlink to an "swf" file.. more architecture info.. and it responds to "mouse-over/click". On the RHS.. click on items and it shows you more "pages".


I did miss those since the links are so cleverly concealed . Didn't think of clicking on that "a" link. I have seen those items before on the main TaskCentre site though, I just didn't know if I was missing some other resource.

The TC 4.5 stuff is pretty good. The provider support is *way* long overdue, so it is good that it is finally there.

-Ryan
[Reply][Quote]
Bob (RJ)Ledger
Posts: 1103
Top 10 forum poster: 1103 posts
 
Re: Send EmailYour last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 23 Mar 08 9:37 AM
Yep.. things are a little "hidden"....
I've a new web site in design (same basic "theme" w/the USA flag....) and it will have a section with a lot of TaskCentre info on it... including screen shots of some really slick workflows.

Agree.. haveing the ability to just hook up to the SalesLogix provider with a few clicks.. and NO coding sure make this product stand tall!
--
RJLedger - rjlSystems
[Reply][Quote]
 Page 1 of 1 
  You can subscribe to receive a daily forum digest in your user profile. View the site code of conduct for posting guidelines.

   Forum RSS Feed - Subscribe to the forum RSS feed to keep on top of the latest forum activity!
 

 
 slxdeveloper.com is brought to you courtesy of Ryan Farley & Customer FX Corporation.
 This site, and all contents herein, are Copyright © 2025 Customer FX Corporation. The information and opinions expressed here are not endorsed by Sage Software.

code of conduct | Subscribe to the slxdeveloper.com Latest Article RSS feed
   
 
page cache (param): 8/23/2025 10:20:05 AM