Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Batch File

Posted on 2007-03-26
8
Medium Priority
?
546 Views
Last Modified: 2010-04-16
Hello Everyone.

I am writing a batch file to uninstall a piece of software (Arkeia Backup Software).  The batch file works until it gets to the point where it ask the question to "Continue" or "Cancel".  Does anyone know the command to tell a batch file to select "continue" and continue running.  

cd %windir%\system32

net stop arkboot
cd\
cd C:\Program Files\Arkeia\Arkeia\bin\
arkboot -remove
cd\
cd C:\Program Files\
rmdir arkeia /s /q
cd\
cd c:\windows\
arkuinst.exe
0
Comment
Question by:CEAllen6216
8 Comments
 
LVL 67

Expert Comment

by:sirbounty
ID: 18793034
try
arkboot /?
it might give you the parameter for that...

Otherwise, I'd imagine you could overcome this with vbscripting, if you're interested...
0
 
LVL 7

Expert Comment

by:avatar-e
ID: 18793050
A pure batch file can't do that but you can call a groundcontrol Windows Macro from batch, however maybe is better do all the unninstalation process automated by GControl.

www.acrasoft.com
0
 
LVL 9

Expert Comment

by:sah18
ID: 18793191
do you know which line is giving you the "continue or cancel" prompt?
0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:CEAllen6216
ID: 18793854
Sirbounty,

I have tried the arkuinst /? but there are no switches.  I would not mind a script but I am not very good with scripts and I need to do this today.  So for me the bat file was suppose to be faster.

sah18,

It is the line with arkuinst.exe

0
 
LVL 67

Expert Comment

by:sirbounty
ID: 18794334
Try this - save as arkremove.vbs

Dim objShell:Set objShell=CreateObject("Wscript.shell") ' for 'shell' references
Dim objFSO:Set objFSO=CreateObject("Scripting.FileSystemObject") 'file system reference
objShell.Run "net stop arkboot"  'stop the service
objShell.Run "C:\Program Files\Arkeia\Arkeia\bin\arkboot -remove" 'run this command
objFSO.DeleteFolder "C:\Program Files\arkeia", True 'delete this folder
objShell.Run "c:\windows\arkuinst.exe"
Set objFSO=Nothing
Set objShell=Nothing
'end

'Now from the above, the only things you need to be concerned with 'auto' answering the prompt is (1) the window title of the pop up (may need to run it manually once to get the exact title name and (2) timings...

For the timings - where does the popup occur?  After the arkboot -remove?
If so, then adjust the script to this

Dim objShell:Set objShell=CreateObject("Wscript.shell") ' for 'shell' references
Dim objFSO:Set objFSO=CreateObject("Scripting.FileSystemObject") 'file system reference
objShell.Run "net stop arkboot"  'stop the service
objShell.Run "C:\Program Files\Arkeia\Arkeia\bin\arkboot -remove" 'run this command
objShell.AppActivate "Arkboot remove popup" 'activates 'this' window/popup
objShell.SendKeys "~" 'sends an 'enter' key to that window
objFSO.DeleteFolder "C:\Program Files\arkeia", True 'delete this folder
objShell.Run "c:\windows\arkuinst.exe"
Set objFSO=Nothing
Set objShell=Nothing
'end
0
 

Author Comment

by:CEAllen6216
ID: 18794988
Hi SirBounty

Thank You very much for the script.  When I run it, it says it can't find the file specified.  What I notice is that it is not changing to the c:\program files\arkeia\arkeia\bin.  Could this be because I am trying to push it out through SMS
0
 
LVL 67

Accepted Solution

by:
sirbounty earned 2000 total points
ID: 18795117
It wouldn't be changing directories but simply calling that executable from that folder...

You might try enclosing it in quotes:

Dim objShell:Set objShell=CreateObject("Wscript.shell") ' for 'shell' references
Dim objFSO:Set objFSO=CreateObject("Scripting.FileSystemObject") 'file system reference
objShell.Run "net stop arkboot"  'stop the service
objShell.Run chr(34) & "C:\Program Files\Arkeia\Arkeia\bin\arkboot -remove" & chr(34) 'run this command
objShell.AppActivate "Arkboot remove popup" 'activates 'this' window/popup
objShell.SendKeys "~" 'sends an 'enter' key to that window
objFSO.DeleteFolder "C:\Program Files\arkeia", True 'delete this folder
objShell.Run "c:\windows\arkuinst.exe"
Set objFSO=Nothing
Set objShell=Nothing
'end

Admin Edit
0
 
LVL 67

Expert Comment

by:sirbounty
ID: 18796264
Happy to help! - thanx for the grade!! :^)
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

You may have already been in the need to update a whole folder stucture using a script. Robocopy does it well and even provides a list of non-updated files in a log (if asked to). Generally those files that were locked by a user or a process by the …
Use this article to create a batch file to backup a Microsoft SQL Server database to a Windows folder.  The folder can be on the local hard drive or on a network share.  This batch file will query the SQL server to get the current date & time and wi…
Two types of users will appreciate AOMEI Backupper Pro: 1 - Those with PCIe drives (and haven't found cloning software that works on them). 2 - Those who want a fast clone of their boot drive (no re-boots needed) and it can clone your drive wh…
This lesson discusses how to use a Mainform + Subforms in Microsoft Access to find and enter data for payments on orders. The sample data comes from a custom shop that builds and sells movable storage structures that are delivered to your property. …
Suggested Courses
Course of the Month10 days, 1 hour left to enroll

926 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question