Discussion:
Basic instructions to use Blat please
(too old to reply)
thrusearch
2004-06-08 14:02:56 UTC
Permalink
First, please don't laugh.

Our company switched from Notes to Outlook, from Novell to
WinNT2000 and introduced Blat 1.9.4 to us this year. Changes are
welcome, but we do not have step by step intruction. Being non-
technical we have difficulty asking questions to IT. If we ask
questions, our bosses yell at us for being charged high $ by IT.
Helpdesk from India does not really help much, because of the
language barrier, time zones and other reasons. Our/my dilema:

We have to send updated reports as email attachments through a
scheduler application repeately. Blat was installed by our local
computer admin. Now it is up to us to create the macros and the batch
files. Some of us have access to DOS (Win2K) some have (WinXP).

There is no BLat icon on the desktop or start/program. What must
we do to get Blat to work, to add the email addresses, subject name
to Blat available command? Whenever we click on Balt.exe, it flashes
quickly to the screen. That was it.

Do we have to be the programmer to use Blat? How can we make these
applications "talk" together? Do we need to go take a programming
class to write a bacth file?

Please recommend some solutions or alternatives. Your help is much
appreciated.

James in Plano.






------------------------ Yahoo! Groups Sponsor --------------------~-->
Yahoo! Domains - Claim yours for only $14.70
http://us.click.yahoo.com/Z1wmxD/DREIAA/yQLSAA/dkFolB/TM
--------------------------------------------------------------------~->
--
Homepage:
http://www.blat.net
Tim Musson
2004-06-08 16:50:48 UTC
Permalink
Hey James,

On Tuesday, June 8, 2004 at 10:02:56 AM you wrote

t> We have to send updated reports as email attachments through a
t> scheduler application repeately.

Ok

t> Blat was installed by our local computer admin.

Where is it installed?

t> Now it is up to us to create the macros and the batch files. Some
t> of us have access to DOS (Win2K) some have (WinXP).

t> There is no BLat icon on the desktop or start/program.

That is as it should be.

t> What must we do to get Blat to work,

I suggest running it from a batch file.

t> to add the email addresses, subject name to Blat available command?

That all goes in the batch file.

t> Whenever we click on Balt.exe, it flashes quickly to the screen.
t> That was it.

The way Blat works is to run it on the command line (Start/Run/CMD)
with a handful of options telling it what you want it to do.

t> Do we have to be the programmer to use Blat?

Not really

t> How can we make these applications "talk" together?

If by 'applications' you mean Blat and MS Outlook, then you should be
able to.

t> Do we need to go take a programming class to write a bacth file?

I would not think so, there are lots of resources on the web (this
being one of them).

%%%%%%%%%%%%%%%%%%%%%

So, if for example you want to send an eMail with Blat and attach
report.doc that lives in c:\reports. You could do something like this:

blat
-
-body "check out the attachment"
-f ***@address.tld
-to ***@address.tld
-subject "here is the report"
-attach c:\reports\report.doc
-server smtp.server.tld

Note: all the above needs to be on one line, I put it on multiple to
make it easier to read...

You will have to find out what SMTP server Blat will attach to.
You should also specify a valid To: and From: eMail address.

If you get a command prompt and type blat /? it gives you some basic
syntax. You can also look at the www.blat.net web site for help.

One last thing. I suggest you upgrade to the current version of Blat.
You can just replace the blat.exe file with a new one from the 'full'
distribution on the www.blat.net web site.

HTH
--
Tim Musson
Flying with The Bat! eMail v2.10.03
Keyboard not available - Press F1; to continue.
Blat Manager, current version is 2.2.2, see www.blat.net



------------------------ Yahoo! Groups Sponsor --------------------~-->
Make a clean sweep of pop-up ads. Yahoo! Companion Toolbar.
Now with Pop-Up Blocker. Get it for free!
http://us.click.yahoo.com/L5YrjA/eSIIAA/yQLSAA/dkFolB/TM
--------------------------------------------------------------------~->
--
Homepage:
http://www.blat.net
thrusearch
2004-06-09 12:41:32 UTC
Permalink
Howdy,

First of all, we thank you.
Post by Tim Musson
Where is it installed?
It was installed on WinNT folder in our local machines.
Post by Tim Musson
I suggest running it from a batch file.
I saw some examples from this site. Humm "@echo
off" .... "Goto" are the commands to run the batch file? or
Run_batch_file_name is the command?

We got the command to email from Blat without running it from a
batch file, but don't know what command to run the batch file; "run"
and execute does not work for us in dos. This is our biggest
obstacle: "how to make them talk" . Most of us are not computer savvy
enough to activate or run the batch file from C drive. Man, it does
not pay to be a computer illiterated these years.

We'll tackle it again today. In the mean time, we continue to
mailing out the CAD reports through ...aol and sbc manually.

Thank you again and y'all have a nice day. James in Plano.
Post by Tim Musson
Hey James,
t> We have to send updated reports as email attachments through a
t> scheduler application repeately.
Ok
t> Blat was installed by our local computer admin.
Where is it installed?
t> Now it is up to us to create the macros and the batch files. Some
t> of us have access to DOS (Win2K) some have (WinXP).
t> There is no BLat icon on the desktop or start/program.
That is as it should be.
t> What must we do to get Blat to work,
I suggest running it from a batch file.
t> to add the email addresses, subject name to Blat available
command?
Post by Tim Musson
That all goes in the batch file.
t> Whenever we click on Balt.exe, it flashes quickly to the screen.
t> That was it.
The way Blat works is to run it on the command line (Start/Run/CMD)
with a handful of options telling it what you want it to do.
t> Do we have to be the programmer to use Blat?
Not really
t> How can we make these applications "talk" together?
If by 'applications' you mean Blat and MS Outlook, then you should be
able to.
t> Do we need to go take a programming class to write a bacth file?
I would not think so, there are lots of resources on the web (this
being one of them).
%%%%%%%%%%%%%%%%%%%%%
So, if for example you want to send an eMail with Blat and attach
blat
-
-body "check out the attachment"
-subject "here is the report"
-attach c:\reports\report.doc
-server smtp.server.tld
Note: all the above needs to be on one line, I put it on multiple to
make it easier to read...
You will have to find out what SMTP server Blat will attach to.
You should also specify a valid To: and From: eMail address.
If you get a command prompt and type blat /? it gives you some basic
syntax. You can also look at the www.blat.net web site for help.
One last thing. I suggest you upgrade to the current version of Blat.
You can just replace the blat.exe file with a new one from
the 'full'
Post by Tim Musson
distribution on the www.blat.net web site.
HTH
--
Tim Musson
Flying with The Bat! eMail v2.10.03
Keyboard not available - Press F1; to continue.
Blat Manager, current version is 2.2.2, see www.blat.net
------------------------ Yahoo! Groups Sponsor --------------------~-->
Make a clean sweep of pop-up ads. Yahoo! Companion Toolbar.
Now with Pop-Up Blocker. Get it for free!
http://us.click.yahoo.com/L5YrjA/eSIIAA/yQLSAA/dkFolB/TM
--------------------------------------------------------------------~->
--
Homepage:
http://www.blat.net
q***@yahoo.com
2004-06-09 14:04:20 UTC
Permalink
Carl Sagan, thrusearch & Bill Nye puff their pipes
and discuss "Basic instructions to use Blat please"..
Post by thrusearch
off" .... "Goto" are the commands to run the batch file? or
Run_batch_file_name is the command?
We got the command to email from Blat without running it from a batch
file, but don't know what command to run the batch file; "run" and execute
does not work for us in dos. This is our biggest obstacle: "how to make
them talk" . Most of us are not computer savvy enough to activate or run
the batch file from C drive. Man, it does not pay to be a computer
illiterated these years.
Welcome to the world of command scripting!

Specifically a batch file is a text file that you create using
a plain text editor, like "Windows Notepad", and saved with a
filename in the format:

batchfilename.bat

To execute the batch file you would enter the following at the
command prompt:

batchfilename

In Windows/DOS (called the Operating System) files ending in
the extension ".bat" are considered executibles. The
Operating System reads the file a line at a time and attempts
to execute each line in the batch file as if it was a command
entered at the command line.

There is a lot more to batch file scripting and help can be
found all over the web (http://www.computerhope.com/batch.htm)
and in many books.
--
Qe'van the Unclothed, Bard of Nor
http://qevan.home.comcast.net/poetry/
http://texasfilk.home.comcast.net/

... 'Well, who am I to question Julian Bashir, Secret Agent.'-
Garak




------------------------ Yahoo! Groups Sponsor --------------------~-->
Yahoo! Domains - Claim yours for only $14.70
http://us.click.yahoo.com/Z1wmxD/DREIAA/yQLSAA/dkFolB/TM
--------------------------------------------------------------------~->
--
Homepage:
http://www.blat.net
Rick Nakroshis
2004-06-10 02:52:13 UTC
Permalink
Post by q***@yahoo.com
There is a lot more to batch file scripting and help can be
found all over the web
(<http://www.computerhope.com/batch.htm)>http://www.computerhope.com/batch.htm)
and in many books.
Watch out for that closing parenthesis, though -- I initially came up with
an error message when it tried to use that link. I had to manually delete
the parenthesis to get it to work.

Rick

[Non-text portions of this message have been removed]



------------------------ Yahoo! Groups Sponsor --------------------~-->
Make a clean sweep of pop-up ads. Yahoo! Companion Toolbar.
Now with Pop-Up Blocker. Get it for free!
http://us.click.yahoo.com/L5YrjA/eSIIAA/yQLSAA/dkFolB/TM
--------------------------------------------------------------------~->
--
Homepage:
http://www.blat.net
Timothy P. Beck
2004-06-08 17:05:16 UTC
Permalink
Hello,

First, I'd recommend that you upgrade to the latest version of Blat (go to
www.blat.net -- click "Download"). Second, from a DOS prompt (Start -> Run -
cmd -> OK), type "blat -h" (without the quotes) to get the blat options.
Basic options are:

BLAT <filename> -to <to-email> -f <sender-email> -s "subject"

Where <filename> is the name of a file containing the body of your message
(i.e. body.txt), <to-email> is the e-mail address of the intended recipient
(i.e. ***@abc.com), <sender-email> is your e-mail address and "subject"
is the message subject (i.e. "A message for you!").

I'm assuming that your IT folks actually installed blat rather than just
putting it on your machine, which means that they told blat how to get to
your e-mail server. If they did this, then you're all set. If not, the
help will tell you how to install it -- you just need to know the name of
your e-mail server.

Good Luck,

Timothy P. Beck
First, please don't laugh.
Our company switched from Notes to Outlook, from Novell to
WinNT2000 and introduced Blat 1.9.4 to us this year. Changes are
welcome, but we do not have step by step intruction. Being non-
technical we have difficulty asking questions to IT. If we ask
questions, our bosses yell at us for being charged high $ by IT.
Helpdesk from India does not really help much, because of the
We have to send updated reports as email attachments through a
scheduler application repeately. Blat was installed by our local
computer admin. Now it is up to us to create the macros and the
batch files. Some of us have access to DOS (Win2K) some have (WinXP)
.
There is no BLat icon on the desktop or start/program. What must
we do to get Blat to work, to add the email addresses, subject name
to Blat available command? Whenever we click on Balt.exe, it
flashes quickly to the screen. That was it.
Do we have to be the programmer to use Blat? How can we make
these applications "talk" together? Do we need to go take a
programming class to write a bacth file?
Please recommend some solutions or alternatives. Your help is
much appreciated.
James in Plano.
--
http://www.blat.net
http://groups.yahoo.com/group/blat
Yahoo! Groups Sponsor
ADVERTISEMENT
-----------------------------------------------------------------------
Yahoo! Groups Links
http://groups.yahoo.com/group/blat/
Your use of Yahoo! Groups is subject to the Yahoo! Terms of
Service.
------------------------ Yahoo! Groups Sponsor --------------------~-->
Make a clean sweep of pop-up ads. Yahoo! Companion Toolbar.
Now with Pop-Up Blocker. Get it for free!
http://us.click.yahoo.com/L5YrjA/eSIIAA/yQLSAA/dkFolB/TM
--------------------------------------------------------------------~->
--
Homepage:
http://www.blat.net
thrusearch
2004-06-09 13:29:43 UTC
Permalink
Thank you Tim. You shed green light to us in 1 reply. We were very
excited to read the log file & learned our problems fast. At least,
something is...communicated back to us: error from host name and not
the socket error. We are getting somewhere with your helps. Today,
one of us brave soul have to talk to the computer man for the mail
server name while the rest of us will scury around to run the batch
file.

We copied the example batch file syntax and changed variables. When
we clicked on it, only the dos screen popped up with a cursor when
clicked on CADReports.bat. Here is the CADReports:

~~~~~~~~~~
@echo off
:::To set variables::
set to = "-to ***@DraftinXYZ.com,***@draftinxyz.com"
set f = "-f ***@Draftingxyz.com"
set server = "-server dratftinserver.Draftinxyz.com

set subject = "-subject \"Test angles\""
set body = "-body \"Please review the attachments\""
set attachment = "-attachment CAD1.zip CAD2.zip CAD3.zip"
set debug = "-debug"

:goto end

echo end of file
~~~~~~~~~~~

We are still puzzled with the sample comment line in Blat's
instruction from the FAQ "::Here is where we run Blat."

What command to run the batch file? RUN? Execute? or simply click
on the CADReports.bat?

We are starting to get somewhere and sooooooooo excited... Talking
about old computer illiterated folks who getting somewhere... We
thank you much for your helps. Y'all have a nice day. James in Plano
Post by Timothy P. Beck
Hello,
First, I'd recommend that you upgrade to the latest version of Blat (go to
www.blat.net -- click "Download"). Second, from a DOS prompt
(Start -> Run -
Post by Timothy P. Beck
cmd -> OK), type "blat -h" (without the quotes) to get the blat options.
BLAT <filename> -to <to-email> -f <sender-email> -s "subject"
Where <filename> is the name of a file containing the body of your message
(i.e. body.txt), <to-email> is the e-mail address of the intended recipient
and "subject"
Post by Timothy P. Beck
is the message subject (i.e. "A message for you!").
I'm assuming that your IT folks actually installed blat rather than just
putting it on your machine, which means that they told blat how to get to
your e-mail server. If they did this, then you're all set. If not, the
help will tell you how to install it -- you just need to know the name of
your e-mail server.
Good Luck,
Timothy P. Beck
First, please don't laugh.
Our company switched from Notes to Outlook, from Novell to
WinNT2000 and introduced Blat 1.9.4 to us this year. Changes are
welcome, but we do not have step by step intruction. Being non-
technical we have difficulty asking questions to IT. If we ask
questions, our bosses yell at us for being charged high $ by IT.
Helpdesk from India does not really help much, because of the
We have to send updated reports as email attachments through a
scheduler application repeately. Blat was installed by our local
computer admin. Now it is up to us to create the macros and the
batch files. Some of us have access to DOS (Win2K) some have (WinXP)
.
There is no BLat icon on the desktop or start/program. What must
we do to get Blat to work, to add the email addresses, subject name
to Blat available command? Whenever we click on Balt.exe, it
flashes quickly to the screen. That was it.
Do we have to be the programmer to use Blat? How can we make
these applications "talk" together? Do we need to go take a
programming class to write a bacth file?
Please recommend some solutions or alternatives. Your help is
much appreciated.
James in Plano.
--
http://www.blat.net
http://groups.yahoo.com/group/blat
Yahoo! Groups Sponsor
ADVERTISEMENT
------------------------------------------------------------------
-----
Post by Timothy P. Beck
Yahoo! Groups Links
http://groups.yahoo.com/group/blat/
Your use of Yahoo! Groups is subject to the Yahoo! Terms of
Service.
------------------------ Yahoo! Groups Sponsor --------------------~-->
Make a clean sweep of pop-up ads. Yahoo! Companion Toolbar.
Now with Pop-Up Blocker. Get it for free!
http://us.click.yahoo.com/L5YrjA/eSIIAA/yQLSAA/dkFolB/TM
--------------------------------------------------------------------~->
--
Homepage:
http://www.blat.net
Timothy P. Beck
2004-06-09 15:02:32 UTC
Permalink
James,

After your :end tag (not shown in your example), you should have a line that
looks something like this:

blat %body% %to% %f% %subject% %server% %attachment% %debug%

Each of the items enclosed by % are replaced when the batch file is run by
the values you "set" earlier in the batch file. In your example, the
command line above would actually run as:

blat -body \"Please review the attachments\"
-to ***@DraftinXYZ.com,***@draftinxyz.com
-f ***@Draftingxyz.com
-subject \"Test angles\"
-server dratftinserver.Draftinxyz.com
-attach CAD1.zip CAD2.zip CAD3.zip
-debug

NOTE: I put the commands on separate lines for easier reading ... they
should all be on one line. Also note, to attach a file, the command should
read "-attach" not "-attachment". Finally, in your example, the trailing
double-quote (") is missing from the server line.

Once you've got this working, you can add the icon for the batch file to
your desktop by right-mouse clicking on the desktop and choosing New -->
Shortcut, then following the prompts to add the file to the desktop.

HTH,

Timothy P. Beck
Post by thrusearch
Thank you Tim. You shed green light to us in 1 reply. We were
very excited to read the log file & learned our problems fast. At
least, something is...communicated back to us: error from host name
and not the socket error. We are getting somewhere with your
helps. Today, one of us brave soul have to talk to the computer man
for the mail server name while the rest of us will scury around to
run the batch file.
We copied the example batch file syntax and changed variables.
When we clicked on it, only the dos screen popped up with a cursor
~~~~~~~~~~
@echo off
set server = "-server dratftinserver.Draftinxyz.com
set subject = "-subject \"Test angles\""
set body = "-body \"Please review the attachments\""
set attachment = "-attachment CAD1.zip CAD2.zip CAD3.zip"
set debug = "-debug"
:goto end
echo end of file
~~~~~~~~~~~
We are still puzzled with the sample comment line in Blat's
instruction from the FAQ "::Here is where we run Blat."
What command to run the batch file? RUN? Execute? or simply
click on the CADReports.bat?
We are starting to get somewhere and sooooooooo excited...
Talking about old computer illiterated folks who getting
somewhere... We thank you much for your helps. Y'all have a nice
day. James in Plano
Post by Timothy P. Beck
Hello,
First, I'd recommend that you upgrade to the latest version of
Blat
(go to > www.blat.net -- click "Download"). Second, from a DOS
prompt
(Start -> Run - > > cmd -> OK), type "blat -h" (without the quotes)
to get the blat options. > Basic options are: > > BLAT
<filename> -to <to-email> -f <sender-email> -s "subject" > > Where
<filename> is the name of a file containing the body of your
message > (i.e. body.txt), <to-email> is the e-mail address of the
mail address and "subject" > is the message subject (i.e. "A
message for you!"). > > I'm assuming that your IT folks actually
installed blat rather than just > putting it on your machine,
which means that they told blat how to get to > your e-mail
server. If they did this, then you're all set. If not, the >
help will tell you how to install it -- you just need to know the
name of > your e-mail server. > > Good Luck, > > Timothy P. Beck
Post by Timothy P. Beck
On Tue, 08 Jun 2004 14:02:56 -0000, thrusearch wrote > > First,
please don't laugh. > > > > Our company switched from Notes to
Outlook, from Novell to > > WinNT2000 and introduced Blat 1.9.4 to
us this year. Changes are > > welcome, but we do not have step by
step intruction. Being non- > > technical we have difficulty asking
questions to IT. If we ask > > questions, our bosses yell at us
for being charged high $ by IT. > > Helpdesk from India does not
really help much, because of the > > language barrier, time zones
and other reasons. Our/my dilema: > > > > We have to send
updated reports as email attachments through a > > scheduler
application repeately. Blat was installed by our local > >
computer admin. Now it is up to us to create the macros and the > >
batch files. Some of us have access to DOS (Win2K) some have
(WinXP) > > . > > > > There is no BLat icon on the desktop
or start/program. What must > > we do to get Blat to work, to add
the email addresses, subject name > > to Blat available command?
Whenever we click on Balt.exe, it > > flashes quickly to the
screen. That was it. > > > > Do we have to be the programmer
to use Blat? How can we make > > these applications "talk"
together? Do we need to go take a > > programming class to write a
bacth file? > > > > Please recommend some solutions or
alternatives. Your help is > > much appreciated. > > > >
James in Plano. > > > > > > > > > > > > > > -- > >
Post by Timothy P. Beck
Post by thrusearch
http://www.blat.net
http://groups.yahoo.com/group/blat
Yahoo! Groups Sponsor
ADVERTISEMENT
----------------------------------------------------------------
--
-----
Post by Timothy P. Beck
Post by thrusearch
Yahoo! Groups Links
http://groups.yahoo.com/group/blat/
Your use of Yahoo! Groups is subject to the Yahoo! Terms of
Service.
--
http://www.blat.net
http://groups.yahoo.com/group/blat
Yahoo! Groups Sponsor
ADVERTISEMENT
-----------------------------------------------------------------------
Yahoo! Groups Links
http://groups.yahoo.com/group/blat/
Your use of Yahoo! Groups is subject to the Yahoo! Terms of
Service.
Timothy P. Beck



------------------------ Yahoo! Groups Sponsor --------------------~-->
Make a clean sweep of pop-up ads. Yahoo! Companion Toolbar.
Now with Pop-Up Blocker. Get it for free!
http://us.click.yahoo.com/L5YrjA/eSIIAA/yQLSAA/dkFolB/TM
--------------------------------------------------------------------~->
--
Homepage:
http://www.blat.net
Rick Nakroshis
2004-06-10 02:44:44 UTC
Permalink
Post by thrusearch
@echo off
set server = "-server dratftinserver.Draftinxyz.com
When you write a batch file, it's best if your SET statements do not have a
space before or after the equals sign. The following four lines do NOT do
the same thing, and are not identical:

set var1=A
set var1 =A
set var1= A
set var1 = A

It looks like an unimportant detail, but it can drive you crazy trying to
figure out why your batch file isn't doing what you think it ought to
be. Example:

set var1=A
set var1 =B
:: Next line will print "A"
echo %var1%
:: Next line will print "B"
echo %var1 %

Hope this helps,

Rick

[Non-text portions of this message have been removed]



------------------------ Yahoo! Groups Sponsor --------------------~-->
Make a clean sweep of pop-up ads. Yahoo! Companion Toolbar.
Now with Pop-Up Blocker. Get it for free!
http://us.click.yahoo.com/L5YrjA/eSIIAA/yQLSAA/dkFolB/TM
--------------------------------------------------------------------~->
--
Homepage:
http://www.blat.net
thrusearch
2004-06-22 06:27:55 UTC
Permalink
Hi y'all.

Thank you again for all your kind help. We three grandpas have been
sending email to recipients from dos mode. But we couldn't send email
by calling from Batch file. The attachments has less than 1.5Kb. We
may be asking wrong questions, but... could it be our bad batch
commands? Please don't chase us away yet. We have our dos command
here. We would greatly appreciate it if y'all can assist us again.

@Echo off
%0
:::::::: Test Batch and set generic names
REM – Setup names to use
:begin
cls
star /w Test.bat
set to="-to ***@gnrldxyz.com"
set f="-f ***@smithtestblat.com"
set server="-server draftinserver.Draftinxyz.com"
set pw="-pw mypassword"
set subject="-subject \"Test angles\""
set body="-body \"Text to accompany CAD.\""
set attach="-attach C:\ALLCAD.zip"
set debug="-debug"

::::::Generic file names
:Goto Macro
:CAD.macro
C:
cd\Program files\AutoCAD\
start /w CADmacro.exe C:\compiledmacro.mnx
if not exit==goto Error.log


:goto Error.log
C:
cd\Error.log
type %1 >> Error.Log


:GoTo
:Goto WinZip
C:
cd\Program Files\WinZip\WINZIP32.exe -AllCAD.zip Polygon.mcr
Rotate.mnx Blipmode.mpp

echo Done
Goto End
:end
echo End of File

:Run Blat
:Blat
blat C:\Test.txt %0% %to% %f% %server% %pw% %subject% %body% %attach%
%log% %debug%
Post by Rick Nakroshis
Post by thrusearch
@echo off
set server = "-server dratftinserver.Draftinxyz.com
When you write a batch file, it's best if your SET statements do not have a
space before or after the equals sign. The following four lines do NOT do
set var1=A
set var1 =A
set var1= A
set var1 = A
It looks like an unimportant detail, but it can drive you crazy trying to
figure out why your batch file isn't doing what you think it ought to
set var1=A
set var1 =B
:: Next line will print "A"
echo %var1%
:: Next line will print "B"
echo %var1 %
Hope this helps,
Rick
[Non-text portions of this message have been removed]
------------------------ Yahoo! Groups Sponsor --------------------~-->
Make a clean sweep of pop-up ads. Yahoo! Companion Toolbar.
Now with Pop-Up Blocker. Get it for free!
http://us.click.yahoo.com/L5YrjA/eSIIAA/yQLSAA/dkFolB/TM
--------------------------------------------------------------------~->
--
Homepage:
http://www.blat.net
Rick Nakroshis
2004-06-22 11:35:19 UTC
Permalink
Post by thrusearch
@Echo off
%0
What is the %0 doing for you here?
Post by thrusearch
:::::::: Test Batch and set generic names
A line that begins with two colon's is a remark, the same as if it started
with REM.
Post by thrusearch
REM – Setup names to use
:begin
Is ":begin" a batch label, used with a "GOTO", or is it just a comment here?
Post by thrusearch
cls
star /w Test.bat
set server="-server draftinserver.Draftinxyz.com"
set pw="-pw mypassword"
set subject="-subject \"Test angles\""
set body="-body \"Text to accompany CAD.\""
set attach="-attach C:\ALLCAD.zip"
set debug="-debug"
::::::Generic file names
:Goto Macro
:CAD.macro
What are the two lines above supposed to do? Are they supposed to be comments?
Post by thrusearch
cd\Program files\AutoCAD\
start /w CADmacro.exe C:\compiledmacro.mnx
if not exit==goto Error.log
I don't know that the line above is anything at all; that doesn't appear to
be proper batch syntax.
Post by thrusearch
:goto Error.log
Again, is that :goto supposed to be a label or actually doing something?
Post by thrusearch
cd\Error.log
type %1 >> Error.Log
:GoTo
:Goto WinZip
Two more labels in a row, and now the goto label is defined in two
different places.


Rick

[Non-text portions of this message have been removed]



------------------------ Yahoo! Groups Sponsor --------------------~-->
Yahoo! Domains - Claim yours for only $14.70
http://us.click.yahoo.com/Z1wmxD/DREIAA/yQLSAA/dkFolB/TM
--------------------------------------------------------------------~->
--
Homepage:
http://www.blat.net
Tim Musson
2004-06-22 12:02:32 UTC
Permalink
Hey Rick,

On Tuesday, June 22, 2004 at 7:35:19 AM you wrote

RN> A line that begins with two colon's is a remark, the same as if it
RN> started with REM.

Actually, :: is not quite the same as REM...

REM is executed as a command (read 3 chars, then process command).

:: is invalid 'label' syntax, and as such is ignored (and skipped) as
soon as the second : is read.

So :: is a better remark than REM, but with today's CPU's it doesn't
make much difference (it sure did in the day though!)...
--
Tim Musson
Flying with The Bat! eMail v2.11.02
What could possibly go wrong?
Blat Manager, current version is 2.2.2, see www.blat.net



------------------------ Yahoo! Groups Sponsor --------------------~-->
Yahoo! Domains - Claim yours for only $14.70
http://us.click.yahoo.com/Z1wmxD/DREIAA/yQLSAA/dkFolB/TM
--------------------------------------------------------------------~->
--
Homepage:
http://www.blat.net
thrusearch
2004-07-18 23:35:13 UTC
Permalink
Many of you helped me and my buddies last month. We can now send
mail and use batch files. A big thank you all Blat readers who helped
us 3 grandpas from Plano...
Post by Tim Musson
Hey Rick,
RN> A line that begins with two colon's is a remark, the same as if it
RN> started with REM.
Actually, :: is not quite the same as REM...
REM is executed as a command (read 3 chars, then process command).
:: is invalid 'label' syntax, and as such is ignored (and skipped) as
soon as the second : is read.
So :: is a better remark than REM, but with today's CPU's it doesn't
make much difference (it sure did in the day though!)...
--
Tim Musson
Flying with The Bat! eMail v2.11.02
What could possibly go wrong?
Blat Manager, current version is 2.2.2, see www.blat.net
------------------------ Yahoo! Groups Sponsor --------------------~-->
Make a clean sweep of pop-up ads. Yahoo! Companion Toolbar.
Now with Pop-Up Blocker. Get it for free!
http://us.click.yahoo.com/L5YrjA/eSIIAA/yQLSAA/dkFolB/TM
--------------------------------------------------------------------~->
--
Homepage:
http://www.blat.net
Tim Musson
2004-06-22 11:57:58 UTC
Permalink
Hey thrusearch,

On Tuesday, June 22, 2004 at 2:27:55 AM you wrote

t> Thank you again for all your kind help. We three grandpas have been
t> sending email to recipients from dos mode. But we couldn't send email
t> by calling from Batch file. The attachments has less than 1.5Kb. We
t> may be asking wrong questions, but... could it be our bad batch
t> commands? Please don't chase us away yet. We have our dos command
t> here. We would greatly appreciate it if y'all can assist us again.

Interesting batch file. Comments in-line.

t> @Echo off
t> %0
This %0 runs the batch, so you get a loop.
t> :::::::: Test Batch and set generic names
t> REM – Setup names to use
t> :begin
t> cls
t> star /w Test.bat
I don't know what this does
t> set to="-to ***@gnrldxyz.com"
t> set f="-f ***@smithtestblat.com"
t> set server="-server draftinserver.Draftinxyz.com"
t> set pw="-pw mypassword"
t> set subject="-subject \"Test angles\""
t> set body="-body \"Text to accompany CAD.\""
t> set attach="-attach C:\ALLCAD.zip"
t> set debug="-debug"

t> ::::::Generic file names
t> :Goto Macro
I am not sure what you are doing with :Goto Macro... If
the first char on the line is a : and it is followed by a word, that
is a position in a batch file to send execution to with the "goto"
command. However, a space is not a valid char...
If you use a double ::, that acts like a comment, is that what you are
going for here?
t> :CAD.macro
t> C:
t> cd\Program files\AutoCAD\
t> start /w CADmacro.exe C:\compiledmacro.mnx
t> if not exit==goto Error.log
I don't think this is correct syntax

t> :goto Error.log
t> C:
t> cd\Error.log
type %1 >>> Error.Log
I am not sure, but it doesn't look like this will do anything.

t> :GoTo
t> :Goto WinZip
t> C:
t> cd\Program Files\WinZip\WINZIP32.exe -AllCAD.zip Polygon.mcr
t> Rotate.mnx Blipmode.mpp

t> echo Done
t> Goto End
t> :end
The above 2 lines may be causing problems depending on your
OS. In some OS's END is implicit at the end of your batch
file, and putting :end in the middle somewhere can give odd
results.
t> echo End of File

t> :Run Blat
t> :Blat
t> blat C:\Test.txt %0% %to% %f% %server% %pw% %subject% %body% %attach%
t> %log% %debug%

Try this:
blat - %to% %f% %server% %pw% %subject% %body% %attach% %debug%
--
Tim Musson
Flying with The Bat! eMail v2.11.02
A person with a green thumb has a sore back and red knees to match
Blat Manager, current version is 2.2.2, see www.blat.net



------------------------ Yahoo! Groups Sponsor --------------------~-->
Make a clean sweep of pop-up ads. Yahoo! Companion Toolbar.
Now with Pop-Up Blocker. Get it for free!
http://us.click.yahoo.com/L5YrjA/eSIIAA/yQLSAA/dkFolB/TM
--------------------------------------------------------------------~->
--
Homepage:
http://www.blat.net
Bykai
2004-06-22 07:46:50 UTC
Permalink
... could it be our bad batch commands?
Is blat ever called in the processing of your batch file?
You may need to change your first line to read
REM @Echo off
to not suppress the command echoing to get a feeling where
the batch file fails to do what you want.
blat C:\Test.txt %0% %to% %f% %server% %pw% %subject% %body% %attach%
%log% %debug%
%0 will be expanded to the name of the batch file by the command
processor.
This will give a second positional parameter to the Blat call.
Blat will not like this.
try to remove the %0% in this line.
The log variable (referenced with %log%) seems not to be set
in your batch?


------------------------ Yahoo! Groups Sponsor --------------------~-->
Make a clean sweep of pop-up ads. Yahoo! Companion Toolbar.
Now with Pop-Up Blocker. Get it for free!
http://us.click.yahoo.com/L5YrjA/eSIIAA/yQLSAA/dkFolB/TM
--------------------------------------------------------------------~->
--
Homepage:
http://www.blat.net
Continue reading on narkive:
Loading...