Page all of 3 123>
Topic Options
#88247 - 2002-09-22 12:55 AM The All-New KiXomatic 2.2 - 'Now with KiX! and WKiX!'
Chris S. Offline
MM club member
*****

Registered: 2002-03-18
Posts: 2368
Loc: Earth
Here it is, the all-new KiXomatic 2.2. Now with KiX! and WKiX!!!

Using KiX (or WKIX) and KiXforms, you too can program the WIN32 Class of Windows Management Instrumentation to impress your boss or pick up members of the opposite sex!

Now uses dynamic progress bars, enhanced save and open dialogs, and best of all it will automatically detect if an output is an array and inserts the proper coding to handle the pesky array.

Order your copy today!

Or... just copy and paste the code below into your favorite editor. (Line breaks optional.)

 Code:
Break On
 
If @SCRIPTEXE<>"wkix32.exe"
 $nul=SetConsole("Hide")
EndIf
 
If Not "\\"=Left(@SCRIPTDIR,2)
 Go Left(@SCRIPTDIR,2)
 CD @SCRIPTDIR
EndIf
 
$Form = CreateObject("Kixtart.Form")
$Form.Caption = "KiXomatic 2.2"
$Form.ScaleHeight = 520
$Form.ScaleWidth = 650
$Form.Center
 
$PForm = CreateObject("Kixtart.Form")
$PForm.Caption = "Loading WMI Classes..."
$PForm.Width = 250
$PForm.Height = 60
$PForm.BorderStyle = 3
$PForm.Center
$PForm.controlbox = 0
 
$PBar = $PForm.ProgressBar
$PBar.Size = 230,15
$PBar.Style = "1"
$PBar.Center
 
$Frame = $Form.PictureBox(,,,$Form.ScaleWidth,$Form.ScaleHeight)
$Frame.BorderStyle = 2
 
$lstClass = $Frame.ComboBox(,20,15,450)
$lstClass.Additem ("Begin by selecting a class")
$lstClass.Sorted = 1
$lstClass.Value = "Begin by selecting a class"
$lstClass.OnClick = "ChooseClass()"
$nul = EnumClasses()
 
$cmdRun  = $Frame.CommandButton("Run", 475,15,35,20)
$cmdSave = $Frame.CommandButton("Save",515,15,35,20)
$cmdOpen = $Frame.CommandButton("Open",555,15,35,20)
$cmdQuit = $Frame.CommandButton("Quit",595,15,35,20)
$cmdRun.Onclick  = "RunScript()"
$cmdSave.Onclick = "SaveScript()"
$cmdOpen.Onclick = "OpenScript()"
$cmdQuit.Onclick = "$$Form.Hide"
$cmdRun.Tooltip  = "Run the script"
$cmdSave.Tooltip = "Save the script"
$cmdOpen.Tooltip = "Open a saved script"
$cmdQuit.Tooltip = "Quit KiXomatic"
$cmdRun.Enabled  = 0
$cmdSave.Enabled = 0
 
$TextBox = $Frame.TextBox(,20,37,610,460)
$TextBox.AcceptsReturn = True
$TextBox.MultiLine = True
$TextBox.Fontname = "Courier New"
$TextBox.Fontsize = "8"
$TextBox.Scrollbars = 2
If $Form.Build<34 $TextBox.MousePointer = 3 EndIf
$TextBox.Hide
 
$Form.Show
 
While $Form.Visible
	$nul=Execute($Form.DoEvents)
Loop
 
QuitScript()
Exit 1
 
Function EnumClasses()
   Dim $Max
   $PForm.Show
   $objWMIService = GetObject("winmgmts:\\.\root\cimv2")
   $PBar.Max = $objWMIService.SubclassesOf().Count
   For Each $objclass in $objWMIService.SubclassesOf()
      $PBar.Value = $PBar.Value + 1
      $IsQ = 0
      If instr($objClass.Path_.Class,"WIN32_")
         For Each $Qualifier in $objClass.Qualifiers_
            If Instr($Qualifier.Name, "ASSOCIATION") $IsQ = 1 Endif
         Next
         If $IsQ = 0 $lstClass.Additem($objClass.Path_.Class) Endif
      Endif
   Next
   $PForm.Hide
   $objWMIService = 0
EndFunction
 
Function ChooseClass()
   Dim $Max
   If $lstClass.Value <> "Begin by selecting a class"
      $Class = $lstClass.Value
      $Form.MousePointer = 11
      $PForm.Caption = "Customizing Script..."
      $PBar.Value = 0
      $PForm.Center
      $PForm.Show
      $Textbox.Show
      $TextBox.Text = ""
      $cmdRun.Enabled  = 0
      $cmdSave.Enabled = 0
      $objWMIService = GetObject("winmgmts:{impersonationLevel=impersonate}!\\.\root\cimv2")
      $objClass = $objWMIService.Get($Class)
      $PBar.Max = $objClass.properties_.Count
      $Script = 'Break On' + @CRLF
      $Script = $Script + '$$strComputer = "."' + @CRLF
      $Script = $Script + '$$objWMIService = GetObject("winmgmts:\\" + $$strComputer + "\root\cimv2")' + @CRLF
      $Script = $Script + '$$colItems = $$objWMIService.ExecQuery("Select * from $Class",,48)' + @CRLF
      $Script = $Script + 'For each $$objItem in $$colItems' + @CRLF
      For Each $objProperty in $objClass.properties_
         $PBar.Value = $PBar.Value + 1
         $Prop = $objProperty.name
         If $objProperty.IsArray
            $Script = $Script + '  For each $$Item in $objItem.' + $Prop + @CRLF
            $Script = $Script + '    "*' + $Prop + ': " + $$Item ?' + @CRLF
            $Script = $Script + '  Next' + @CRLF
         Else
            $Script = $Script + '  "' + $Prop + ': " + $$objItem.' + $Prop + ' ?' + @CRLF
         Endif
      Next
      $Script = $Script + '  ?' + @CRLF
      $Script = $Script + 'Next'
      $script = $script + @CRLF + "? 'Press Any Key to Close the Window'" + @CRLF + "Get $"
      $TextBox.Text = $Script
      $cmdRun.Enabled  = 1
      $cmdSave.Enabled = 1
      $cmdRun.SetFocus
   Else
      $TextBox.Text = ""
      $cmdRun.Enabled  = 0
      $cmdSave.Enabled = 0
   Endif
   $PForm.Hide
   $Form.MousePointer = 0
   $objWMIService = 0
EndFunction
 
Function RunScript()
   $objFSO = CreateObject("Scripting.FileSystemObject")
   $strTmpName = "temp_script.kix"
   $objScript = $objFSO.CreateTextFile($strTmpName)
   $objScript.Write ($TextBox.Text)
   $objScript.Close
   $objShell = CreateObject("WScript.Shell")
   If "@SCRIPTEXE"<>"wkix32.exe"
      $strCmdLine = "kix32.exe"
   Else
      $strCmdLine = "wkix32.exe"
   EndIf
   If @SCRIPTDIR<>@CURDIR and Exist(@SCRIPTDIR + "\" + @SCRIPTEXE)
      $strCmdLine = '"' + @SCRIPTDIR + $strCmdLine + '" "' + $strTmpName + '"'
   Else
      $strCmdLine = '"' + $strCmdLine + ' "' + $strTmpName + '"'
   EndIf
   $nul = $objShell.Run($strCmdLine)
EndFunction
 
Function SaveScript()
   $objFSO = CreateObject("Scripting.FileSystemObject")
   $strTmpName = "temp_script.kix"
   $objScript = $objFSO.CreateTextFile($strTmpName)
   $objScript.Write ($TextBox.Text)
   $objScript.Close
   $dlgSave = $Form.FileSaveDialog("Save File",@SCRIPTDIR,$Class+".kix","KiX Files|*.kix|All Files|*.*|",2)
   Copy $strTmpName $dlgSave
EndFunction
 
Function OpenScript()
   $dlgOpen = $Form.FileOpenDialog("Open File",@SCRIPTDIR,,"KiX Files|*.kix|All Files|*.*|",4)
   $objFSO = CreateObject("Scripting.FileSystemObject")
   $objFile = $objFSO.OpenTextFile($dlgOpen)
   $Script = $objFile.ReadAll()
   $TextBox.Text =  $Script
   $objFile.Close
   $Textbox.Show
   $cmdRun.Enabled  = 1
   $cmdSave.Enabled = 1
EndFunction
 
Function QuitScript()
   $objFSO = CreateObject("Scripting.FileSystemObject")
   $objFSO.DeleteFile ("temp_script.kix")
   $objFSO = 0
   $nul=Setconsole("Show")
   Quit()
EndFunction


Edited By Chris S. (08/24/05 06:03 AM)

Edited by Lonkero (12/21/07 02:08 PM)
Edit Reason: re-enforced copy&paste codeblock

Top
#88248 - 2002-09-22 05:23 PM Re: The All-New KiXomatic 2.1 - 'Now with KiX!'
Chris S. Offline
MM club member
*****

Registered: 2002-03-18
Posts: 2368
Loc: Earth
Tweaked WMIQuery to exit after loading the first set of values. Speeds up 'customizing' the script, especially with dealing with classes with many values.
Top
#88249 - 2002-09-24 02:33 PM Re: The All-New KiXomatic 2.1 - 'Now with KiX!'
Will Hetrick Offline
Hey THIS is FUN

Registered: 2001-10-02
Posts: 320
Loc: Harrisburg, PA USA
What a neat script Chris. I will enjoy playing with this one!
_________________________
You have at least 2 choices. Each choice changes your destiny. Choose wisely!

Top
#88250 - 2002-09-24 02:38 PM Re: The All-New KiXomatic 2.1 - 'Now with KiX!'
Chris S. Offline
MM club member
*****

Registered: 2002-03-18
Posts: 2368
Loc: Earth
Thanks. I think it makes a good companion to Rad's WMIQuery() in that you can run a quick script against a class and see if there is any relevant information you want to capture.
Top
#88251 - 2002-09-24 05:41 PM Re: The All-New KiXomatic 2.1 - 'Now with KiX!'
Waltz Offline
Seasoned Scripter

Registered: 2002-08-01
Posts: 485
Loc: Waterloo, Ontario, Canada
[Big Grin]
...Verrry nice...
Thanks...
_________________________
We all live in a Yellow Subroutine...

Top
#88252 - 2002-09-24 06:55 PM Re: The All-New KiXomatic 2.1 - 'Now with KiX!'
NTDOC Administrator Offline
Administrator
*****

Registered: 2000-07-28
Posts: 11574
Loc: CA
Chris,

Just wanted to say thanks for taking the time to review and code this. Very nice tool to at least get you started. Good job.

Thanks again... and to you as well Shawn for the KiXForms great job there as well. [Big Grin]

Top
#88253 - 2002-10-03 10:26 PM Re: The All-New KiXomatic 2.1 - 'Now with KiX!'
kholm Offline
Korg Regular
*****

Registered: 2000-06-19
Posts: 714
Loc: Randers, Denmark
Very nice

If not for anyting else, i would like to 'ping' this post to the top of the list.

I didn't check this post prior to yesterday, because the title KiXomatic told me nothing about the usefullnes.

After checking, i must say: This is one of the best inventions since the wheel [Wink]

I would suggest this script as a howto on COM and WMI in the FAQ-forum

Cris,
Can i subscribe on updates [Smile]

Top
#88254 - 2002-10-03 10:35 PM Re: The All-New KiXomatic 2.1 - 'Now with KiX!'
Chris S. Offline
MM club member
*****

Registered: 2002-03-18
Posts: 2368
Loc: Earth
Thank you. Of course, the enum function and the look and feel was 'borrowed' from the 'Script Guys' Scriptomatic script. The 'array detect' is new, however.

I'll post updates here. [Big Grin]

Top
#88255 - 2002-10-03 10:39 PM Re: The All-New KiXomatic 2.1 - 'Now with KiX!'
Schuliebug Offline
Hey THIS is FUN
*****

Registered: 2002-01-18
Posts: 379
Loc: Netherlands
Very nice, very usable code !!!!
_________________________
Kind regards,

Top
#88256 - 2002-10-11 12:46 AM Re: The All-New KiXomatic 2.1 - 'Now with KiX!'
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22342
Loc: OK
went to msdn, searched... no go
went to technet, searched... only for xp and .net server

checked from typelibs, not working...

tried with kixomatic, success.

chris, I must admit you have earned your stars.
 
_________________________
!

download KiXnet

Top
#88257 - 2002-10-10 02:15 PM Re: The All-New KiXomatic 2.1 - 'Now with KiX!'
Kdyer Offline
KiX Supporter
*****

Registered: 2001-01-03
Posts: 6241
Loc: Tigard, OR
Chris,

Very cool! This version works great, where previous versions were problematic.

Good work.

Thanks!

Kent
_________________________
Utilize these resources:
UDFs (Full List)
KiXtart FAQ & How to's

Top
#88258 - 2002-10-10 04:19 PM Re: The All-New KiXomatic 2.1 - 'Now with KiX!'
Chris S. Offline
MM club member
*****

Registered: 2002-03-18
Posts: 2368
Loc: Earth
Version 2.1 incorporates some minor bug-fixes relating to the forms and also a RFC or two.

  • MousePointer default for script textbox. Bugfix in KiXforms eliminated need to set a default value.
  • Added flags to Open and Save dialog boxes. Added a pipe to workaround bug in KiXforms 2.1.
  • Tweaked the QuitScript() routine to exit more gracefully and to catch those who use the [x]
  • Tweaked SaveScript() to save the temp_script before opening the dialog.

Top
#88259 - 2002-10-10 04:26 PM Re: The All-New KiXomatic 2.1 - 'Now with KiX!'
Chris S. Offline
MM club member
*****

Registered: 2002-03-18
Posts: 2368
Loc: Earth
Oh, yeah, and lines that output arrays has an '*' in front of it so you can spot them easier.
Top
#88260 - 2003-07-12 01:46 AM Re: The All-New KiXomatic 2.1 - 'Now with KiX!'
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22342
Loc: OK
I copy&pasted this to my favorite editor (notepad) and it screwed everything up :'(
_________________________
!

download KiXnet

Top
#88261 - 2003-07-14 09:40 AM Re: The All-New KiXomatic 2.1 - 'Now with KiX!'
Jochen Administrator Offline
KiX Supporter
*****

Registered: 2000-03-17
Posts: 6374
Loc: Stuttgart, Germany
Did you try using Wordpad first ? [Razz]
_________________________



Top
#88262 - 2003-07-14 10:23 AM Re: The All-New KiXomatic 2.1 - 'Now with KiX!'
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22342
Loc: OK
it does not say anything about wordpad-transformation [Mad]
_________________________
!

download KiXnet

Top
#88263 - 2003-07-14 10:39 AM Re: The All-New KiXomatic 2.1 - 'Now with KiX!'
Jochen Administrator Offline
KiX Supporter
*****

Registered: 2000-03-17
Posts: 6374
Loc: Stuttgart, Germany
RTFFAQ : HOWTO: Submit code to / copy code from the board

[Razz] [Razz] [Razz] [Big Grin]

Gotcha !
_________________________



Top
#88264 - 2003-07-14 10:51 AM Re: The All-New KiXomatic 2.1 - 'Now with KiX!'
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22342
Loc: OK
sorry, you are the lame one. [Wink]
quote:
just cut and paste the code below into your favorite editor.

first of all, he said I can "cut and paste"
it does not work.
when I say that, I really mean it. [Roll Eyes]
like, I use such code-format that you can use your favorit editor without any buts.

secondly, I say "you can copy&paste" as who can cut from webpage? [Big Grin]
_________________________
!

download KiXnet

Top
#88265 - 2003-07-15 12:07 AM Re: The All-New KiXomatic 2.1 - 'Now with KiX!'
Jochen Administrator Offline
KiX Supporter
*****

Registered: 2000-03-17
Posts: 6374
Loc: Stuttgart, Germany
Am not responsible for sayings of contributors ... never was, never will be

Ey Chris, ever thought of using PP making such strong statements valid? Knowwhatimean, nudge nudge ...

[Razz]
_________________________



Top
#88266 - 2003-07-14 06:05 PM Re: The All-New KiXomatic 2.1 - 'Now with KiX!'
NTDOC Administrator Offline
Administrator
*****

Registered: 2000-07-28
Posts: 11574
Loc: CA
You mean kind of like this?


Break On
$nul=Setconsole("Hide")

$Form = CreateObject("Kixtart.Form")
$Form.Caption = "KiXomatic"
$Form.ScaleHeight = 520
$Form.ScaleWidth = 650
$Form.Center

$PForm = CreateObject("Kixtart.Form")
$PForm.Caption = "Loading WMI Classes..."
$PForm.Width = 250
$PForm.Height = 60
$PForm.BorderStyle = 3
$PForm.Center

$PBar = $PForm.ProgressBar
$PBar.Size = 230,15
$PBar.Style = "1"
$PBar.Center

$Frame = $Form.PictureBox(,,,$Form.ScaleWidth,$Form.ScaleHeight)
$Frame.BorderStyle = 2

$lstClass = $Frame.ComboBox(,20,15,450)
$lstClass.Additem ("Begin by selecting a class")
$lstClass.Sorted = 1
$lstClass.Value = "Begin by selecting a class"
$lstClass.OnClick = "ChooseClass()"
$nul = EnumClasses()

$cmdRun = $Frame.CommandButton("Run", 475,15,35,20)
$cmdSave = $Frame.CommandButton("Save",515,15,35,20)
$cmdOpen = $Frame.CommandButton("Open",555,15,35,20)
$cmdQuit = $Frame.CommandButton("Quit",595,15,35,20)
$cmdRun.Onclick = "RunScript()"
$cmdSave.Onclick = "SaveScript()"
$cmdOpen.Onclick = "OpenScript()"
$cmdQuit.Onclick = "$$Form.Hide"
$cmdRun.Tooltip = "Run the script"
$cmdSave.Tooltip = "Save the script"
$cmdOpen.Tooltip = "Open a saved script"
$cmdQuit.Tooltip = "Quit KiXomatic"
$cmdRun.Enabled = 0
$cmdSave.Enabled = 0

$TextBox = $Frame.TextBox(,20,37,610,460)
$TextBox.AcceptsReturn = True
$TextBox.MultiLine = True
$TextBox.Fontname = "Courier New"
$TextBox.Fontsize = "8"
$TextBox.Scrollbars = 2
If $Form.Build<34 $TextBox.MousePointer = 3 EndIf
$TextBox.Hide

$Form.Show

While $Form.Visible
$nul=Execute($Form.DoEvents)
Loop

QuitScript()
Exit 1

Function EnumClasses()
Dim $Max
$PForm.Show
$objWMIService = GetObject("winmgmts:\\.\root\cimv2")
For Each $objClass in $objWMIService.SubclassesOf() $Max = $Max + 1 Next
$PBar.Max = $Max
For Each $objclass in $objWMIService.SubclassesOf()
$PBar.Value = $PBar.Value + 1
$IsQ = 0
If instr($objClass.Path_.Class,"WIN32_")
For Each $Qualifier in $objClass.Qualifiers_
If Instr($Qualifier.Name, "ASSOCIATION")
$IsQ = 1
Endif
Next
If $IsQ = 0
$lstClass.Additem ($objClass.Path_.Class)
Endif
Endif
Next
$PForm.Hide
$objWMIService = 0
EndFunction

Function ChooseClass()
Dim $Max
If $lstClass.Value <> "Begin by selecting a class"
$Class = $lstClass.Value
$Form.MousePointer = 11
$PForm.Caption = "Customizing Script..."
$PBar.Value = 0
$PForm.Center
$PForm.Show
$Textbox.Show
$TextBox.Text = ""
$cmdRun.Enabled = 0
$cmdSave.Enabled = 0
$objWMIService = GetObject("winmgmts:{impersonationLevel=impersonate}!\\.\root\cimv2")
$objClass = $objWMIService.Get($Class)
For Each $objProperty in $objClass.properties_ $Max = $Max + 1 Next
$PBar.Max = $Max
$Script = 'Break On' + @CRLF
$Script = $Script + '$$strComputer = "."' + @CRLF
$Script = $Script + '$$objWMIService = GetObject("winmgmts:\\" + $$strComputer + "\root\cimv2")' + @CRLF
$Script = $Script + '$$colItems = $$objWMIService.ExecQuery("Select * from $Class",,48)' + @CRLF
$Script = $Script + 'For each $$objItem in $$colItems' + @CRLF
For Each $objProperty in $objClass.properties_
$PBar.Value = $PBar.Value + 1
$Prop = $objProperty.name
If instr(WMIQuery($Prop,$Class),"$$value")
$Script = $Script + ' For each $$Item in $objItem.' + $Prop + @CRLF
$Script = $Script + ' "*' + $Prop + ': " + $$Item ?' + @CRLF
$Script = $Script + ' Next' + @CRLF
Else
$Script = $Script + ' "' + $Prop + ': " + $$objItem.' + $Prop + ' ?' + @CRLF
Endif
Next
$Script = $Script + ' ?' + @CRLF
$Script = $Script + 'Next'
$TextBox.Text = "$Script"
$cmdRun.Enabled = 1
$cmdSave.Enabled = 1
$cmdRun.SetFocus
Else
$TextBox.Text = ""
$cmdRun.Enabled = 0
$cmdSave.Enabled = 0
Endif
$PForm.Hide
$Form.MousePointer = 0
$objWMIService = 0
EndFunction

Function RunScript()
$objFSO = CreateObject("Scripting.FileSystemObject")
$strTmpName = "temp_script.kix"
$objScript = $objFSO.CreateTextFile($strTmpName)
$objScript.Write ($TextBox.Text)
$objScript.Close
$objShell = CreateObject("WScript.Shell")
$strCmdLine = "%COMSPEC% /k kix32.exe "
$strCmdLine = $strCmdLine + $strTmpName
$nul = $objShell.Run($strCmdLine)
EndFunction

Function SaveScript()
$objFSO = CreateObject("Scripting.FileSystemObject")
$strTmpName = "temp_script.kix"
$objScript = $objFSO.CreateTextFile($strTmpName)
$objScript.Write ($TextBox.Text)
$objScript.Close
$dlgSave = $Form.FileSaveDialog("Save File",@SCRIPTDIR,$Class+".kix","KiX Files|*.kix|All Files|*.*|",2)
Copy $strTmpName $dlgSave
EndFunction

Function OpenScript()
$dlgOpen = $Form.FileOpenDialog("Open File",@SCRIPTDIR,,"KiX Files|*.kix|All Files|*.*|",4)
$objFSO = CreateObject("Scripting.FileSystemObject")
$objFile = $objFSO.OpenTextFile($dlgOpen)
$Script = $objFile.ReadAll()
$TextBox.Text = $Script
$objFile.Close
$Textbox.Show
$cmdRun.Enabled = 1
$cmdSave.Enabled = 1
EndFunction

Function QuitScript()
$objFSO = CreateObject("Scripting.FileSystemObject")
$objFSO.DeleteFile ("temp_script.kix")
$objFSO = 0
$nul=Setconsole("Show")
Quit()
EndFunction

Function WMIQuery($what,$from,optional $computer,optional $where, optional $x)
dim $strQuery, $objEnumerator, $value
if not $computer $computer="@WKSTA" endif
$strQuery = "Select $what From $from"
if $where and $x $strQuery = $strQuery + " Where $where = '$x'" endif
$SystemSet = GetObject("winmgmts:{impersonationLevel=impersonate}!//$computer")
$objEnumerator = $SystemSet.ExecQuery($strQuery)
For Each $objInstance in $objEnumerator
If @Error = 0 and $objInstance <> ""
$=execute("$$value = $$objInstance.$what")
$WMIQuery="$value"+"|"+"$WMIQuery"
EndIf
exit @error
Next
;$WMIQuery=left($WMIQuery,len($WMIQuery)-1)
exit @error
EndFunction


Top
#88267 - 2003-07-14 06:12 PM Re: The All-New KiXomatic 2.1 - 'Now with KiX!'
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22342
Loc: OK
doc, it looks nice.
even though, the shit color might not be the best one...
but that indeed is COPY&pasteable.
_________________________
!

download KiXnet

Top
#88268 - 2003-07-14 06:14 PM Re: The All-New KiXomatic 2.1 - 'Now with KiX!'
Les Offline
KiX Master
*****

Registered: 2001-06-11
Posts: 12734
Loc: fortfrances.on.ca
...but I still cannot Cut & Paste. [Frown]
_________________________
Give a man a fish and he will be back for more. Slap him with a fish and he will go away forever.

Top
#88269 - 2003-07-14 06:29 PM Re: The All-New KiXomatic 2.1 - 'Now with KiX!'
NTDOC Administrator Offline
Administrator
*****

Registered: 2000-07-28
Posts: 11574
Loc: CA
Yeah... 2 problems I don't think anyone is going to solve in their code.

CUT and Acceptable colors for eveyone. [Big Grin]

Top
#88270 - 2003-07-14 06:34 PM Re: The All-New KiXomatic 2.1 - 'Now with KiX!'
Chris S. Offline
MM club member
*****

Registered: 2002-03-18
Posts: 2368
Loc: Earth
The lengths you guys will go to to increase your post-count. [Wink]

Is this description better?

BTW, I plan on updating this script when the latest KF dll goes gold. Sometime in the next decade, I imagine.

Top
#88271 - 2003-07-14 06:37 PM Re: The All-New KiXomatic 2.1 - 'Now with KiX!'
NTDOC Administrator Offline
Administrator
*****

Registered: 2000-07-28
Posts: 11574
Loc: CA
LOL [Big Grin]
Top
#88272 - 2003-07-14 06:40 PM Re: The All-New KiXomatic 2.1 - 'Now with KiX!'
Les Offline
KiX Master
*****

Registered: 2001-06-11
Posts: 12734
Loc: fortfrances.on.ca
Thanks Chris.
Guys, I guess we've been found out. Now for MCA to try and figure out how to discount these posts from his stats> [Big Grin]
_________________________
Give a man a fish and he will be back for more. Slap him with a fish and he will go away forever.

Top
#88273 - 2003-07-14 07:06 PM Re: The All-New KiXomatic 2.1 - 'Now with KiX!'
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22342
Loc: OK
chris, I still wonder what is that ",,48" in those getobjects...
I've found almost all I've tried working without it.
is it some sorta trojan?
_________________________
!

download KiXnet

Top
#88274 - 2003-07-14 07:11 PM Re: The All-New KiXomatic 2.1 - 'Now with KiX!'
Chris S. Offline
MM club member
*****

Registered: 2002-03-18
Posts: 2368
Loc: Earth
More like a sig than a trojan. [Wink]

But...it does serve some purpose: http://www.kixtart.org/board/ultimatebb.php?ubb=get_topic;f=1;t=005971#000010

Top
#88275 - 2003-07-14 07:13 PM Re: The All-New KiXomatic 2.1 - 'Now with KiX!'
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22342
Loc: OK
thank you, oh WMI-GURU!

not sure I still need them anywhere but good to know that they don't most likely harm either.
_________________________
!

download KiXnet

Top
#88276 - 2003-07-14 07:16 PM Re: The All-New KiXomatic 2.1 - 'Now with KiX!'
Sealeopard Offline
KiX Master
*****

Registered: 2001-04-25
Posts: 11162
Loc: Boston, MA, USA
However, the 48 (semi-synchronous mode) cannot be used in conjunction with a .COUNT. Thus
code:
$a=$objWMIService.ExecQuery("Select * from $Class",,48)
? 'elements = '+$a.count
for each $b in $a
next

will not work AFAIK.
_________________________
There are two types of vessels, submarines and targets.

Top
#88277 - 2005-04-26 10:26 PM Re: The All-New KiXomatic 2.1 - 'Now with KiX!'
masken Offline
MM club member
*****

Registered: 2000-11-27
Posts: 1222
Loc: Gothenburg, Sweden
Just wanted to say REALLY nice work Chris S!

...and I'm not gonna be a bitch-o-matic about anything which seems more popular than staying on-topic for some these days
_________________________
The tart is out there

Top
#88278 - 2005-04-27 08:06 PM Re: The All-New KiXomatic 2.1 - 'Now with KiX!'
Chris S. Offline
MM club member
*****

Registered: 2002-03-18
Posts: 2368
Loc: Earth
Hey, thanks!
Top
#88279 - 2005-06-08 01:33 AM Re: The All-New KiXomatic 2.1 - 'Now with KiX!'
Jose Offline
Seasoned Scripter
*****

Registered: 2001-04-04
Posts: 693
Loc: Buenos Aires - Argentina
Hey Chris!! congrats man!
You know what I was thinking while using it, It would be cool if you reduce the size of the combo and instead place a small textbox in order to type any word to match the array populated into the big combo after an 'enter' FE. In that case you can type the word 'Video' FE and just populate only the ones that match some part of any array item.
Just a feedback thought Chris...thanks.
_________________________
Life is fine.

Top
#88280 - 2005-08-24 05:05 AM Re: The All-New KiXomatic 2.2 - 'Now with KiX! and WKiX!'
Chris S. Offline
MM club member
*****

Registered: 2002-03-18
Posts: 2368
Loc: Earth
I have updated KiXomatic with Lonk's code to handle WKiX, plus I have optimized the script generation code to handle arrays better. No more long hangups while generating a script!
Top
#88281 - 2005-08-24 05:31 AM Re: The All-New KiXomatic 2.2 - 'Now with KiX! and WKiX!'
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22342
Loc: OK
lol, you had to do something meaningfull for your 2000th post.

and I'm glad my modifications made to the mainstream kixomatic version.
_________________________
!

download KiXnet

Top
#88282 - 2005-08-24 08:42 AM Re: The All-New KiXomatic 2.2 - 'Now with KiX! and WKiX!'
NTDOC Administrator Offline
Administrator
*****

Registered: 2000-07-28
Posts: 11574
Loc: CA
Works great. Thanks again Chris
Top
#88283 - 2006-02-09 09:32 AM Re: The All-New KiXomatic 2.2 - 'Now with KiX! and WKiX!'
Arend_ Moderator Offline
MM club member
*****

Registered: 2005-01-17
Posts: 1869
Loc: Hilversum, The Netherlands
How about KixOMatic showing methods too ?
Top
#88284 - 2006-02-09 09:35 AM Re: The All-New KiXomatic 2.2 - 'Now with KiX! and WKiX!'
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22342
Loc: OK
idea is nice but how to really do that as an example code is rather not that easy.
maybe as comments...
_________________________
!

download KiXnet

Top
#88285 - 2006-02-09 09:51 AM Re: The All-New KiXomatic 2.2 - 'Now with KiX! and WKiX!'
Arend_ Moderator Offline
MM club member
*****

Registered: 2005-01-17
Posts: 1869
Loc: Hilversum, The Netherlands
Something like this perhaps ?
Code:

$strComputer = "."
$objWMIService = GetObject("winmgmts:{impersonationLevel=impersonate}!\\" + $strComputer + "\root\cimv2")
$objClass = $objWMIService.Get("Win32_PnPEntity")
? "Listing Class Methods:"
For Each $objItem In $objClass.methods_
? $objItem.Name
Next


Top
#88286 - 2006-02-09 09:56 AM Re: The All-New KiXomatic 2.2 - 'Now with KiX! and WKiX!'
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22342
Loc: OK
well, that's not how the properties work either.

but, as many of us know, there is just so little methods in WMI.
as example, in pnpEntity, I think there was just 2 methods, and both are unusable!
_________________________
!

download KiXnet

Top
#88287 - 2006-02-09 10:01 AM Re: The All-New KiXomatic 2.2 - 'Now with KiX! and WKiX!'
Arend_ Moderator Offline
MM club member
*****

Registered: 2005-01-17
Posts: 1869
Loc: Hilversum, The Netherlands
Thats true, although the "terminate" method in WIN32_Process is a handy one. I just mentioned it for the completeness of KiXoMatic. WIN32_PnPEntity should have an "Uninstall" method
Top
#195188 - 2009-07-31 06:39 PM Re: The All-New KiXomatic 2.2 - 'Now with KiX! and WKiX!' [Re: Chris S.]
itdaddy Offline
Starting to like KiXtart

Registered: 2006-12-19
Posts: 145
Loc: Wisconsin
chris
i get an error line 27 when I run the kixomatic?
It shows it wants to run but stops and give me and error at line 27.
I have kixforms installed right and then use wkix32 to run the kixomatic2.kix file right?
thanks
_________________________
Robert
A+, CCNA, MCP
Network Admin
Credit Union Wisconsin

Top
#195189 - 2009-07-31 06:45 PM Re: The All-New KiXomatic 2.2 - 'Now with KiX! and WKiX!' [Re: itdaddy]
itdaddy Offline
Starting to like KiXtart

Registered: 2006-12-19
Posts: 145
Loc: Wisconsin
chris i solved it
i needed the kix classic msi file installed for it to work
thanks i got it looks freaking awesome great job man
wow!
robert
_________________________
Robert
A+, CCNA, MCP
Network Admin
Credit Union Wisconsin

Top
#195190 - 2009-07-31 06:49 PM Where do I get temp_script.kixF? [Re: itdaddy]
itdaddy Offline
Starting to like KiXtart

Registered: 2006-12-19
Posts: 145
Loc: Wisconsin
when i run the kixomatic 2 i get this error need file
temp_script.kixF! where do I get his kix file?

thanks
_________________________
Robert
A+, CCNA, MCP
Network Admin
Credit Union Wisconsin

Top
#195196 - 2009-07-31 08:42 PM Re: The All-New KiXomatic 2.1 - 'Now with KiX!' [Re: NTDOC]
itdaddy Offline
Starting to like KiXtart

Registered: 2006-12-19
Posts: 145
Loc: Wisconsin
CHris and NTDOC

you guys are freaking geniuses I love kixomatic got it working chris
thanks
wow is this fantastic! wowowowowo!
-Robert
_________________________
Robert
A+, CCNA, MCP
Network Admin
Credit Union Wisconsin

Top
Page all of 3 123>


Moderator:  Shawn, ShaneEP, Arend_, Jochen, Radimus, Glenn Barnas, Allen, Mart 
Hop to:
Shout Box

Who's Online
1 registered (Allen) and 49 anonymous users online.
Newest Members
ROBECCO80, TsuyoiSaigai, a5tr0, FoolZero, DaveE
17657 Registered Users

Generated in 0.066 seconds in which 0.013 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