Page 2 of 5 <12345>
Topic Options
#173352 - 2007-01-29 03:27 AM Re: ANY SAVIOUR I N HERE TODAY?? [Re: Les]
selormquarshie Offline
Getting the hang of it

Registered: 2006-12-24
Posts: 85
....to make sure the desired output will be gained when i deploy it......please any help will be huge
Top
#173353 - 2007-01-29 04:04 AM Re: ANY SAVIOUR I N HERE TODAY?? [Re: selormquarshie]
Les Offline
KiX Master
*****

Registered: 2001-06-11
Posts: 12734
Loc: fortfrances.on.ca
It seems somewhat unnecessary to run in debug mode given that you popup a MessageBox() on Exist() and $programpath + "Does not Exist" on failure.

If you DON'T get the MessageBox() and you DO get $programpath + "Does not Exist", then obviously the folder does NOT Exist(). That is where you need to look.
_________________________
Give a man a fish and he will be back for more. Slap him with a fish and he will go away forever.

Top
#173356 - 2007-01-29 08:26 AM Re: ANY SAVIOUR I N HERE TODAY?? [Re: selormquarshie]
NTDOC Administrator Offline
Administrator
*****

Registered: 2000-07-28
Posts: 11623
Loc: CA
Quote:
shell 'C:\WINDOWS\uninst.exe -y -f"C:\Program Files\Pivotal\Relation" /passive' Sleep 6



You should not call C:\WINDOWS as a hard coded path. This can lead to failure on some systems which might have Windows installed in another folder such as WINNT or another and possibly even on another drive.

According to Microsoft documentation %SystemRoot% is the preferred method of locating the installation folder however in practice it does not appear that anyone is following that directive from what I see. In either case

%SystemRoot% or %WINDIR% should return the installation location of Windows.

.

Top
#173381 - 2007-01-30 02:43 AM Re: ANY SAVIOUR I N HERE TODAY?? [Re: NTDOC]
selormquarshie Offline
Getting the hang of it

Registered: 2006-12-24
Posts: 85
here's my latest code for the software removal...any ommissions or additions or ideas to tune this up will be appreciated........

Break Off
$programpath="HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\Pivotal\Relation\DeIsL1.isu"

If Exist($programpath) = 0

Shell '%systemroot%\system32\uninst.exe -y -f"HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\Pivotal\Relation\DeIsL1.isu"
" /passive'
Sleep 6

$rc = Shutdown("", "System is being rebooted to enable new settings.", 30, 0, 1)

Else
? $programpath + "Does not Exist"
EndIf

Top
#173382 - 2007-01-30 03:24 AM Re: ANY SAVIOUR I N HERE TODAY?? [Re: selormquarshie]
Les Offline
KiX Master
*****

Registered: 2001-06-11
Posts: 12734
Loc: fortfrances.on.ca
You cannot use Exist($programpath) that points to the registry.
_________________________
Give a man a fish and he will be back for more. Slap him with a fish and he will go away forever.

Top
#173383 - 2007-01-30 03:28 AM Re: ANY SAVIOUR I N HERE TODAY?? [Re: Les]
selormquarshie Offline
Getting the hang of it

Registered: 2006-12-24
Posts: 85
I do have a laptop with Relationship installed yet still when i run the code it doesn't uninstall it......please anyone help....



$programpath= "C:\Program Files\Pivotal\Relation"

If Exist($programpath) = 0

MessageBox ("", "Please wait while Relationship is uninstalled","ESI INT'L", 10, 0, 1)

Shell 'C:\WINDOWS\MsiExec.exe -y -f"C:\Program Files\Pivotal\Relation" '

$rc = Shutdown("", "System is being rebooted to enable new settings.", 30, 0, 1)

Sleep 6

Else
? $programpath + "Does not Exist"
EndIf
$rc = Shutdown("", "System is being rebooted to enable new settings.", 30, 0, 1)

Else
? $programpath + "Does not Exist"
EndIf


Edited by selormquarshie (2007-01-30 03:37 AM)

Top
#173384 - 2007-01-30 03:33 AM Re: ANY SAVIOUR I N HERE TODAY?? [Re: selormquarshie]
Les Offline
KiX Master
*****

Registered: 2001-06-11
Posts: 12734
Loc: fortfrances.on.ca
-f"HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\Pivotal\Relation\DeIsL1.isu"
is not a valid switch.
_________________________
Give a man a fish and he will be back for more. Slap him with a fish and he will go away forever.

Top
#173385 - 2007-01-30 03:40 AM Re: ANY SAVIOUR I N HERE TODAY?? [Re: Les]
selormquarshie Offline
Getting the hang of it

Registered: 2006-12-24
Posts: 85
I do have a laptop with Relationship installed yet still when i run the code it doesn't uninstall it......please anyone help....


$programpath= "C:\Program Files\Pivotal\Relation"

If Exist($programpath) = 0

MessageBox ("", "Please wait while Relationship is uninstalled","ESI INT'L", 10, 0, 1)

Shell 'C:\WINDOWS\MsiExec.exe -y -f"C:\Program Files\Pivotal\Relation" '

$rc = Shutdown("", "System is being rebooted to enable new settings.", 30, 0, 1)

Sleep 6

Else
? $programpath + "Does not Exist"
EndIf

Top
#173386 - 2007-01-30 03:43 AM Re: ANY SAVIOUR I N HERE TODAY?? [Re: selormquarshie]
Les Offline
KiX Master
*****

Registered: 2001-06-11
Posts: 12734
Loc: fortfrances.on.ca
If Exist() = 0

Means IF NOT EXIST!
_________________________
Give a man a fish and he will be back for more. Slap him with a fish and he will go away forever.

Top
#173387 - 2007-01-30 03:45 AM Re: ANY SAVIOUR I N HERE TODAY?? [Re: Les]
selormquarshie Offline
Getting the hang of it

Registered: 2006-12-24
Posts: 85
here are my changes......but i'm buffled by this code..it still wont output right.....i need to submit this tomorrrow....please help...


$programpath= "C:\Program Files\Pivotal\Relation"

If Exist($programpath) = 1

MessageBox ("", "Please wait while Relationship is uninstalled","ESI INT'L", 10, 0, 1)

Shell 'C:\WINDOWS\uninst.exe -y -f"C:\Program Files\Pivotal\Relation\DeIsL1.isu" '

$rc = Shutdown("", "System is being rebooted to enable new settings.", 300, 0, 1)

Sleep 6

Else
? $programpath + "Does not Exist"
EndIf

Top
#173390 - 2007-01-30 05:28 AM Re: ANY SAVIOUR I N HERE TODAY?? [Re: selormquarshie]
Sealeopard Offline
KiX Master
*****

Registered: 2001-04-25
Posts: 11164
Loc: Boston, MA, USA
How can one help you if you don't heed any advice?

You should test the code step-by-step.
_________________________
There are two types of vessels, submarines and targets.

Top
#173391 - 2007-01-30 06:04 AM Re: ANY SAVIOUR I N HERE TODAY?? [Re: Sealeopard]
selormquarshie Offline
Getting the hang of it

Registered: 2006-12-24
Posts: 85
ok here i come again....i figured that C:\Program Files\Pivotal\Relation is a folder not a file. i may be wrong or right...however if this isn't the right file, what command do i use to locate a FOLDER instead of a file?? i realize the EXIST command is to locate a file not folder........ any help??
Top
#173392 - 2007-01-30 06:12 AM Re: ANY SAVIOUR I N HERE TODAY?? [Re: selormquarshie]
Sealeopard Offline
KiX Master
*****

Registered: 2001-04-25
Posts: 11164
Loc: Boston, MA, USA
So, what is it? Is it a fodler or file? It's yoru system, you should be able to determine what it is. EXIST can check for both the existance of a folder and/or file.

Code:
? 'KiXtart v'+@kix
$folder='C:\Program Files\Pivotal\Relation'
select
case exist($folder+'\')
  ? $folder + 'is a folder and exists'
case exist($folder)
  ? $fodler + ' is a file and exists'
case 1
  ? 'Cannot find a file or folder by name f ' + $folder
endselect

Please run this codefragment and report the results.
_________________________
There are two types of vessels, submarines and targets.

Top
#173393 - 2007-01-30 06:25 AM Re: ANY SAVIOUR I N HERE TODAY?? [Re: Sealeopard]
selormquarshie Offline
Getting the hang of it

Registered: 2006-12-24
Posts: 85
yea it read " c:\program files\pivotal\relation is a folder and exists

Edited by selormquarshie (2007-01-30 06:30 AM)

Top
#173394 - 2007-01-30 06:38 AM Re: ANY SAVIOUR I N HERE TODAY?? [Re: selormquarshie]
NTDOC Administrator Offline
Administrator
*****

Registered: 2000-07-28
Posts: 11623
Loc: CA
Is this an application for CRM from here: http://www.pivotal.com/products/

If so which one?

What version of KiXtart are you using?

Top
#173395 - 2007-01-30 06:41 AM Re: ANY SAVIOUR I N HERE TODAY?? [Re: NTDOC]
selormquarshie Offline
Getting the hang of it

Registered: 2006-12-24
Posts: 85
yes it's from there and the program is Relationship. kix version 4.51
Top
#173396 - 2007-01-30 06:46 AM Re: ANY SAVIOUR I N HERE TODAY?? [Re: selormquarshie]
NTDOC Administrator Offline
Administrator
*****

Registered: 2000-07-28
Posts: 11623
Loc: CA
Why do you keep changing from UNINSTAL to MSIEXEC ?

If you look on a client and at the uninstall string you need the EXACT string they supply.

Please provide that here.

Top
#173397 - 2007-01-30 06:46 AM Re: ANY SAVIOUR I N HERE TODAY?? [Re: selormquarshie]
selormquarshie Offline
Getting the hang of it

Registered: 2006-12-24
Posts: 85
when i run the script by Sealeopard is confirms the existence of the folder however when i run the following code it doesn't remove it. rather it jumps from the MESSAGEBOX to the DOES NOT EXIT line.....weird..


Break off

$programpath= "C:\Program Files\Pivotal\Relation"

If Exist($programpath) = 1

MessageBox ("", "Please wait while Relationship is uninstalled","ESI INT'L", 10, 0, 1)

Shell 'C:\WINDOWS\uninst.exe -y -f"C:\Program Files\Pivotal\Relation\DeIsL1.isu"'

$rc = Shutdown("", "System is being rebooted to enable new settings.", 300, 0, 1)

Sleep 6

Else
? $programpath + "Does not Exist"
EndIf

Top
#173398 - 2007-01-30 06:48 AM Re: ANY SAVIOUR I N HERE TODAY?? [Re: selormquarshie]
selormquarshie Offline
Getting the hang of it

Registered: 2006-12-24
Posts: 85
this is the exact script i found for the uninstall......

C:\WINDOWS\uninst.exe -f"C:\Program Files\Pivotal\Relations\DeIsL1.isu

Top
#173399 - 2007-01-30 07:07 AM Re: ANY SAVIOUR I N HERE TODAY?? [Re: selormquarshie]
NTDOC Administrator Offline
Administrator
*****

Registered: 2000-07-28
Posts: 11623
Loc: CA
Please use CODE TAGS when posting to preserve the formatting.

I did not ask for the script you found, though if you found that one a link to where you found it would be good.

Please copy this into a clean new script and run it like this from a workstation that has it installed and report back exactly what it returns.


KIX32.EXE RemoveRelation.kix

Code:
Dim $Msg, $Pause
If Exist('C:\Program Files\Pivotal\Relation\relation.exe')
  $Msg = MessageBox('Please wait while Relationship is uninstalled','ESI International',4160,10)
  ;I'm guessing this line is correct as I don't know and I don't have the program to test
  Shell 'C:\WINDOWS\uninst.exe -y -f"C:\Program Files\Pivotal\Relation\DeIsL1.isu" '
  'Error: ' + @ERROR + ' - ' + @SERROR ?
  'Press any key to continue ' ?
  Get $Pause
  ;This will FORCE all applications closed without saving data within 90 seconds
  $RC = Shutdown("","System is being rebooted to enable new settings.", 90, 1, 1)
  ;No need for a sleep command
Else
  ;You would not want this to show though on every logon
  'The eRelation program was not found on this system ' ?
EndIf


.

Top
Page 2 of 5 <12345>


Moderator:  Jochen, Allen, Radimus, Glenn Barnas, ShaneEP, Ruud van Velsen, Arend_, Mart 
Hop to:
Shout Box

Who's Online
2 registered (morganw, mole) and 414 anonymous users online.
Newest Members
gespanntleuchten, DaveatAdvanced, Paulo_Alves, UsTaaa, xxJJxx
17864 Registered Users

Generated in 0.121 seconds in which 0.073 seconds were spent on a total of 13 queries. Zlib compression enabled.

Search the board with:
superb Board Search
or try with google:
Google
Web kixtart.org