Jump to content

Batch File


Prayder
 Share

Recommended Posts

My batch files keep creating a duplicate icon when they are ran. Instead of replacing the existing icon it just adds another one to my desktop. How can I fix this? Here is what one of my files look like:

ECHO OFF
@echo "Waiting for Position Matrix to shut down"
c:
cd\
mkdir databases
C:
cd\databases
del Inventory_mgr.mdb
o:
CD\WWP Shared\Databases
ECHO ON
echo "PLEASE WAIT WHILE FILES ARE BEING COPIED!!!"
echo "This box will close upon completion!!!!"
ECHO OFF
copy Inventory_mgr.mdb C:\databases
copy FREE3OF9.ttf c:\databases
CD\WWP Shared\Databases\icons
Copy Inventory_mgr.ico c:\databases
CD\WWP Shared\Databases\shortcuts
copy Inventory_mgr.lnk c:\databases

rem *******************************************
rem Window 7 fix
c:
cd\
cd databases
copy Inventory_mgr.lnk %userprofile%\Desktop

rem *****************************************
rem windows xp
c:
cd \
cd documents and settings
cd all users
cd desktop
copy c:\databases\Inventory_mgr.lnk
C:\databases\Inventory_mgr.mdb

rem ************************************************

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.

 Share

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. Privacy Policy