Page 2 of 2 <12
Topic Options
#43475 - 2003-07-28 10:12 PM Re: Delele Program Group
Howard Bullock Offline
KiX Supporter
*****

Registered: 2000-09-15
Posts: 5809
Loc: Harrisburg, PA USA
And you have

ReadValue($hklms+"\Microsoft\Windows NT\CurrentVersion\Winlogon", "RunLogonScriptSync") set to 1 on your computers?

Please check and let us know.

The return code of 1 seems to be a bug in either docs or the function. We will need some clarification from Ruud on that.
_________________________
Home page: http://www.kixhelp.com/hb/

Top
#43476 - 2003-07-28 10:14 PM Re: Delele Program Group
Sealeopard Offline
KiX Master
*****

Registered: 2001-04-25
Posts: 11164
Loc: Boston, MA, USA
The delete during login will not work if RunLoginScriptSync=0, thus it would not be an error as the user profile is not loaded by the time the deleet is issued.

Thus, please answer the question!
_________________________
There are two types of vessels, submarines and targets.

Top
#43477 - 2003-07-28 10:16 PM Re: Delele Program Group
jhansenjr Offline
Fresh Scripter

Registered: 2002-08-31
Posts: 37
Loc: New Jersey
Yes, I have that value set to 1 already.
Top
#43478 - 2003-07-28 10:19 PM Re: Delele Program Group
Howard Bullock Offline
KiX Supporter
*****

Registered: 2000-09-15
Posts: 5809
Loc: Harrisburg, PA USA
Jens, based in the test code I furnished and the posted results, I think that the DelProgramGroup function is returning 0=fail 1=success. DOCs are wrong in this case.

I agree with you that the RunLoginScriptSync setting could be skewing the problem by changing the ability to delete the group. In this case the function is reporting 0=Fail and pring the text of the supposed action.

[ 28. July 2003, 22:20: Message edited by: Howard Bullock ]
_________________________
Home page: http://www.kixhelp.com/hb/

Top
#43479 - 2003-07-29 03:12 PM Re: Delele Program Group
Howard Bullock Offline
KiX Supporter
*****

Registered: 2000-09-15
Posts: 5809
Loc: Harrisburg, PA USA
So to get both the return code and error code could you run this code and report the report?

Run it both at the command line and as part of a logon script. Use KiXtart 4.21 if possible.


? "KiXtart version: " + @kix
? "OS: " + @DOS
? "Product: " + @ProductType
? "LogonMode: @LogonMode"
?
$rc = DelProgramGroup("Sentry Spelling Checker Engine", 0) = 0
If $rc = 0
? "Spell Checker Program Group Deleted...."
? "DelProgramGroup Result: " + $rc
? "Errorcode: @error @serror"
Else
? "DelProgramGroup Result: " + $rc
? "Errorcode: @error @serror"
EndIf


[ 29. July 2003, 15:13: Message edited by: Howard Bullock ]
_________________________
Home page: http://www.kixhelp.com/hb/

Top
#43480 - 2003-07-29 04:30 PM Re: Delele Program Group
jhansenjr Offline
Fresh Scripter

Registered: 2002-08-31
Posts: 37
Loc: New Jersey
Command Prompt: Deletes Group
KiXtart version: 4.21
OS: 5.0
Product: Windows 2000 Professional
LogonMode:

DelProgramGroup Result: 1
Errorcode: 0 The operation completed successfully.

Logon Scrip: Does not Delete Group
KiXtart version: 4.21
OS: 5.0
Product: Windows 2000 Professional
LogonMode:

Spell Checker Program Group Deleted....
DelProgramGroup Result: 0
Errorcode: 2

Top
#43481 - 2003-07-29 04:43 PM Re: Delele Program Group
Howard Bullock Offline
KiX Supporter
*****

Registered: 2000-09-15
Posts: 5809
Loc: Harrisburg, PA USA
These results confirm that the documentation is incorrect.

DelProgramGroup return 1=success or 0=fails and sets @error.

The function fails in the logon script becuase it encounters error 2 "The system cannot find the file specified."

Apparently the path to the file is not known at the time of execution during the logon script. You could possibly try to provide the full path using variable (determined from the registry or Environment).

The inability to find the file in itself does not seem to be a KiXtart error to me. Anybody else have thoughts?
_________________________
Home page: http://www.kixhelp.com/hb/

Top
#43482 - 2003-07-29 04:46 PM Re: Delele Program Group
Howard Bullock Offline
KiX Supporter
*****

Registered: 2000-09-15
Posts: 5809
Loc: Harrisburg, PA USA
I also find it strange that the macro @LogonMode did not return a value. Is this a bug in 4.21?
_________________________
Home page: http://www.kixhelp.com/hb/

Top
#43483 - 2003-07-29 04:49 PM Re: Delele Program Group
Sealeopard Offline
KiX Master
*****

Registered: 2001-04-25
Posts: 11164
Loc: Boston, MA, USA
Check for the existance of the folder via EXIST before doing the DELPOROGRAMGROUP. Maybe the profile is not fully loaded by the time the DELPROGRAMGROUP is issued. However that would contradict the statement that RunLoginScriptSync=1 is implemented for all users.
_________________________
There are two types of vessels, submarines and targets.

Top
#43484 - 2003-07-29 05:03 PM Re: Delele Program Group
Les Offline
KiX Master
*****

Registered: 2001-06-11
Posts: 12734
Loc: fortfrances.on.ca
Jens,
I think you may have the logic reversed on RunLogonScriptSync. If set to 1 then the profile does not load until after the logon script completes. If set to 0, the profile start to load in sync but there is still no guarantee as it still depends on timing.
_________________________
Give a man a fish and he will be back for more. Slap him with a fish and he will go away forever.

Top
#43485 - 2003-07-29 05:08 PM Re: Delele Program Group
Sealeopard Offline
KiX Master
*****

Registered: 2001-04-25
Posts: 11164
Loc: Boston, MA, USA
I was alwasy under the impression that RunLoginScriptSync=1 will result in the following login process events:
a) Load profile if necessary
b) Start login script after profile finished loading
c) Start Run/RunOnce registry keys after logins cript finished
d) Start the shell
_________________________
There are two types of vessels, submarines and targets.

Top
Page 2 of 2 <12


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

Who's Online
1 registered (Allen) and 382 anonymous users online.
Newest Members
gespanntleuchten, DaveatAdvanced, Paulo_Alves, UsTaaa, xxJJxx
17864 Registered Users

Generated in 0.063 seconds in which 0.025 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