Page 1 of 1 1
Topic Options
#138208 - 2005-04-19 07:35 PM SetConsole troubles
ArminL Offline
Just in Town

Registered: 2005-03-16
Posts: 3
Loc: Germany
Hi everyone,

it seems that SetConsole("alwaysOnTop") and SetConsole("foreground"), once assigned to the console, cannot be reset. I have a program that should run in the background for a while, but display error messages (if there are any ...) in the foreground. So I use

$=SetConsole("AlwaysOnTop")
$=SetConsole("Foreground")
$=SetConsole("Hide")
... my program (invisible phase .....)

and this seems to worke nicely. Messages pop up in front of any application (but do not automatically get the focus, but this is just a minor issue).

Later on the console should be visible, since there are some lengthy processes running and I want the user to see some progress indicators.

$=SetConsole("Show")
... my program (copies a lot of files, and writes a progress indicator ...)

The problem is, that in this phase I want the user to be able to switch to a different application if he doesn't feel like watching the copy progress. But alas, the "alwaysontop" is still active, and the kix console consumes most of the space on screen, which in turn makes some users simply cancel my script.

I haven't found any way yet to reset attributes like "alwaysontop" or "foreground". Anyone who has an idea how this cound be done?

2nd question: solving issue #1 still gives the user an opportunity to cancel my script by closing its console window. Few ever will, if I manage to solve issue #1, because a window in the background won't do any harm. Just for the heck of it ... is there any setting so a user cannot cancel a kix script by closing its console window? (Setting "break on" and logging him out or using wkix is not a good idea ...)

Kix environment: Kix 4.21, Windows XP SP-2

Thanks

Armin Linder

Top
#138209 - 2005-04-19 07:50 PM Re: SetConsole troubles
NTDOC Administrator Offline
Administrator
*****

Registered: 2000-07-28
Posts: 11631
Loc: CA
Quote:

logging him out or using wkix is not a good idea




Well then I have no ideas for you. Though I run a script that can take an hour to run but few users even know when it runs unless they pay attention because it is run hidden all the time under WKIX32

Top
#138210 - 2005-04-19 07:55 PM Re: SetConsole troubles
Les Offline
KiX Master
*****

Registered: 2001-06-11
Posts: 12734
Loc: fortfrances.on.ca
IMHO the entire logon script execution should be invisible to the users.
_________________________
Give a man a fish and he will be back for more. Slap him with a fish and he will go away forever.

Top
#138211 - 2005-04-19 09:51 PM Re: SetConsole troubles
Mart Moderator Offline
KiX Supporter
*****

Registered: 2002-03-27
Posts: 4673
Loc: The Netherlands
Well, we use kixforms for our (logon) script and got the x at the top right corner disabled or even removed (it's one of these two options, not sure can't check right now) so user obviously can’t use it to quite running the script. No need for the console to come up because it's all shown in a kixform.

Maybe this is an option for you?
Will check on our code and post it if it is a valid option in your case.
_________________________
Mart

- Chuck Norris once sold ebay to ebay on ebay.

Top
Page 1 of 1 1


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

Who's Online
0 registered and 460 anonymous users online.
Newest Members
Sir_Barrington, batdk82, StuTheCoder, M_Moore, BeeEm
17886 Registered Users

Generated in 0.051 seconds in which 0.022 seconds were spent on a total of 12 queries. Zlib compression enabled.

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