Discussion:
BLAT.DLL
(too old to reply)
Grigore Dolghin
2006-11-20 01:50:42 UTC
Permalink
Well, guys

I heard some of you saying that you are using blat.dll for sending mails. I
spent today several hours trying to make the dll work. No success at all -
it doesn't send mails. The code posted at SPSBlog doesn't work - raises the
same error code: no file name specified or bad argument.

Does anyone has a sample code that actually works and is able to send
messages with attachments?

Thanks.
William Sanders / EFG
2006-11-20 07:26:15 UTC
Permalink
Heya Grig.

debugging a blat app can be fun -
here's the steps I used:

1. paste your SEND string into a dos command window - preface it with
'blat'
and end it with -debug - do this IN the folder you've installed blat.
my cmd debug is a big trickier.. file to attach somewhere on the d: drive,
blat on the c: drive, so I'll chgdir on the c: drive to c:\blat,
then chgdir into the d: drive where the attachment lives,
and then from d: (not the root) issue 'c:blat .....

2. spacing is important . more than one space in the wrong place will
kill you.

3. pathing is important. what i do is issue 'set defa to' when i'm ready
to attach a file, then attach that file. this gets around:
a. hugely nested subdirectories
b. spaces in path names

4. are you using a profile ? are you using a named profile ?
take a look - shell to dos , get into the folder where blat lives,
and take a look at the profiles. don't like what you see? change it in
the registry with regedit. Even if you call a profile, you CAN over-ride
its settings at run time with the appropriate switches .

5. set up a log file. study the output.

6. in an interactive cmd shell session (repeating for emphasis) - paste
your SEND command string. what's the error again ? (paste that here)

hth - sorry for the late reply ... Tis the Birthday and I've been ruminating.

Mondo Regards [Bill]
--
William Sanders / efGroup {rmv the DOT BOB to reply}
Mondo Cool TeleCom -> http://www.efgroup.net/efgcog.html
Mondo Cool WebHosting -> http://www.efgroup.net/efglunar.html
Mondo Cool DSL -> http://www.efgroup.net/shopfordsl.html
VFP Webhosting? You BET! -> http://efgroup.net/vfpwebhosting
Failing dotNet Project? -> http://www.dotnetconversions.com
MB Software Solutions
2006-11-20 12:49:07 UTC
Permalink
Post by William Sanders / EFG
hth - sorry for the late reply ... Tis the Birthday and I've been ruminating.
Happy Birthday, Bill! Make it a great day!

--Michael
--
Michael J. Babcock, MCP
MB Software Solutions, LLC
http://mbsoftwaresolutions.com
http://fabmate.com
"Work smarter, not harder, with MBSS custom software solutions!"
Vince Teachout
2006-11-20 14:18:42 UTC
Permalink
Post by William Sanders / EFG
hth - sorry for the late reply ... Tis the Birthday and I've been ruminating.
Many happy returns! I hope you're ruminating over something tasty!
Sietse Wijnker
2006-11-20 08:59:12 UTC
Permalink
Hi Grigore,
I've got BLAT working by wrapping it in a class that handles most of the
functionality.

You can donload it from my site:
http://www.sw-software.nl/LinkClick.aspx?link=Downloads%2fVFP+Tools%2fBlatMa
il.zip&tabid=61&mid=376

In the zip is a classlib containing two classes: a blatmail class for
setting up the message and the server class which actually calls blat. The
command-string used is build using both classes.

disclaimer: the class provided is nowhere near production level, but will
give you some insight on the workings. I intend to work it out further, but
I'm not sure where I'll find the time for it..

Regards,
Sietse
-----Original Message-----
Sent: maandag 20 november 2006 2:51
Subject: BLAT.DLL
Well, guys
I heard some of you saying that you are using blat.dll for
sending mails. I spent today several hours trying to make the
dll work. No success at all - it doesn't send mails. The code
no file name specified or bad argument.
Does anyone has a sample code that actually works and is able
to send messages with attachments?
Thanks.
[excessive quoting removed by server]
Grigore Dolghin
2006-11-20 11:08:02 UTC
Permalink
Thank you very much - it did the trick.

There is one small problem though - the file that contains the body text is
opened exclusively by blat.dll and cannot be deleted by "DELETE FILE
filename RECYCLE" - it raises an error.

Any ideas besides CLEAR DLLS?


----- Original Message -----
From: "Sietse Wijnker" <***@sw-software.nl>
To: <***@leafe.com>
Sent: Monday, November 20, 2006 10:59 AM
Subject: RE: BLAT.DLL
Post by Sietse Wijnker
Hi Grigore,
I've got BLAT working by wrapping it in a class that handles most of the
functionality.
http://www.sw-software.nl/LinkClick.aspx?link=Downloads%2fVFP+Tools%2fBlatMa
il.zip&tabid=61&mid=376
In the zip is a classlib containing two classes: a blatmail class for
setting up the message and the server class which actually calls blat. The
command-string used is build using both classes.
disclaimer: the class provided is nowhere near production level, but will
give you some insight on the workings. I intend to work it out further, but
I'm not sure where I'll find the time for it..
Regards,
Sietse
-----Original Message-----
Sent: maandag 20 november 2006 2:51
Subject: BLAT.DLL
Well, guys
I heard some of you saying that you are using blat.dll for
sending mails. I spent today several hours trying to make the
dll work. No success at all - it doesn't send mails. The code
no file name specified or bad argument.
Does anyone has a sample code that actually works and is able
to send messages with attachments?
Thanks.
[excessive quoting removed by server]
Malcolm Greene
2006-11-20 12:02:09 UTC
Permalink
Grigore,
the file that contains the body text is opened exclusively by blat.dll and cannot be deleted by "DELETE FILE filename RECYCLE"
Blat will release the referenced files once the send process completes.
The send process isn't instantaneous and may be several seconds or more
depending on the size of the attached file(s).

You could place body text and attached files in a temp folder and then
attempt to delete that folder when you app exits. If you need to be sure
all these files are deleted, then at exit, loop until you CAN delete all
files in your temp folder.

Malcolm
MB Software Solutions
2006-11-20 12:46:53 UTC
Permalink
Post by Grigore Dolghin
Well, guys
I heard some of you saying that you are using blat.dll for sending mails. I
spent today several hours trying to make the dll work. No success at all -
it doesn't send mails. The code posted at SPSBlog doesn't work - raises the
same error code: no file name specified or bad argument.
Does anyone has a sample code that actually works and is able to send
messages with attachments?
You can download the n-tier VFP open source project I put on the web
last week for the community to download and comment on. See
http://leafe.com/forum/viewtopic.php?t=1861 or
http://leafe.com/forum/viewtopic.php?t=1860 for download links.
--
Michael J. Babcock, MCP
MB Software Solutions, LLC
http://mbsoftwaresolutions.com
http://fabmate.com
"Work smarter, not harder, with MBSS custom software solutions!"
Continue reading on narkive:
Loading...