Computer Hope

Microsoft => Microsoft DOS => Topic started by: KenL on June 10, 2009, 07:39:06 AM

Title: Bat2Exe problems when using icons.
Post by: KenL on June 10, 2009, 07:39:06 AM
Hello all, I'm BACK!

I started to use the Bat_to_exe_converter and all was well. It created an exe file and when I added the ghost option the CMD window diappeared, everything is perfect.

Until I added an ICON file. Now it produces nothing.

Any ideas?
Title: Re: Bat2Exe problems when using icons.
Post by: BatchFileBasics on June 10, 2009, 03:27:39 PM
it could be problems with valid icons\ valid sizes
Title: Re: Bat2Exe problems when using icons.
Post by: billrich on June 10, 2009, 04:14:32 PM
An icon is a small file that contains the address or path to usually a program that you have installed.  The icon can be removed and the program will still function.

Search for the recently installed program. In the search results, point to the program, right click and choose to create a new icon for your desktop.

If the new "bat to exe" converter continues not to work correctly, go the the folder where the "bat to exe" is stored and run the program without using an icon.

If you continue to have problems reinstall "bat to exe" after removing the first installation and cleaning the registry.

If you still have problems, restore system to an earlier date when all was well.

Good Luck

Title: Re: Bat2Exe problems when using icons.
Post by: BC_Programmer on June 10, 2009, 04:26:57 PM
billrich- unfortunately, that has *censored* near nothing to do with his issue, and additionally, it describes a "shortcut" not an icon. An Icon is just a bitmap and a mask or alpha channel.
Title: Re: Bat2Exe problems when using icons.
Post by: billrich on June 10, 2009, 04:42:01 PM
billrich- unfortunately, that has <censored> near nothing to do with his issue, and additionally, it describes a "shortcut" not an icon. An Icon is just a bitmap and a mask or alpha channel.


Definition:

Quote
"An icon is a tiny picture on the screen that represents a program, file or folder.

Explanation:

Icons make it easy to find what you are looking for. To tell the computer to open a file,
folder or program, double-click on the icon. To select an item, click only once on the icon.

Desktop icons are the most commonly recognized icons by most people.
They are used to convey purpose of an available function on a computer.

On a very graphic oriented Windows environment such as Windows XP the common desktop icons
you might see are “My Computer”, “Recycle Bin”, and various file folders with labels.


http://www.microsoft.com/windowsxp/using/setup/personalize/shortcuts.mspx
">>>>>
Title: Re: Bat2Exe problems when using icons.
Post by: BC_Programmer on June 10, 2009, 04:46:26 PM
http://en.wikipedia.org/wiki/Icon_(computing)

http://en.wikipedia.org/wiki/Computer_shortcut


different concepts.


either way...


Quote

Until I added an ICON file. Now it produces nothing.

What is meant by this? the bat2exe converter program simply doesn't make the file, or ?

Title: Re: Bat2Exe problems when using icons.
Post by: billrich on June 10, 2009, 05:00:35 PM
BC wrote:

Quote
"What is meant by this? the bat2exe converter program simply doesn't make the file, or ?"

Yes, BC is right. It is most likely the "bat to exe" program and not the icon.

But the problem could be either the icon or the "bat to exe"

p.s.  I'm sorry if I was rude.  I see no need for a "bat to exe" program.
Title: Re: Bat2Exe problems when using icons.
Post by: BC_Programmer on June 10, 2009, 05:22:26 PM
I think, what is happening, is that, the bat converter program, or whatever it is, let's the person change the icon of the resulting executable from the drab application icon. But I'm not 100% on what is happening when they try, wether the program simply doesn't work, the icon isn't showing that they want, or the program is never created is something only the OP can answer.

Either way, the whole idea of converting a batch to a executable for the sole purpose of being able to hide it's execution seems a bit out of the way.
Title: Re: Bat2Exe problems when using icons.
Post by: BatchFileBasics on June 10, 2009, 06:50:07 PM
well for all we know, it could be something to make sure a process is running(like a firefox preloader) and he does't want the window up.
but thats just me

any who...

bat2exe works perfect for me, invisible or not.

make sure you have the most current:
Code: [Select]
http://download.cnet.com/Bat-To-Exe-Converter/3000-2069_4-10555897.html?tag=mncol
Title: Re: Bat2Exe problems when using icons.
Post by: KenL on June 11, 2009, 06:50:25 AM
Sorry guys I was knee deep in DOS scripting yesterday and was not looking at emails.

The Bat_To_Exe_Converter doesn't create the file when the ICON is added.
I have used this tool for 2 reasons, 1 is to hide the source code from the client and 2 is to stop the DOS CMD window from showing during execution (very annoying).

When I use it without the icon, it works perfectly (although still trying to figure out the redirecting of echo statements to a log file). Even using the Ghost option works perfectly.

As soon as I add an icon, it produces nothing. I use the icons on the shortcuts without any problems.

I just downloaded the version from the UTILS section yesterday. I assume this is the latest version.

Ken
Title: Re: Bat2Exe problems when using icons.
Post by: BC_Programmer on June 11, 2009, 09:03:39 AM
I'll say this- using it to hide your source is only effective at a basic level, (IE they simply cannot right-click and edit). But, I do have an idea.

You could try, Instead of telling the program to create it with an ICO file, create it without one, and then use Resource hacker (http://www.angusj.com/resourcehacker/) to add the icon. Assuming of course the new version still doesn't work.


Also, this is an ICO file, correct?
Title: Re: Bat2Exe problems when using icons.
Post by: KenL on June 11, 2009, 10:33:08 AM
Thanks guys, Yes it is an ICO file.

Never heard of Resource Hacker, will have to look at this.

Another issue just came up that maybe someone here can answer. In the BAT file (before compiling) I have an "Echo Running %1", this works when the file is a BAT file called from another  BAT file, but as soon as I 'exe' it, the echo statement disappears. Anyone have an idea for a work around here?

Ken
Title: Re: Bat2Exe problems when using icons.
Post by: BatchFileBasics on June 11, 2009, 10:38:18 AM
well using %1,%2,%3, etc

is putting input into a variable.

if i were to have a batch file:
Code: [Select]
@echo off
echo %1
pause

then i drag a file into the batch file, it would show:
Code: [Select]
c:\path of file\file.txt
press any key to...

so if you don't have that input, theres nothing to show
Title: Re: Bat2Exe problems when using icons.
Post by: TheHoFL on June 11, 2009, 10:39:03 AM
I also use this app when converting to EXE and i have had issues with filling out ANY of the "additional informations" area. Are you filling this out at all?
Title: Re: Bat2Exe problems when using icons.
Post by: KenL on June 11, 2009, 10:41:16 AM
Yes I am using the Author line, works ok for me. Sorry the Company Line

As for the comment from BatchFileBasics.....I have the variable filled with the file that I am running just like it did when it was in BAT format
Title: Re: Bat2Exe problems when using icons.
Post by: BatchFileBasics on June 11, 2009, 10:43:58 AM
well im talking about when you call the batch file, it shows the line, but when you just run it, it doesn't.

do you want it to echo its own path?
Title: Re: Bat2Exe problems when using icons.
Post by: TheHoFL on June 11, 2009, 10:44:57 AM
I honestly have always had issues with the "additional info" area. Have you tried unchecking that box and checking the "ghost applications" box?

EDIT: I followed the link that BatchFileBasics sent to download the new version (v1.5). It rocks! I was using 1.4 until now. So the comments i made were regarding 1.4. Thank you BatchFileBasics!
Title: Re: Bat2Exe problems when using icons.
Post by: billrich on June 11, 2009, 12:42:19 PM
Ken wrote:
Quote
Another issue just came up that maybe someone here can answer. In the BAT file (before compiling) I have an "Echo Running %1", this works when the file is a BAT file called from another  BAT file, but as soon as I 'exe' it, the echo statement disappears. Anyone have an idea for a work around here?

There are other controls for redirection:
http://www.zsh.org/mla/users/1997/msg00526.html

Quote
"Will interpret the `1>&2' as
saying you want stdout to go to both the old stderr *and* the pipe,
which in this case you don't." 


Your bat to exe converter might have command line options for redirection?
or
the following workaround might survive the conversion process:

echo Running %1  1>output.txt

type output.txt

Title: Re: Bat2Exe problems when using icons.
Post by: KenL on June 11, 2009, 01:21:37 PM
WOOOHOOO that worked.
The 1>output.txt  did it.

I'M FREE...lol

Thanks guys, just have the ICON to test next.

V1.5 is definately better.
Title: Re: Bat2Exe problems when using icons.
Post by: TheHoFL on June 11, 2009, 04:08:38 PM
I definitely agree too! I can add the "additional informations" area without ANY issues at all!