Jump to content

Weird Batch Problem


G-Stress

Recommended Posts

Just wondering, I was messing around with batch and got a werid error about @echo off not being recognized as a internal or external command with some weird text before the @ sign, but it doesn't show up in the .bat file itself. I'm using now Quick Batch File Compiler and when I copied and pasted the text it then displayed this before the @ sign

@echo off

anybody know why that is?

Link to comment
Share on other sites

Just wondering, I was messing around with batch and got a werid error about @echo off not being recognized as a internal or external command with some weird text before the @ sign, but it doesn't show up in the .bat file itself. I'm using now Quick Batch File Compiler and when I copied and pasted the text it then displayed this before the @ sign

@echo off

anybody know why that is?

And hidden cahracters showing up after you try to run it? If its compiled code you open the exe you are going to see weird data since its no longer a plain text bat file any more. You do not run it as a bat file, but it is supposed to compile it to an exe, so yeah, that will have funky looking code in it once it is converted. Never used the program, but that is my guess. But if its in the editor for the program before its compiled and is seeing that then maybe it needs the text in a certain encoding format.

Is this in the editor for the pprogram that you see these things? Maybe you are pasting in text in a different format than the program uses, like the difference between UTF encoding and Ascii characters? Again, I have not used the program your referring to so I do not know what its settings are looking for.

Why are you creating exe's from bat files anyway? Why not just code an exe to do the same thing and this way you know what is going on under the hood. "Quick Batch File Compiler" just sounds like asking for trouble. Make sure you scan it and upload it to be scanned for virus, etc.

Link to comment
Share on other sites

@ digip,

Actually Quick Batch File Complier is pretty good. I would love to create .exe's but im a n00b :-( I'm "learning" batch scripting I guess you could say. Basically i'm trying to create a "switchblade" like package out of .bat file(s) and then from there I want to create the same thing in VB, then maybe c, etc. It's helping me understand alot about the cmd interface and out things work, working on this project.

You should really check out QBFC I'm actually surprised you haven't already.

http://www.abyssmedia.com/quickbfc/

But no I don't think it's a matter of encoding, but it could be. It's so weird cause this is what happens. Say I create just a basic bat file of

@echo off
REM This is my bat file

echo Hello world

exit

Then when I run that bat file it gives me an error, this error to be exact

'???@echo' is not recognized as an internal or external command,
operable program or batch file.

but that weird text before the @ sign does not appear at all in my bat file, but when I paste the text from my bat file into QBFC it appears as

@echo off

So weird. I didn't know if anyone else had experienced this before.

Link to comment
Share on other sites

Instead of pasting it, can you just type it into the program manually?

Link to comment
Share on other sites

Yea that isn't an issue at all. I just have no idea where it's coming from.

Maybe it is inserting the CRLF or something like that when you paste it.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

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