Jump to content

BLAT DLL


Recommended Posts

Is anyone Know the synthax for launching Balt dll

My example tha's doesn(t works

$teststring="-html ""<B>Bonjour<B>"" -alttext ""ba"" -to ""toto@free.fr"" -f ""toto@9online.fr"" -s ""test"" -x ""X-Header-Test: Can Blat do it? Yes it Can"""

Msgbox(0,"",DllCall("blat.dll","int","SendBlat","str",$teststring))

Link to comment
Share on other sites

The name of the function is actually Send() and not SendBlat().

Thanks I try like this

Msgbox(0,"",DllCall("blat.dll","int","Send","str",$teststring))

and the function return me a blank maybe one parameter is not good in call function ?

Link to comment
Share on other sites

Thanks I try like this

Msgbox(0,"",DllCall("blat.dll","int","Send","str",$teststring))

and the function return me a blank maybe one parameter is not good in call function ?

You might get some results if you set up a variable then check the first element of that.

$Result = DllCall(...)
MsgBox(0, "", $Result[0])
Edited by Emperor
Link to comment
Share on other sites

Instead of

$teststring="-html ""<B>Bonjour<B>"" -alttext ""ba"" -to ""toto@free.fr"" -f ""toto@9online.fr"" -s ""test"" -x ""X-Header-Test: Can Blat do it? Yes it Can"""oÝ÷ ÚÚòjëh×6$teststring='-html "<B>Bonjour<B>" -alttext "ba" -to "toto@free.fr" -f "toto@9online.fr" -s "test" -x "X-Header-Test: Can Blat do it? Yes it Can"'
Link to comment
Share on other sites

Is anyone Know the synthax for launching Balt dll

My example tha's doesn(t works

Or you can use Blat.exe instead of Blat.dll

I used it in one my project, here are examples:

Run('Blat.exe ' & $err_name & ' -subject "Action - ' & $error_text & '" -to ' & $ini_EmailTo & ' -server ' & $ini_SMTP & ' -attach .\' & $log_name,'',@SW_HIDE)oÝ÷ Ù«­¢+ÙIÕ¸ Ìäí    ±Ð¹áÌäìµÀìÀÌØíÉÉ}¹µµÀìÌäìµÍÕ©ÐÅÕ½ÐíÑ¥½¸´¥¹¥Í¡¸9յȽÉɽÉÌôÌäìµÀìÀÌØí¹Õµ}ÉȵÀìÌäìÅÕ½ÐìµÑ¼ÌäìµÀìÀÌØí¥¹¥}µ¥±Q¼µÀìÌäìµÍÉÙÈÌäìµÀìÀÌØí¥¹¥}M5Q@µÀìÌäìµÑÑ ¸ÀäÈìÌäìµÀìÀÌØí±½}¹µ°ÌäìÌäì±M]}!%
Link to comment
Share on other sites

Only for your info:

On WINXP is elegant method for sending emails by system DLL via COM object CDO.Message:

Func _SendEmail($e_From, $e_To, $e_Cc, $e_Bcc, $e_Subject, $e_Text)
  $objMessage = ObjCreate ("CDO.Message")
  If @error Then Return
  $objMessage.BodyPart.ContentTransferEncoding = "8bit"
  $objMessage.BodyPart.CharSet = "windows-1250"
  $objMessage.From = $e_From
  $objMessage.To = $e_To
  $objMessage.Cc = $e_Cc
  $objMessage.Bcc = $e_Bcc
  $objMessage.Subject = $e_Subject
  $objMessage.TextBody = $e_Text
;~  $objMessage.AddAttachment(@ScriptDir & "\Test.txt")
  $objMessage.Configuration.Fields.Item ("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2
  $objMessage.Configuration.Fields.Item ("http://schemas.microsoft.com/cdo/configuration/smtpserver") = $ini_smtp_server
  $objMessage.Configuration.Fields.Item ("http://schemas.microsoft.com/cdo/configuration/smtpserverport") = $ini_smtp_port
  $objMessage.Configuration.Fields.Item ("http://schemas.microsoft.com/cdo/configuration/smtpconnectiontimeout") = 60
  $objMessage.Configuration.Fields.Update
  $objMessage.Send
EndFunc
Link to comment
Share on other sites

Is anyone Know the synthax for launching Balt dll

My example tha's doesn(t works

Always check the error codes.

$teststring="-html ""<B>Bonjour<B>"" -alttext ""ba"" -to ""toto@free.fr"" -f ""toto@9online.fr"" -s ""test"" -x ""X-Header-Test: Can Blat do it? Yes it Can"""


$Return = DllCall("blat.dll","int","SendBlat","str",$teststring)

If @Error Then

     Msgbox(0,"ERROR", @Error)

Else
     Msgbox(0,"", $Return)

EndIf

If you had done that, and it's the function name that is wrong, you would've gotten an error code of 3. Which as stated in the helpfile..""function" not found in the DLL file.". That would've told you that the function name was incorrect.

Nomad :D

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...