Vulcan.NET First WinForm Window
// A Simple .Net WinForm Window (in a few lines of code)
REFERENCES "System"
REFERENCES "System.Windows.Forms"
USING System.Windows.Forms
// By using the "Using" directive we no longer have to type"System.Windows.Forms"
// We can express the code equivalent of local oWin as System.Windows.Forms.Form
// simply as Local oWin as form
FUNCTION Start() AS VOID
//Local oWin as System.Windows.Forms.Form
//So the above becomes shorten to because we use the namespace.
LOCAL oWin AS Form
//Assign a non NIL Value to oWin
oWin := Form{}
// Text for Title bar of the .net Window
oWin:Text := "Vulcan.NET First Window Form"
// Center the window
oWin:StartPosition := FormStartPosition.CenterScreen
oWin:ShowDialog()
RETURN
|