Windows Vista Tips

Windows Vista Tips > Newsgroups > Windows Vista General Discussion > How Do I Get a Batch File to Run on Vista?

Reply
Thread Tools Display Modes

How Do I Get a Batch File to Run on Vista?

 
 
jim evans
Guest
Posts: n/a

 
      10-26-2008
I have a computer illiterate friend who is an author. He composes his
manuscripts in Word but knows nothing else about his computer. I
tried to help him automate some processes using batch files just to
discover I can't make batch files work in Vista. I followed this
procedure
http://www.vistaclues.com/run-a-batc...administrator/

It throws up the UAC prompt but seems to do nothing when you click the
button to authorize it.

How do I make batch files work in Vista?

jim
 
Reply With Quote
 
 
 
 
NormCameron
Guest
Posts: n/a

 
      10-26-2008

That procedure authorises a BAT file to run as Administrator by amending
it's properties. To run a BAT file goto [Start] [Accessories] [Command
Prompt].


--
NormCameron


 
Reply With Quote
 
jim evans
Guest
Posts: n/a

 
      10-27-2008
On Sun, 26 Oct 2008 18:23:51 -0500, NormCameron
<> wrote:

>That procedure authorises a BAT file to run as Administrator by amending
>it's properties. To run a BAT file goto [Start] [Accessories] [Command
>Prompt].


If I have to have him do anything that elaborate, I might as well set
him up with cookbook scripts to follow. I was trying to set him up
with batch files he simply double-clicks on to do the actions.

I take it from your reply there's no way in Vista to run a batch file
in a simple straightforward way like you can in XP, NT or Win9x. I'm
beginning to understand the negative feelings about Vista.

jim
 
Reply With Quote
 
Lang Murphy
Guest
Posts: n/a

 
      10-27-2008
"jim evans" <> wrote in message
news:...
>I have a computer illiterate friend who is an author. He composes his
> manuscripts in Word but knows nothing else about his computer. I
> tried to help him automate some processes using batch files just to
> discover I can't make batch files work in Vista. I followed this
> procedure
> http://www.vistaclues.com/run-a-batc...administrator/
>
> It throws up the UAC prompt but seems to do nothing when you click the
> button to authorize it.
>
> How do I make batch files work in Vista?
>
> jim



Jim,

What is this batch file attempting to accomplish? I can run a bat file here,
with UAC enabled, without getting a UAC prompt. (But then I'm not doing
anything other than throwing a pause command in the batch file...)

Setting the batch file to run as administrator -will- throw a UAC prompt
when UAC is enabled. Are you sure this batch file -needs- to run as
administrator? What happens if your friend just tries to run the bat file by
double clicking on it? (Without having "run as administrator" set.)

Lang

 
Reply With Quote
 
NormCameron
Guest
Posts: n/a

 
      10-27-2008

An alternative is to change a batch file shortcut’s target to have
cmd /c inserted before the batch file location. For example a batch for
with a target of:c:\batchfiles\mybatch.bat would need to be changed
to:cmd /c c:\batchfiles\mybatch.bat.


--
NormCameron


 
Reply With Quote
 
Stuart Sabatini
Guest
Posts: n/a

 
      10-28-2008
I simply right click on the batch file and drag to the desktop or taskbar,
then select create short cut. UAC is enabled but causes no problem when the
batch file is run. It does not pop up. I do not have run as administrator
selected in the shortcut properties. My batch files are simple copy
commands to a USB stick drive or DVD.

Stuart

"jim evans" <> wrote in message
news:...
>I have a computer illiterate friend who is an author. He composes his
> manuscripts in Word but knows nothing else about his computer. I
> tried to help him automate some processes using batch files just to
> discover I can't make batch files work in Vista. I followed this
> procedure
> http://www.vistaclues.com/run-a-batc...administrator/
>
> It throws up the UAC prompt but seems to do nothing when you click the
> button to authorize it.
>
> How do I make batch files work in Vista?
>
> jim


 
Reply With Quote
 
jim evans
Guest
Posts: n/a

 
      10-28-2008
Well, it's a little embarrassing but here's the answer. Apparently
when Windows is set to not show extension of files with known parents
it NEVER shows them. I thought it just didn't show them in Explorer,
but even when you highlight the name to change it, it doesn't show the
extension. So, if you highlight a file name, delete it entirely and
rename it you really don't delete it entirely -- the extension is
still there, just invisible. So, if you create a new file using the
Right Click > New menu you can never get rid of the .txt extension.
No matter what you do the .txt extension remains. So when you rename
it to bat it becomes bat.txt.

You have to create it in an application like Notepad and save it as a
..bat file or it's still a text file.

jim
 
Reply With Quote
 
+Bob+
Guest
Posts: n/a

 
      10-28-2008
On Tue, 28 Oct 2008 17:55:06 -0600, jim evans
<> wrote:

>Well, it's a little embarrassing but here's the answer. Apparently
>when Windows is set to not show extension of files with known parents
>it NEVER shows them. I thought it just didn't show them in Explorer,
>but even when you highlight the name to change it, it doesn't show the
>extension. So, if you highlight a file name, delete it entirely and
>rename it you really don't delete it entirely -- the extension is
>still there, just invisible. So, if you create a new file using the
>Right Click > New menu you can never get rid of the .txt extension.
>No matter what you do the .txt extension remains. So when you rename
>it to bat it becomes bat.txt.
>
>You have to create it in an application like Notepad and save it as a
>.bat file or it's still a text file.
>
>jim


That problem goes back several generations of windows. Always show
file extensions.

Yet another example where dumbing-down windows just makes it
impossible to get real work done.
 
Reply With Quote
 
 
 
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Vista: Batch file cannot find path of exe Bruce Windows Vista General Discussion 5 09-26-2009 05:23 AM
Vista: Batch file cannot find path of exe Bruce Windows Vista General Discussion 1 12-11-2008 12:27 AM
Vista Task Scheduler - Batch File MCM Windows Vista General Discussion 2 06-27-2008 07:30 PM
vista batch file problem Stephen Windows Vista General Discussion 1 04-30-2008 03:21 PM
Batch file renaming in Vista doesn't work! Malcolm H Windows Vista General Discussion 9 03-22-2008 01:00 AM



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59