| Newsgroups |
gmane.mail.blat |
| Message-ID |
<194F59840FF140C9ABD0A5DD5E61B01E@chip> |
> Hi,
>
> I too am having trouble using BLAT from RAD Studio.
> I am using Win7/64 Pro. I have downloaded and unzipped blat324_64.full.zip
>
> In my case I am using C++Builder XE5 (Rad Studaio 12.0). I am seeting up a command line like:
blat C:\Users\John\AppData\Local\Temp\\blat_body.tmp -subject "Controller 6 [Identity:1000] Test" -to [email protected] -p CryoBank
and calling system(). This does not work - system() returns 1, with errno = 0. If I replace 'blat' with 'echo' it works - but I think echo is a built-in command, not a program on the PATH. If I replace the command line with
ipconfig > c:\temp\echoed.txt it works - so system() can pick up programs from the path.
>
> I get the same result if I use the full path to blat.exe, C:\Windows\System32\blat.exe
>
> I can open a command prompt at C:, and 'blat' runs, giving usage info, and sending emails. I can copy the program's command line to this dos box, and that works too.
>
> The really odd thing is that I have GoW installed, and 'which blat' says 'no blat in:' and lists the PATH, which definitely has %systemroot%\system32 in it. 'which robocopy', for instance, shows C:\Windows\system32\robocopy.EXE.
>
> For now, I have copied blat.exe to the same folder as my own program's .exe, but this is less than ideal.
>
> Any hints as to how to get this going, please. Did the original poster make it work, I wonder.
>
> Thanks
John,
If you want to use quotation marks in your C++ code for the Blat command line, make sure you precede each with a backslash like below:
retval = system( __T("blat.exe ") \
__T("- ") \
__T("-q ") \
__T("-body \"Test message\" ") \
__T("-s \"Testing BLAT324 attachment encoding\" ") \
__T("-t myself ") \
__T("-attach \"\\RFCs\\rfc_2184\\*.pdf\" ") \
__T("-debug ") \
__T("-noh2 ") \
__T("-overwritelog ") \
__T("-log \"\\smtp0.txt\"") );
I do not have the software you mentioned, so I’m not sure what it needs to make Blat work.
Chip