KiXforms Forum Index KiXforms
The Forum for the KiXforms Community
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
 Quick Links 
Site News
Downloads
Documentation
Donations
Script Archive
Tracking Systems

Welcome
Goto page 1, 2  Next
 
Post new topic   Reply to topic    KiXforms Forum Index -> KiXforms.NET Discussion
View previous topic :: View next topic  
Author Message
Shawn
KiXforms Developer
KiXforms Developer


Joined: 22 Feb 2003
Posts: 1983
Location: Canada

PostPosted: Mon Jun 27, 2005 4:35 pm    Post subject: Welcome Reply with quote

Hi and welcome,

This will be the new home for Kixforms.Net discussion. Just by way of status, the new version is indeed alive and well and growing by leaps and bounds. An alpha build will be posted soon, along with some scripts that take advantage of the .NET framework.

Stay tuned for more information.

-Shawn
Back to top
View user's profile Send private message
Chris S.
KiXforms Enthusiast
KiXforms Enthusiast


Joined: 05 Mar 2003
Posts: 241

PostPosted: Sat Jul 02, 2005 7:47 pm    Post subject: Reply with quote

Sounds awesome, Shawn!

Will you be exposing .Net namespaces other than form related ones?
Back to top
View user's profile Send private message MSN Messenger
Shawn
KiXforms Developer
KiXforms Developer


Joined: 22 Feb 2003
Posts: 1983
Location: Canada

PostPosted: Sun Jul 03, 2005 10:11 pm    Post subject: Reply with quote

Would like to put whatever is "puttable" and interesting and fun into there.
Back to top
View user's profile Send private message
masken
KiXforms Enthusiast
KiXforms Enthusiast


Joined: 14 Mar 2003
Posts: 202
Location: Gothenburg, Sweden

PostPosted: Mon Jul 04, 2005 8:50 am    Post subject: Reply with quote

For a non-coder like me Wink - can you just mention some of the general advantages shawn? Smile
Back to top
View user's profile Send private message MSN Messenger
Lonkero
KiXforms Devotee
KiXforms Devotee


Joined: 13 Mar 2003
Posts: 1022
Location: Espoo, Finland

PostPosted: Mon Jul 04, 2005 5:30 pm    Post subject: Reply with quote

basicly, there is none.
and still, the main advantage is that basicly the code is cleaner and meaner as shawn started it from scratch.
also, namespace screw ups should be gone via this.
as example, socket-library should not anymore be dependent of form-events but should be tied to it's true parent.

_________________
Hammer
Back to top
View user's profile Send private message Visit poster's website MSN Messenger
Shawn
KiXforms Developer
KiXforms Developer


Joined: 22 Feb 2003
Posts: 1983
Location: Canada

PostPosted: Mon Jul 04, 2005 6:24 pm    Post subject: Reply with quote

Well, the advantage is that the new library is .NET (versus the old library that just emulates .NET). All the advanced features of .net should be (will be) there ... like Forms and Sockets and Processes. Kixforms doesn't actually implement most of this stuff, it just exposes it to Kixtart (or vbscript for that matter). Thats not to say Kixforms.Net is solely a wrapper of .NET (although that would be a fair term to use) ... Kixforms.Net has much custom code to support event handling, and object referencing and other things that circumvent the limitations of a scripting language that isn't really .NET enabled.
Back to top
View user's profile Send private message
pearly
KiXforms Aficionado
KiXforms Aficionado


Joined: 27 Jan 2004
Posts: 332

PostPosted: Tue Jul 05, 2005 7:38 pm    Post subject: Reply with quote

Asking a dumb question here, but does KiXforms.NET eliminate the need to queue events when triggering multiple events at the same time. Will it allow for multiple event triggering or is this a limitation locked down by KiXtart?
Back to top
View user's profile Send private message
Shawn
KiXforms Developer
KiXforms Developer


Joined: 22 Feb 2003
Posts: 1983
Location: Canada

PostPosted: Tue Jul 05, 2005 7:58 pm    Post subject: Reply with quote

Good question. Events were the most challenging part of getting Kixtart working with .NET. Basically the answer is yes - the full suite of .NET events will be supported. If an action generates multiple events, then all the events will be captured and ... triggered in the order they were received (that is to say, the same order that .NET has them).

By the way - events will always be received one-at-a-time, no matter how one slices that.

The other reason i re-engineered events in Kixforms.Net was to eliminate event collisions - for example a MouseDown and MoveMove being triggered at the same time (or shortly thereafter) - and a common "event property" (like MouseButton) may get "globbered" by a subsequent event - these mouse events were (are) notorious for doing this.

Now - all events have associated "eventargs" objects - just for that singluar event, so the only thing that will globber an event property is the another event of the same type.

-Shawn


Last edited by Shawn on Tue Jul 05, 2005 8:01 pm; edited 1 time in total
Back to top
View user's profile Send private message
krabourn
KiXforms Aficionado
KiXforms Aficionado


Joined: 05 Mar 2003
Posts: 273
Location: San Antonio. TX

PostPosted: Tue Jul 05, 2005 8:00 pm    Post subject: Reply with quote

Are there any .NET version dependacies? There is 1.0, 1.1, 1.2, 2.0 and that is probably not all of them. I guess my question is will this work any version of .NET?
_________________
Kelly
Back to top
View user's profile Send private message Send e-mail MSN Messenger
Shawn
KiXforms Developer
KiXforms Developer


Joined: 22 Feb 2003
Posts: 1983
Location: Canada

PostPosted: Tue Jul 05, 2005 8:03 pm    Post subject: Reply with quote

I am engineering Kixforms.Net around the lowest common denominator for now (1.0) - although most folks are using 1.1 afaik.
Back to top
View user's profile Send private message
Shawn
KiXforms Developer
KiXforms Developer


Joined: 22 Feb 2003
Posts: 1983
Location: Canada

PostPosted: Tue Jul 05, 2005 8:13 pm    Post subject: Reply with quote

Just for your own information, here is a Kixforms.Net script I am currently working on ... although obviously you cant try it yourself, just want to show you guys what the new stuff looks like (aint that much different than the old stuff):

Code:

Break On

$= SetOption("WrapAtEol","On")

$System = CreateObject("Kixforms.System")

$Form = $System.Form()
$Form.SuspendLayout()
$Form.AutoScaleBaseSize = $System.Size(5, 13);

$cmdPing = $Form.Controls.Add($System.Button())
$cmdPing.FlatStyle = $System.FlatStyle_System;
$cmdPing.Location = $System.Point(224, 8);
$cmdPing.Name = "cmdPing";
$cmdPing.TabIndex = 0;
$cmdPing.Text = "Ping Host";
$cmdPing.Click = "cmdPing_Click()"

$txtHostname = $Form.Controls.Add($System.TextBox())
$txtHostname.Location = $System.Point(8, 8);
$txtHostname.Name = "txtHostname";
$txtHostname.Size = $System.Size(208, 20);
$txtHostname.TabIndex = 1;
$txtHostname.Text = "";

$txtResponses = $Form.Controls.Add($System.TextBox())
$txtResponses.MultiLine = "True"
$txtResponses.Location = $System.Point(8, 40);
$txtResponses.Name = "lstResponses";
$txtResponses.Size = $System.Size(400, 199);
$txtResponses.TabIndex = 2;

$cmdClose = $Form.Controls.Add($System.Button())
$cmdClose.DialogResult = $System.DialogResult_Cancel;
$cmdClose.FlatStyle = $System.FlatStyle_System;
$cmdClose.Location = $System.Point(336, 248);
$cmdClose.Name = "cmdClose";
$cmdClose.TabIndex = 3;
$cmdClose.Text = "Close";
$cmdClose.Click = "cmdClose_Click()"

$cmdCancel = $Form.Controls.Add($System.Button())
$cmdCancel.FlatStyle = $System.FlatStyle_System;
$cmdCancel.Location = $System.Point(224, 8);
$cmdCancel.Name = "cmdCancel";
$cmdCancel.TabIndex = 4;
$cmdCancel.Text = "Cancel";
$cmdCancel.Visible = "false";
$cmdCancel.Click = "cmdCancel_Click()"

$Form.AcceptButton = $cmdPing;
$Form.CancelButton = $cmdClose;
$Form.ClientSize = $System.Size(416, 278);
$Form.Name = "frmPingTest";
$Form.Text = "Ping Test";
$Form.ResumeLayout(1);

$Form.Center
$Form.Show

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

Exit 0

Function cmdPing_Click()

 $procInfo = $System.ProcessStartInfo("ping", "127.0.0.1");
 $procInfo.CreateNoWindow = "True" ; "false";
 $procInfo.UseShellExecute = "false";
 $procInfo.WindowStyle = $System.ProcessWindowStyle_Hidden;
 $procInfo.RedirectStandardOutput = "True";

 $pro = $System.Process();
 $pro.StartInfo = $procInfo;
 $= $pro.Start();

 Return

EndFunction

Function cmdClose_Click()

 $Form.Close

EndFunction

Back to top
View user's profile Send private message
Les
KiXforms Aficionado
KiXforms Aficionado


Joined: 24 Dec 2003
Posts: 317

PostPosted: Tue Jul 05, 2005 10:28 pm    Post subject: Reply with quote

Hey, I just noticed the different namespace CreateObject("Kixforms.System"). Does that mean it can coexist with the existing CreateObject("Kixtart.System")?
_________________
The Repro Man
Stealing for a living!
Back to top
View user's profile Send private message
Shawn
KiXforms Developer
KiXforms Developer


Joined: 22 Feb 2003
Posts: 1983
Location: Canada

PostPosted: Tue Jul 05, 2005 10:36 pm    Post subject: Reply with quote

ja
Back to top
View user's profile Send private message
Shawn
KiXforms Developer
KiXforms Developer


Joined: 22 Feb 2003
Posts: 1983
Location: Canada

PostPosted: Tue Jul 05, 2005 11:27 pm    Post subject: Reply with quote

Just by way of comments:

The following is the new namespace for Kixforms.Net - like Les said, it coexists with the existing library - the new DLL is called Kixforms3.dll:

$System = CreateObject("Kixforms.System")

Creating a form hasn't changed:

$Form = $System.Form()

Creating controls looks kinda the same, behaves kinda the same, but there is now more flexibiity. You can create controls "inplace", like this:

$cmdPing = $Form.Controls.Add($System.Button())

This basically creates a new Button control and adds it to the form all at the same time. It returns a reference to the created object - which deviates somewhat from pure .net, but i didn't see any harm.

The new (.net) way of creating/placing controls is also supported. This allows you to pre-create all your controls - then add them to the form/containers later on:

$cmdPing = $System.Button()
$cmdPing.Text = "Ping Host"

$= $Form.Controls.Add($cmdPing)

Events now have the proper .net names, dropping the "On" prefix, otherwise its the same old thing:

$cmdPing.Click = "cmdPing_Click()"

Enumerations are exposed/handled in true .NET COM fashion (mostly) ... they're normally exposed at the library level - Kixtart doesn't support that - so i exposed them at the System level.

$cmdPing.FlatStyle = $System.FlatStyle_System;

The standard naming convention for enums is

$System.<Enum>_<Member>

That's an underscore there. Would have prefered a . (period) but can't have everything.

I kept this stuff pretty much the same:

$Form.Center
$Form.Show

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

Although .net forms dont really have a DoEvents method - kept it mostly for convience and to honor the old library ;0)

This stuff here is the ProcessStartInfo and Process classes, that supports redirection of output back into the script - the only thing that isn't Forms/Drawing related that I've included in the first build:

$procInfo = $System.ProcessStartInfo()
$procInfo.FileName = "ping"
$procInfo.Arguments = $txtHostname.Text
$procInfo.RedirectStandardOutput = "True"

-Shawn
Back to top
View user's profile Send private message
Shawn
KiXforms Developer
KiXforms Developer


Joined: 22 Feb 2003
Posts: 1983
Location: Canada

PostPosted: Tue Jul 05, 2005 11:42 pm    Post subject: Reply with quote

oh yeah forgot to mention a couple of other things

1) USing @ERROR and @SERROR in Kxiforms.Net actually provides real-live meaningfull information now !!! I use it all the time and it's invaluable. Thats why I set the WrapAtEol on.

2) Some stuff has changed much - Comboboxes and Listboxes work differently in .net. A couple of aspects of working with ListViews and ListViewItems (and especially SubItems) shocked the heck out of me.

3) Some stuff from the old library wont be (may never be) supported - like for instance expandos (although I to want to get those going again).
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    KiXforms Forum Index -> KiXforms.NET Discussion All times are GMT
Goto page 1, 2  Next
Page 1 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group