form.suite4.net

form.suite4.net

© assetm gmbh

User Manual

www.suite4.net


Introduction

form.suite4.net is a graphical user interface designer for Microsoft .NET Windows Forms. It is a stand-alone tool that does not require Visual Studio .NET to be installed on the user's computer but seemlessly works together with it if the need should arise.

The tool offers the possibility to bind business classes to forms, thereby speeding up the form creation process. Tedious activities such as logically naming controls are simplified through an intelligent algorithm. Once a format has been applied to a specific control it can be copied and transferred to any selected control. Even global formatting templates that work similar to Cascading Style Sheets (CSS) on the web can be employed. This makes matching an application’s presentation layer to the corporate design of a company a swift operation.

In order to optimize the work-flow of configuring controls the program provides specific editors for recurring tasks such as setting TabIndex and limiting the scope of user input values. A built-in reporting engine makes it possible to print designed forms so they can be submitted to the client for approval or to output relevant project information on paper for further analysis.

form.suite4.net allows for smooth import of existing Visual Studio .NET projects. Once the design process is complete, the required VB.NET or C# code is generated or exported to a Visual Studio .NET project. The format of the generated code can be highly customized and existing code in Visual Studio will never be overwritten. You can even convert a Windows Forms project to an ASP.NET project, retaining most of the visual properties in the process.

This user manual is divided in several distinct sections that correspond to the main program elements.

  • General overview of some of the program features and their correct application.
  • Form Manager
  • Form Designer
  • Program options

Additional help can be found on the web at http://www.suite4.net, where you have access to instructional videos and a support forum.

Please send feedback about the program and its documentation to info@suite4.net.


Installation

System Requirements

The requirements your computer must meet in order to successfully run form.suite4.net are identical to the ones Microsoft lists for running the .NET Framework. Details can be found at MSDN .NET Framework Developer Center: System Requirements.

Note: form.suite4.net requires Version 1.1 of the .NET Framework with Service Pack 1 installed (mandatory). The respective downloads can be found on Microsoft's website and are listed here for your convenience:

  • .NET Framework Version 1.1 Redistributable Package
  • .NET Framework Version 1.1 Language Pack
  • .NET Framework SDK Version 1.1
  • .NET Framework Version 1.1 Service Pack 1

Installation of the program

Installation of form.suite4.net is a very straightforward task:

  1. Double-click on the provided .msi file to start the setup.
  2. Read and accept the license agrement.
  3. Provide an installation path.
  4. Confirm the installation.
  5. After the installer has completed its task you can start the program by choosing Start > Programs > form.suite4.net.

Note: The setup program does not write any values to the Windows Registry. All program files are contained in the program directory you provided during setup.

Deinstallation of the program

You can un-install the software through the "Software" Applet in the Windows Control Panel. Look for the entry named "suite4.net" and click "Edit/Remove".

The program does not leave any traces on your system after it has been un-installed.


Working With Business Classes

Note: additional information on the subject contained here can be obtained from an instructional video clip [image] at the form.suite4.net web site.

You can bind business objects of your application to a form in a form.suite4.net project. When the code for the form is generated, form.suite4.net includes code statements based on your preferred data binding method (see below).

Note: form.suite4.net concerns itself only with the presentation layer of .NET applications. Therefore, even though the code generation engine takes care of setting control property values to business object property values, you are still responsible for retrieving an instance of the business class from lower application layers and storing it back to the data store once editing of the data is complete.

s supports two different approaches to binding a business object to a form. They differ in the generated code and are based on the two most common scenarious found in working with data in a .NET environment:

  1. Manual assignment of business object property values to controls and writing their values back to the business object. This is a flexible but usually rather involved approach as it entails typing lots of repetitive code statements (along the lines of myControl.Text = myBusinessObject.MyProperty) that assign business object properties to control property values. form.suite4.net's code generation engine comes in very handy here, as the "typing" is delegated to the tool — permitting the developer to concentrate on more important tasks.
  2. Use of built-in Windows Forms data binding features using myControl.DataBindings.Add(…) and related operations. Microsoft's recommended approach. Easy to use for simple data manipulation operations.

This sample excerpt shows the code generation engine's output for binding a business object to form control properties using the first (manual) approach:

public void InitializeDataSource(assetm.Northwind.EmployeesRow employeesRowdata)
{
    this.SuspendLayout();
    this.Save();
    this._IsInitializing = true;
    this.Reset();
    this._EmployeesRowdata = employeesRowdata;
    if((this._EmployeesRowdata != null))
    {
        this.txtEmployeeID.Text = this._EmployeesRowdata.EmployeeID.ToString();
        this.txtTitleOfCourtesy.Text = this._EmployeesRowdata.TitleOfCourtesy;
        this.txtTitle.Text = this._EmployeesRowdata.Title;
        this.txtCountry.Text = this._EmployeesRowdata.Country;
        this.txtRegion.Text = this._EmployeesRowdata.Region;
        this.txtPostalCode.Text = this._EmployeesRowdata.PostalCode;
        this.txtCity.Text = this._EmployeesRowdata.City;
        this.txtStreet.Text = this._EmployeesRowdata.Address;
        this.txtFirstName.Text = this._EmployeesRowdata.FirstName;
        this.txtLastName.Text = this._EmployeesRowdata.LastName;
    } // end if((this._EmployeesRowdata != null))
    this.ResumeLayout(false);
    this._IsInitializing = false;
    this._IsDirty = false;
} // end public void InitializeDataSource(assetm.Northwind.EmployeesRow employeesRowdata)

This is the output for the same form when using Windows Forms databinding:

public void InitializeDataSource(assetm.Northwind.EmployeesRow employeesRowdata)
{
    this.SuspendLayout();
    // Clear DataBindings for all components.
    this.txtTitleOfCourtesy.DataBindings.Clear();
    this.txtTitle.DataBindings.Clear();
    this.txtCountry.DataBindings.Clear();
    this.txtRegion.DataBindings.Clear();
    this.txtPostalCode.DataBindings.Clear();
    this.txtCity.DataBindings.Clear();
    this.txtStreet.DataBindings.Clear();
    this.txtFirstName.DataBindings.Clear();
    this.txtLastName.DataBindings.Clear();
    this._EmployeesRowdata = employeesRowdata;
    if((this._EmployeesRowdata != null))
    {
        this.txtTitleOfCourtesy.DataBindings.Add("Text", this._EmployeesRowdata, "TitleOfCourtesy");
        this.txtTitle.DataBindings.Add("Text", this._EmployeesRowdata, "Title");
        this.txtCountry.DataBindings.Add("Text", this._EmployeesRowdata, "Country");
        this.txtRegion.DataBindings.Add("Text", this._EmployeesRowdata, "Region");
        this.txtPostalCode.DataBindings.Add("Text", this._EmployeesRowdata, "PostalCode");
        this.txtCity.DataBindings.Add("Text", this._EmployeesRowdata, "City");
        this.txtStreet.DataBindings.Add("Text", this._EmployeesRowdata, "Address");
        this.txtFirstName.DataBindings.Add("Text", this._EmployeesRowdata, "FirstName");
        this.txtLastName.DataBindings.Add("Text", this._EmployeesRowdata, "LastName");
    } // end if((this._EmployeesRowdata != null))
    this.ResumeLayout(false);
} // end public void InitializeDataSource(assetm.Northwind.EmployeesRow employeesRowdata)

Depending on the selected approach, additional methods may be added to the form which perform functions such as:

  • resetting the form to its initial state
  • raising events upon user changes to control properties
  • writing control property values back to the business class.

You can assign a business class to a form as follows:

  1. Select the form in the Form Manager.
  2. In the Form Detail pane, under Form Settings, click on the button with the three dots as shown below:
  3. The Select Class dialog window opens. Click on the button with the three dots to browse to the assembly containing the desired business class.
  4. Find the business class in the left pane and select it. Its properties are shown on the right.
  5. Click OK to confirm your selection. The class is now bound to the form.
  6. If you want to use Windows Forms data binding, select the "Use Data Binding" checkbox.


Exporting to Visual Studio .NET

forms.suite4.net projects can be exported as a Visual Studio .NET project in the language of your choice (currently C# and Visual Basic .NET are supported). Additionally, you have the option of converting the Windows Forms project into an ASP.NET Web Forms project if this should be required.

The export is performed in the Form Manager. Choose File > Export as VS Project. The "Export as Visual Studio Project" dialog appears.

In addition to selecting the directory where you want the project files to be stored (using the button marked with 1 above) you have to make two choices in regards to the consistency of the both the forms.suite4.net project and the Visual Studio project:

  • Set "CanDelete" for all components to false
    All form.suite4.net components have a CanDelete property which can be found in the Property Grid when the control is selected in the Form Design Area. Using this property you can prevent deletion of the control within a form. The export engine sets CanDelete to false for all components by default, i.e. accidental deletion of a component which has previously been exported will be impossible. This way, you can keep the exported code and the form.suite4.net project consistent with each other. If you activate the checkbox (2) in the "Export as Visual Studio" dialog, however, no changes will be made to the CanDelete settings.
  • Set "CanRename" for all components to false
    This setting (3) works similar to the one above but it applies to the CanRename property of the exported controls. By default, controls can not be renamed after they have been exported, but activating the checkbox overrides this behavior.

After you click on the "Start" button in the "Export as Visual Studio Project" dialog, the form.suite4.net project will be exported to the directory you specified earlier. Progress is displayed in the dialog while the files are being written.

The export engine creates a separate directory for each Group you have specified in the Project Explorer and organizes the generated code in namespaces corresponding to the Groups' names. After the export is finished you can view the generated files in Visual Studio .NET and add behavior to the forms and controls you have created.

Note: combined with the import function, exporting a form.suite4.net project as a Visual Studio project is a powerful method of converting a layout project between .NET languages: import a C# project form Visual Studio .NET into form.suite4.net, set the project language to VB.NET and export it using the procedure described above -- all the imported files will be converted to VB.NET.
Please be aware that the import only considers the layout elements of a VS.NET project. Behavior will not be imported and will thus not be available in the exported project either.

Exporting as ASP.NET Web Forms

If you select the "ASP.NET Web Forms" option in the "Export as Visual Studio Project" dialog, the existing Windows Forms project will be converted to ASP.NET. Here is what happens during the conversion process:

  1. Forms are converted to ASP.NET pages (*.aspx).
  2. Controls are mapped to matching controls in the System.Web.UI.* namespaces. Currently form.suite4.net only supports the conversion of basic controls, such as TextBox, RadioButton, GroupBox, TabControl and the like. Complex controls such as the TreeView will not be converted.
  3. Controls are positioned on the ASP.NET page using either flow-layout (HTML tables) or grid-layout (Cascading Stylesheets), depending on the choices you made for the form and the project (see ASP.NET-related settings in the Project Explorer for more information).
    • Flow Layout
      The controls are inserted into an HTML table structure. If you activate the "ASP.NET Web Controls" option for the project, the table will itself be created with ASP.NET Server Controls (<asp:Table id="Table1" [...]); otherwise simple HTML tags will be used.
    • Grid Layout
      The controls are arranged on the page using Cascading Stylesheets (CSS) instructions for absolutely positioning elements on a page. The controls will not move if the browser window is resized (as they would when using Flow Layout) but stay at a fixed position on the page at all times.
  4. A code-behind file (*.aspx.cs | *.aspx.vb) is created that contains the control declarations and — if Grid Layout is used — full initialization routines for the controls.

Once the files have been written to the designated output directory, you can either import them into an existing ASP.NET project or create a new one using Internet Information Services (IIS) manager or Visual Studio .NET. Compile them, preview the output in the browser and make any necessary changes and extensions as you see fit.


Converting forms to ASP.NET

Converting forms and controls to ASP.NET

form.suite4.net provides a built-in engine for converting the forms and controls in a project to ASP.NET web forms and user controls. While we make no claim to support a full conversion between Windows Forms to ASP.NET Web forms, most of the common Windows Forms controls will be converted to their ASP.NET counterparts.

Adapting the ASP.NET conversion process is described in the following sections of the manual:

  • ASP.NET-related settings in the Project Explorer
  • Exporting as ASP.NET Web Forms


Import

Importing elements from Visual Studio .NET and form.suite4.net projects

You can import elements from external sources into a form.suite4.net project. This is done in the Form Manager.

The sources currently available for import are:

  • Visual C# projects,
  • Visual Basic .NET projects,
  • other form.suite4.net projects.

Importing from Visual Studio .NET projects

  1. In the Form Manager main menu choose File > Import Source. The "Import From VS Project" dialog appears.
  2. Browse to the C# or VB.NET project file you want to import from and click "Open". The forms contained in the project are being added to the project explorer.

Importing from another form.suite4.net project

You can import elements from other form.suite4.net projects into the project that is currently opened. Import of external elements must be done into a Group in the Project Explorer.

  1. Select the Group you want the imported elements to appear under in the Project Explorer.
  2. In the Form Manager main menu choose File > Import from project. The "Open Project" dialog appears.
  3. Browse to the project file you want to import and click "Open". The "Import Forms" dialog appears.
  4. The pane on the left displays all forms available in the external project. Move the ones you wish to import to the pane on the right and click "OK". The forms you selected are added to the project under the Group you specified in step 1.


FormDatabase

Loading forms dynamically — the FormDatabase API

The form.suite4.net application allows you to export the forms you created in the designer into various formats, such as a Visual Studio .NET project or ASP.NET Web Forms. However, the result of the export is static: if you make a change to a form in a form.suite4.net project you have to re-export the updated element in order to use it in your application.

The form.suite4.net FormDatabase API is an effective approach to overcome this limitation. It provides programmatic tools to dynamically load and manipulate forms and controls in both Windows desktop and Web environments. If you make a change to an element in a form.suite4.net project, the display of the element will be updated immediately — effectively eliminating the need to re-export project elements or re-compile the application.

Physically, the FormDatabase consists of the form.suite4.net project file and the suite4.net.FormDatabase.dll assembly. Using the provided classes and interfaces you can access and manipulate a comprehensive set of form.suite4.net project elements. Since dynamically loading project elements works by reading the contents of a project file, it's enough to deploy the updated project file to the production environment after you made changes to a project. The next time the assembly accesses the project file, the updated elements will be displayed the way you defined them in the form.suite4.net application.

Due to the fundamental difference in the nature of Windows desktop and Web environments the FormDatabase API provides separate classes for dynamically loading form.suite4.net forms and controls in each. The following topics provide a high-level introduction to the two approaches:

  • Windows Loader Components
  • WebLoader Component

Further information can be found in the FormDatabase API Documentation.


LoaderForm and LoaderControl Components

Using the form.suite4.net FormDatabase component, existing forms can be dynamically loaded and used in both Web and Windows environments. For .NET Windows Forms, this functionality is the responsibility of the LoaderForm and LoaderControl components. Both can load a form or user control that has been defined in the form.suite4.net application and display it.

The LoaderControl and LoaderForm perform slightly different functions but their purpose is the same: to read a form or user control from a form.suite4.net project file and display it on a .NET Windows Form.

The LoaderControl can be used like a regular System.Windows.Forms.UserControl at design time; it can be placed on a System.Windows.Forms.Form or into container controls such as the TabPage. The LoaderForm, on the other hand, is better suited for use in an MDI-environment or as a dialog window.

Note that neither the LoaderControl nor the LoaderForm make a distinction in regards to the elements they load and display — form.suite4.net Forms and UserControls are treated alike (through the IForm interface).

Because form definitions are read dynamically from the form.suite4.net project file, all updates can be performed in a central location — the form.suite4.net designer — and changes will be visible immediately without the need to re-compile (and re-deploy) the application.

The RootControl property

In addition to simply loading and displaying form.suite4.net forms and user controls, the LoaderControl and LoaderForm components provide the means to modify the properties of existing System.Windows.Forms.Form or System.Windows.Forms.UserControl instances. This is achieved through the use of the RootControl property.

Essentially, you can mask an existing Form/Control with a form.suite4.net IForm. During the loading process the IForm overrides each property of the Form/Control with the same name and type as one of its own, effectively resulting in a merge between the Form/Control and the IForm.

Possible uses of this technique include showing/hiding of controls based on user roles, or localization of form labels for different user languages.

Note: another approach to localization encompasses the use of form.suite4.net visual form inheritance.


WebLoader

WebLoader Component

Using the form.suite4.net FormDatabase component, existing forms can be dynamically loaded and used in both Web and Windows environments. For web pages, this functionality is achieved by taking advantage of Macromedia® Flash™ technology. This allows for constistent and predictable rendering of forms across client browsers and operating systems that have Flash Player 7.0 and higher installed.

The WebLoader component is essentially a Flash (.swf) file that is able to dynamically display a form that has been created in the form.suite4.net application. It queries an XML Web Service on the server for data on the form to be displayed and draws it accordingly. The Web Service, in turn, receives the form information from the form.suite4.net project file that has been placed on the server, as depicted in the following illustration:

The form layout is created in the form.suite4.net designer using the tools available there. After the project file has been placed on the server, the Web Service can extract all the necessary information from it to display the form on a web page. When you make changes to an existing form in the form.suite4.net designer, they will immediately be visible to Web site visitors after the updated project file has been placed on the server. No HTML knowlege is required, visual updates only occur in one place — the form.suite4.net designer.

Communication between the WebLoader and its Web Service is achieved through the use of WebLoaderEvents. You can pass parameters to the Web Service and query it for business data or use it to change the form's user interface language. The IForm interface of the FormDatabase assembly contains methods to serialize and deserialize a form and its associated business object for smooth interaction with the Web Service.

If a form includes images, the WebLoader component will extract them from the form and display them in the Flash player. This allows for the creation of visually rich user interfaces for Windows and the Web.

Configuring WebLoader events

WebLoader events are configured on the client and handled on the server or client, depending on the configuration. The first step is to enable an existing form for use with the WebLoader component by selecting the form in the Project Explorer of the Form Manager and activating the checkbox "WebLoader enabled" as shown on the right.

Next, open the form in the Form Designer and select the control on the form which you want to associate the event with. In most cases, this will be a command button. Because the form has been enabled for use with the WebLoader in the previous step, an additional panel is displayed that allows you to configure the WebLoader event according to your needs. The panel is shown on the left.

The value selected in the "EventType" dropdown-list determines where the event will be handled — if it's set to "WebService" a server-side method will be called, whereas setting it to"JavaScript" will have the WebLoader look for and call a client-side JavaScript function.

Note that the values of most of the available parameter types in the "WebLoader Events" panel are provided by the system. For example, you do not have to provide an explicit value for "FormName", as the WebLoader will automatically pass this value to the configured event handler method. Only setting the parameter type to "UserDefined" enables the textbox for providing a custom parameter value as shown in the screenshot above.

Debugging the WebLoader

Flash Player is highly tolerant of errors by design, so you may need a "window" into what's going on in the WebLoader during development and/or testing as you will not get any error messages from the player itself. The component provides three configurable levels of debugging:

  • DebugLevel 0: Silent mode. No messages are displayed. This is the recommended level for a production application.
  • DebugLevel 1: All errors are displayed as they occur.
  • DebugLevel 2: Tracing mode. All Web Service calls including their parameters are displayed.

The debug levels are set as parameters of the <object> tag on the Web page that hosts the WebLoader component.


Form Inheritance

Visual Form Inheritance

Creating a consistent look for the forms of an application can be a challenging task, especially when the application is quite large. form.suite4.net provides stylesheets as a means to ease the tedium connected with re-creating formatting across different forms, but it also offers another alternative — form inheritance.

Using the Form Manager, you can easily create inherited forms by right-clicking on any existing form in the Project Explorer and selecting "Inherited Form" in the context menu. A new form is added to the project, which inherits all controls and properties from the base form. It can be freely modified in the Form Designer just like the base form.

When you generate the code for the RootForm and its inherited form(s) after the design process is completed, the following changes occur:

  • All access modifiers for controls on the RootForm are set from private to protected. This allows access to the controls in the parent form from any child form.
  • The method Initialize Component in the child forms contains merely the changes between the parent form and the child. Controls that remain unchanged between the parent and the child are not initialized again.

Resetting changes in inherited forms

If you work in an inherited form in the Form Designer, you have the option to undo all or only a subset of the changes you made to any given control. This is achieved by right-clicking on the control and selecting "Reset all" or "Reset size/location" form the context menu.

  • Reset all: undo all the changes to all the properties of the control and set it back to the state originally specified in the parent form.
  • Reset size/location: only undo changes made in regards to sizing or positioning of the control. Other properties, such as ForeColor or BorderStyle remain untouched.

Applications of visual form inheritance

In addition to the obvious benefits of using inheritance for achieving a consistent visual layout across the forms of an application, there are two more applications you may want to consider:

  1. Localization of user interface elements. Design the layout of your forms in the Form Designer and enter all label texts in the primary language, then create an inherited form for each additional language you want to support. Change the texts — and, if necessary, the control sizes — in the child forms to match the requirements of the target language.
  2. Role-based security of form data. Depending on the role of the current user, show/hide specific controls in child forms or make them read-only. This helps protect the integrity of the data your application is entrusted with.

Note: there is no technical limit to the levels of nested inheritance supported by form.suite4.net.


License key

Licensing procedure

During the time you are running a trial of form.suite4.net the program will remind you of the number of days remaining for the trial period on startup.

Purchasing the product

Clicking on "Buy Now" (1) will take you to a purchasing page at http://www.suite4.net where you can acquire a license for continued use of the product beyond the end of the trial period. After payment has been received an email containing a license file will be sent to you.

Activating the product

After you have purchased a license through our web site you will receive a text file with the license data. When the reminder window shown above appears the next time you start form.suite4.net, click on "I already have a license" (2). This will bring up the "Select Existing License" dialog.

Browse to the license file you received and click "OK". This activates the software permanently.

Note: Be sure to store the license key in a safe location so it is available when you reinstall the program at some other time.


Form Manager

Note: additional information on the subject contained here can be obtained from an instructional video clip [image] at the form.suite4.net web site.

The Form Manager is the central administration facility for a form.suite4.net project. Here you set global project options, arrange project elements in logical Groups (which will be reflected as namespaces in the generated code), add forms to Groups and controls to forms, and assign business classes to forms. Information pertaining to the selected item in the Project Explorer is displayed in a detailed view on the right for a quick overview of the project and its elements.

Some of the features available in the Form Manager are:

  • Forms can have business classes assigned to them. For more information see Working With Business Classes.
  • All the controls contained in a selected form are displayed hierarchically and can be examined at a glance.
  • Forms and controls can be imported (into Groups only) from other form.suite4.net projects.
  • Supports drag and drop of controls or entire containers onto other forms from the grid view below the Form Details pane.
  • A preview of any form can be displayed with a single click.
  • Copying and pasting of forms is supported.


Form Manager: Main Menu

File

The File menu allows basic manipulating of forms and user controls with the following commands:

New | CTRL+N | Create a new project.
Open | CTRL+O | Open an existing project.
Save | CTRL+S | Save the selected project.
Save As |  | Save the project under a different name.
Add Item |  | Add a new Group / RootForm / Inherited Form.
Import from Project |  | Import elements from another form.suite4.net project.
Export as VS Project |  | Export the source code as a Microsoft Visual Studio .NET project.
Import from VS |  | Import a project from Microsoft Visual Studio .NET.
Exit | ALT+F4 | Exit the Form Manager.

Edit

Open in Designer | CTRL+D | Open the selected form in the Form Designer.
Copy | CTRL+C | Copy the selected form.
Delete | Del | Delete the selected form from the project.

View

Project Explorer Display the Project Explorer.

Tools

Preview | CTRL+W | Display a preview of the currently selected form in the Project Explorer.
Source C# | CTRL+F11 | Generate the C# code for the selected form and display it in a preview window.
Source VB | CTRL+F12 | Generate the VB.NET code for the selected form and display it in a preview window.
ASP.NET Source |  | Convert the selected form to an ASP.NET page and display the generated code of the *.aspx page in a preview window.
ASP.NET Source C# |  | Convert the selected form to an ASP.NET page and display the generated C# code-behind.
ASP.NET Source VB |  | Convert the selected form to an ASP.NET page and display the generated VB.NET code-behind.
Options |  | Set the program options.

Help

Contents | F1 | Opens the program's online help.
About Form Manager |  | Displays copyright and technical information about the program.


Form Manager: Toolbar

The Form Manager toolbar contains the following items:

New Project | Create a new project.
Open Project | Open an existing project.
Save Project | Save the selected project.
Add Group | Add a new Group.
Add Root Form | Add a new Root Form.
Open in Designer | Open the selected form in the Form Designer.
Copy Item | Copy the selected form.
Delete Item | Delete the selected form from the project.


Form Manager: Project Explorer

Project Explorer

The Project Explorer displays a hierarchical list of all the Groups, forms and controls you have added to your project. When you select an element in the Project Explorer, corresponding information about the selection is displayed in the main program window.

Selecting the project itself at the root of the Project Explorer (as shown above) allows you to set global project preferences such as the target programming language — currently VB.NET and C# are supported — or the namespace that should be added to the generated code.

Adding elements to a project

If you start with an empty project, you can add new items to it by right-clicking on the project name in the Project Explorer and selecting either "Add Group" or "Add Rootform".

A Rootform can be a .NET Windows Form or a UserControl, depending on how you configure it using the "Formtype" dropdown list (see below).

A Group is a logical container for Rootforms that provides you with both a means of structuring your project within form.suite4.net and within the generated code because Group names are included as namespaces in the code generation output.

Switching between forms and user controls

After you selected a form in the Project Explorer, you can view and edit its properties in the main program window. If you want to turn a form into a user control (or vice versa) simply select the desired type from the "Formtype" dropdown list.

Adding tasks to a project or group

Tasks can be assigned to individual forms or controls, to groups and the project itself. Linking tasks to controls is done in the Form Designer as described in Task/Description Board. To add tasks to a project or group complete the following steps:

  1. Select the project or group node in the Project Explorer.
  2. In the main window, click on the "Tasks" tab.
  3. Right-click on the list in the bottom half of the window and select "Add task" from the context menu. A new task is added to the list.
  4. Select the newly added task and edit its properties in the input fields in the top half of the window.

Deleting tasks from a project or goup

  1. Select the task that is to be deleted.
  2. Right-click on it and click on "Delete task" in the context menu.

ASP.NET-related settings

form.suite4.net can convert forms and controls of a project to ASP.NET web forms and user controls. A number of settings in the Form Manager determine the parameters of the conversion.

  1. "Use ASP.NET flow layout". This setting is available from the details pane after you selected a form or control in the Project Explorer. It determines the method employed to place controls onto the ASP.NET page or user control when the selected form is converted to ASP.NET.
    The two available otions are:
    • Grid Layout: the default method. Controls are absoluteley positioned using Cascading Stylesheets (CSS) instructions similar to the following:
      <asp:TextBox id="MyTextBox" runat="Server" style="position:absolute;top:15px;left:25px; [...]">[...]</asp:TextBox>
      Resizing the browser window will not affect positioning of the controls.
    • Flow Layout: the "traditional" method for web page layout. Controls are placed in a dynamically created table structure. Their position is determined by the location within the table. Resizing the browser window will cause the controls to realign their positions.
    Note: Flow Layout can further be customized by using the setting described next.
  2. "Use ASP.NET Web controls". This project-wide setting refers to the way layout tables for holding the controls are being generated when using Flow Layout (see above).

    Activating it will cause the tables to be created with ASP.NET Server Controls as in the following snippet:

    <asp:Table id="Table1" runat="Server">
      <asp:TableRow runat="Server">
        <asp:TableCell runat="Server">[...]</asp:TableCell>
      </asp:TableRow>
    <asp:Table>

    If the option is deselected, simple HTML elements will be used instead:

    <table [...]>
      <tr>
        <td>[...]</td>
      </tr>
    </table>

    Note: since this setting applies to the entire project, it is only available after the project has been selected in the Project Explorer.

Enabling a form or control for use with the WebLoader component

The WebLoader component is unique feature of form.suite4.net that allows you to publish an existing form on a web page. Activating the "WebLoader enabled" checkbox does just that -- it enables a form or control you selected in the Project Explorer to be used in conjunction with the WebLoader component. After you activated the checkbox, an additional panel appears in the Form Designer that allows you to configure the WebLoader interaction.


Form Designer

The form.suite4.net Form Designer is a professional graphical user interface design tool for .NET Windows Forms. Here you design the forms, add controls and set their properties.

Some of the features you can take advantage of during the design process are:

  • Keeps look and feel of the form even when it is resized.
  • Works with any .NET controls or containers including custom or 3rd party controls.
  • Locking of individual controls prevents accidental editing. Cut, copy and paste controls and control groups.
  • A Clipcontainer with drag and drop support caches controls for later reuse.
  • All possible sizing and positioning options for every form control or container
  • Controls can be manipulated as a group through multi-select and -move as well as aligning the sizes of controls to a reference control.
  • Snap-to-grid. This facility ensures that controls can be aligned with minimal effort. The grid's size and appearance can be customized.
  • Support for nested controls that are contained within another control.
  • Forms and controls can be uniformly styled by employing customizable Style Sheets.
  • End user input can be guided by setting the TabIndex of controls with the TabIndex Editor or limiting input length using the Limit Editor.
  • UI elements can have tasks and/or descriptions assigned using the Task/Description Board.
  • Control properties can be set using a standard property grid or the Quick Properties Editor which assembles the most commonly used properties in one place for swift access and manipulation.


Form Designer: Main Menu

File

Close Designer | Exit the Form Designer. If you have made changes to the form you will be asked if you want to save them before exiting the designer.
Save | Save all the changes made to the current form. Undo history will be reset.

Edit

The Edit menu allows the manipulation of controls on the current form or user control with the following commands:

Undo | CTRL+Z | Undo last action.
Redo | CTRL+Shift+Z | Redo last action.
Cut | CTRL+X | Cut selected controls from a form to the clipboard.
Copy | CTRL+C | Copy selected controls from a form to the clipboard.
Paste | CTRL+V | Insert controls from the clipboard to a form.
Delete | Del | Delete selected controls from a form.
Copy appearance |  | Copy appearance properties for application to another control.
Select All | CTRL+A | Select all form controls.

View

The View menu allows the user to enable or disable various viewing options.

Show Ruler | Toggle ruler visibility.
Show Grid | Toggle grid visibility.
Design explorer | Show or hide the Design Explorer.
Properties | Show or hide the Property Grid for the selected object.
Quick Properties | Show or hide the QuickProperties Editor.
Toolbox | Show or hide the Toolbox.
Clipboard | Show or hide the Clipboard.
Task/Description Board | Show or hide the Task/Description Board.

Format

The Format menu allows for editing the layout of forms or user controls using a number of commands which are described in Form Designer: Format Menu.

Tools

Preview | CTRL+W | Displays a preview of the form that is currently opened in the Form Designer.
TabIndex Editor | CTRL+T | Opens the TabIndex Editor.
Limit Editor | CTRL+L | Opens the Limit Editor.
Source C# | CTRL+F11 | Generates the source code of the current form in C# and displays it in a preview window.
Source VB | CTRL+F12 | Generates the source code of the current form in Visual Basic .NET and displays it in a preview window.
Options |  | Opens the Options dialog window.

Help

Contents ... | F1 | Displays the program's online help.
About Form Designer |  | Displays copyright and technical information about the program.


Form Designer: Toolbar

The Form Designer contains a number of different toolbars that provide access to the most frequently used commands of the main menu.

Basic

Close Designer | Exit the Form Designer. If you have made changes to the form you will be asked if you want to save them before exiting the designer.
Save | Save curent layout to file.
Undo | Undo last action.
Redo | Redo last action.
Cut | Cut selected controls from a form to the clipboard.
Copy | Copy selected controls from a form to the clipboard.
Paste | Insert controls from the clipboard to a form.
Delete | Delete selected controls from a form.

Style Sheets

Style Sheet | Select the style sheet to be applied.
Copy to Style Sheet | Copy formatting instructions of the currently selected control to the active style sheet.
Apply Style Sheet | Apply formatting instructions stored in the active style sheet to the currently selected control(s).

Format

Align Left | Align controls to the leftmost selected control.
Align Horizontal Center | Align the center points of the controls along a horizontal axis.
Align Right | Align controls to the rightmost selected control.
Align Top | Align controls to their topmost selected control.
Align Vertical Center | Align the center points of the controls along a vertical axis.
Align Bottom | Align controls to their bottommost selected control.
Align to Grid | Align controls to the Form Designer's grid.
Match Width | Match the selected controls' widths.
Match to Grid | Match the controls' size to the grid.
Match Height | Match the selected controls' heights.
Match Width and Height | Match both height and width of the selected controls.
Space Evenly Horizontally | Space selected controls evenly horizontally.
Increase Horizontally | Increase horizontal spacing between selected controls.
Decrease Horizontally | Decrease horizontal spacing between selected controls.
Remove Horizontal Spacing | Remove horizontal spacing between selected controls.
Space Evenly Vertically | Space selected controls evenly vertically.
Increase Vertically | Increase vertical spacing between selected controls.
Decrease Vertically | Decrease vertical spacing between selected controls.
Remove Vertical Spacing | Remove vertical spacing between selected controls.
Center Horizontally | Center selected control horizontally on the form.
Center Vertically | Center selected control vertically on the form.
Bring to Front | Place the control at the top of the stacking order.
Send to Back | Place the control below all other selected controls.
Lock Control | Prevent changes to a control.
Copy Appearance | Copy the appearance settings of a control to the clipboard for subsequent application to another control.
Apply Appearance | Apply appearance settings stored in the clipboard to the selected control.


Form Designer: Design Area

Design Area

The Design Area is your "canvas" for working with forms and controls. Selecting any item allows you to set its properties using the Property Grid or the QuickProperties Editor.

You can use the ruler and the grid for precise alignment of elements. A right-click on elements often displays a context menu providing access to additional features.

One of these is a convenient method to switch between control types. Right-click on a control, choose Change to and click on any of the available control types.

If the Change to command is disabled it means that no possible alternate control types have been defined yet for the currently selected control. This functionality can be extensively customized in the program options for the Form Designer. There you can define for each of the Windows Forms controls an exact list of control types that are to appear as alternatives.


Form Designer: Design Explorer

Design Explorer

Note: additional information on the subject contained here can be obtained from an instructional video clip [image] at the form.suite4.net web site.

The Design Explorer displays a hierarchical view of all the elements currently placed in the designer window.

Each control has a number in square brackets [] assigned to it. This is the control's TabIndex which can be changed using the Property Grid or TabIndex Editor.

Clicking on an element in the Design Explorer selects the element in the designer.


Form Designer: Property Grid

Property Grid

The Property Grid is the Form Designer control that allows you to manipulate the properties of any control currently selected in the designer window.

Select the property you want to modify and make the required changes. They will be reflected in the designer window immediately.

Note: you can find detailed information about each of the properties available in the Property Grid in the .NET Framework Class Library documentation of the System.Windows.Forms namespace. An online version is available at Microsoft's MSDN website.

Changes made using the property grid can be persisted when exiting the Form Designer as the program will ask you whether or not you want to save them before closing the Form Designer Window.

Note: experience has shown that only a limited number of properties available in the standard Property Grid are actually being used in day-to-day operations. Therefore, we have developed a QuickProperties Editor that allows you to edit the most common form and control properties in one convenient place.


Form Designer: QuickProperties

QuickProperties

Note: additional information on the subject contained here can be obtained from an instructional video clip [image] at the form.suite4.net web site.

The QuickProperties Editor provides an alternative to the Property Grid. While both perform essentially the same function — allowing you to modify properties of forms or controls — the QuickProperties Editor contains only the most relevant properties that you are most likely to use during day-to-day form design tasks.

Here you can conveniently set the name of a control, manage the linkage of the control to a business class property and modify its appearance, size or locking settings.

Depending on the settings in the program options, you can have the QuickProperties Editor automatically assign a name to the control based on the value entered in the "Text" input field. This way, if you enter "LastName" as the "Text" value of a TextBox control, the "Name" property is set to "txtLastName". If the control already contains a value in the "Text" input field, you can double-click on the field to have the name adjusted in the same way.

Please note that this function is disabled by default and has to be enabled in the program options first. To do this go to the main menu, choose Tools > Options > Designer > Common > Control Edit Options and activate the Use control text as control name checkbox.


Form Designer: Task/Description Board

Task/Description Board

Note: additional information on the subject contained here can be obtained from an instructional video clip [image] at the form.suite4.net web site.

The Task/Description Board provides a repository for both tasks assigned to a form element and short notes for documenting the design process. If you enter a description it is added as a comment to the generated code.

Click on one of the tasks/descriptions in the list automatically selects the corresponding control in the Form Designer window.

You can add or edit tasks and descriptions using the Task/Description Editor.

Enter a short and (if required) a detailed description. Make the appropriate changes in the dropdown lists for "Type", "Priority" and "Assigned to:" and click OK to save the data.


Form Designer: Limit Editor

Limit Editor

Note: additional information on the subject contained here can be obtained from an instructional video clip [image] at the form.suite4.net web site.

The Limit Editor is a feature that lets you set the MaxLength property of multiple text boxes or the Maximum and Minimum properties of a NumericUpDown control from one convenient location. MaxLength, Minimum and Maximum are used to limit the number of characters or range of values a user can enter in a control and are very useful in constraining and/or validating end user keyboard input.

Use the Limit Editor as follows:

  1. Select the text box you want to modify, and click on "Limit Editor" in the context menu. Alternatively you can simply right-click on the form itself.
  2. The Limit Editor displays the current MaxLength value of all text boxes. Click in the green box next to the control you want to modify and edit the value.
  3. Repeat step 2 for any other text boxes you want to modify.
  4. Exit the Limit Editor by right-clicking on the form and selecting "Close Limit Editor" or "Close Limit Editor (Save)". Doing the former will discard your changes whereas the latter will save them.


Form Designer: TabIndex Editor

TabIndex Editor

Note: additional information on the subject contained here can be obtained from an instructional video clip [image] at the form.suite4.net web site.

The TabIndex Editor is a swift method of defining the TabIndex of controls on a form, thereby setting the TAB-key sequence for the end user.

Recommended use of the TabIndex Editor is as follows:

  1. Open the TabIndex Editor by right-clicking on the form in the Form Designer and selecting "TabIndex Editor".
  2. The TabIndex property values of all visible controls are displayed by the TabIndex Editor in green and red boxes. The color of the box denotes:
    • Green: The TabStop property of the control is set to true. The user can reach the control using the TAB key.
    • Red: TabStop is set to false. The user won't be able to reach the control using the TAB key.
    Change a control's value of TabStop by right-clicking the control and selecting or deselecting "TabStop" from the context menu.
  3. To change the TAB order of two controls drag the box of the first control onto the box of the second one. The TabIndex values of the two controls will be swapped.
  4. Repeat steps 2 and 3 until you have set the TabIndex and/or TabStop values of all controls to their desired value.
  5. If you want to quickly arrange the TAB order of all the controls on a form, right-click on the form, point to "Whole Form" in the contex menu and select "Horizontal" or "Vertical". The TabIndex of all controls is adjusted appropriately.

    Note: this procedure can also be applied to containers: instead of selecting the whole form, you select a container only and perform the same menu commands — the resulting tab order will only apply to the container, not to the entire form.


Form Designer: Toolbox

Toolbox

Note: additional information on the subject contained here can be obtained from an instructional video clip [image] at the form.suite4.net web site.

The Toolbox provides access to user interface controls and other components. The elements are arranged in groups, the most of common of which are "Windows Forms", "Data Tools" and — providing the form is connected to a business class — "Business Class". These groups are explained below.

You can customize the Toolbox by right-clicking on it and selecting any of the commands from the context menu. Customization options include modifying the sequence of elements in the Toolbox, moving elements between groups and adding custom elements from external DLLs.

Drag an element from the Toolbox to the form to position it precisely or double-click on it to add it without regard to its position.

Windows Forms

This section of the toolbox contains the set of built-in .NET Windows Forms controls. Further information about these controls is available in the MSDN documentation of the System.Windows.Forms namespace.

Data Tools

This group contains non-visual components for use with ADO.NET data access. Information on them is available in the System.Data and related namespaces in the .NET Framework documentation.

Business Class

form.suite4.net provides you with the necessary infrastructure to connect a form to a business class. Once assignment of a class to a form has been accomplished, the Toolbox contains an additional group named "Business Class".

The group lists all public properties of the class. Each property is bound to a control that is most suitable to display the property's data type. String properties are bound to TextBox controls, DateTime properties to DateTimePicker controls and so on. Where a class property can be displayed in more than one control, this control is also provided as can be seen in the example to the left. One of the controls is the default, the other or others are alternatives that can be used as well.

Double-click on the control or drag it onto the form to add a bound input element to the form. If you prefer not to have a Label added at the same time, deselect the "Add Label" checkbox.

The numbers in square brackets [] next to each property indicate the total amount of bound controls that have been added to the form for this property.

Note: The assignment of data types to controls can be customized through the program options.


Form Designer: Clipboard and Clipcontainer

Clipboard and Clipcontainer

Note: additional information on the subject contained here can be obtained from an instructional video clip [image] at the form.suite4.net web site.

Clipboard and Clipcontainer are repositories for controls and control groups that need to be used again later. Both support drag and drop and visually display their content so you can easily pick the elements you are looking for.

Clipboard: use CTRL+X (cut) or CTRL+C (copy) to place any form element in the Clipboard. Retrieve the content by dragging it onto a form or another control in the Form Designer window.
Note: as soon as you copy or cut another element to the Clipboard, any existing content will be overwritten.

Clipcontainer: if you want to keep a control or group of controls available across several cut and copy operations or even several editing sessions, drag them from the Form Designer window to the Clipcontainer. Its content is stored along with the current user's settings and will be available any time you open the program (this feature can be disabled in the program options if required). Retrieving the Clipcontainer's content is done by dragging the desired element or elements onto the form. Should you not need Clipcontainer items anymore, select them and press the DEL key. This removes them permanently.


Form Designer: Style Sheets

Style Sheets

Note: additional information on the subject contained here can be obtained from an instructional video clip [image] at the form.suite4.net web site.

form.suite4.net provides a unique mechanism for consistent layout across forms in a project — or even several projects. Similar in functionality to Cascading Style Sheets (CSS) on the web, form.suite4.net style sheets act as a container for layout information that can be applied many times over. There are two basic ways of using style sheets that work hand in hand. These are described below.

Creating and editing style sheets via the program options

  1. Access the program options using Tools > Options > Designer > Stylesheet.
  2. Select the default stylesheet and click on "Copy".
  3. Rename the new stylesheet and click on "Edit". The dialog for editing style sheets appears.
  4. Select any control in the list box (1) and edit its properties to your liking in the property grid (2). A preview (3) will help you to determine what the control will look like eventually.
  5. Repeat step 4 for all the controls you wish to edit. Confirm your changes with a click on "OK".
  6. The Form Designer now has an additional item in the style sheets drop-down list of the toolbar.
  7. To apply the formatting instructions of your newly created style sheet to controls on your form:
    1. Select your style sheet in the drop-down list.
    2. Select any number of controls on your form you wish to apply the styles to.
    3. Click the "Apply Stylesheet" button to the right of the style sheet drop-down list. The formatting instructions you specified in steps 4 and 5 above are applied to the selected control(s).

Editing style sheets on the fly

In addition to the options you have for editing style sheets as described above, you can also edit style instructions for a particular control type on the fly while working in the designer.

  1. Select the control and — if necessary — perform any edits you see fit using the Property Grid or the QuickProperties Editor.
  2. To copy the formatting instructions of this control to a style sheet, do the following:
    1. Select the target style sheet from the style sheets drop-down list in the toolbar. This needs to be one of your custom stylesheets as the default stylesheet that comes preinstalled with the program can not be edited.
    2. Click the "Copy to Stylesheet" button next to the drop-down list. The formatting instructions of the control you selected in step 1 are stored in the specified style sheet and can subsequently be applied to all controls of the same type using the "Apply Stylesheet" button as described earlier.


Program Options

The program options can be accessed from both the Form Manager and the Form Designer by choosing Tools > Options from the main menu.

They are arranged in two distinct areas, Common (1) and Designer (2). You can find more information about the possible settings of each in the following sections:

  • Program Options: Common
  • Program Options: Designer


Program Options: Common

This section contains settings in regards to generation of source code using form.suite4.net.

It is subdivided in the following areas:

  • Code Generation
  • Code View

Code Generation

Code Generation Options

  • Generate Visual Studio compatible code?
    The difference between the two possible states lies primarily in the way events are treated in the generated code. This is best explainend using sample code:
    The scenario is a simple form with one button on it that has a Click event attached to it. The following code is generated when the checkbox is activated:
    using System;
using System.Windows.Forms;
public class Form1 : System.Windows.Forms.Form
{
    private System.Windows.Forms.Button cmdButton1;

    public Form1()
    {
        this.InitializeComponent();
    }

    private void InitializeComponent()
    {
        this.cmdButton1 = new System.Windows.Forms.Button();
        this.SuspendLayout();
        this.cmdButton1.Location = new System.Drawing.Point(8, 8);
        this.cmdButton1.Name = "cmdButton1";
        this.cmdButton1.Size = new System.Drawing.Size(75, 23);
        this.cmdButton1.TabIndex = 0;
        this.cmdButton1.Text = "cmdButton1";
        this.cmdButton1.Click += new System.EventHandler(this.cmdButton1_Click);
        this.AutoScaleBaseSize = new System.Drawing.Size(5, 13);
        this.ClientSize = new System.Drawing.Size(292, 266);
        this.Controls.Add(this.cmdButton1);
        this.Name = "Form1";
        this.Text = "Form1";
        this.ResumeLayout(false);
    }

    private void cmdButton1_Click(object sender, System.EventArgs e) {

    }
}
    The event handler is registered in the InitializeComponent method of the form just as it would in Visual Studio .NET. Now compare this to the code output when the checkbox is not checked:
    using System;
using System.Windows.Forms;
public class Form1 : System.Windows.Forms.Form
{
    private System.Windows.Forms.Button cmdButton1;

    public Form1()
    {
        this.InitializeComponent();
        this.InitializeEvents();
    }

    private void InitializeComponent()
    {
        this.cmdButton1 = new System.Windows.Forms.Button();
        this.SuspendLayout();
        this.cmdButton1.Location = new System.Drawing.Point(72, 48);
        this.cmdButton1.Name = "cmdButton1";
        this.cmdButton1.Size = new System.Drawing.Size(75, 23);
        this.cmdButton1.TabIndex = 0;
        this.cmdButton1.Text = "cmdButton1";
        this.AutoScaleBaseSize = new System.Drawing.Size(5, 13);
        this.ClientSize = new System.Drawing.Size(292, 266);
        this.Controls.Add(this.cmdButton1);
        this.Name = "Form1";
        this.Text = "Form1";
        this.ResumeLayout(false);
    }

    private void InitializeEvents()
    {
        this.cmdButton1.Click += new System.EventHandler(this.cmdButton1_Click);
    }

    private void cmdButton1_Click(object sender, System.EventArgs e)
    {
    }
}
    As you can see, an additional method InitializeEvents is created which registers the event handler for the Click event of cmdButton1 (and, of course, any event handlers of other controls). The advantage of this approach over the one shown earlier is that you can edit all event handler registrations in one location rather than having to search for them in InitializeComponent.
  • Would you like extended comments for each form?
    If this checkbox is activated and you have been assigning tasks and/or descriptions to controls during the design process using the Task/Description Editor, these get added to the generated code.

Back to top

Data Binding / Data Initialization Options

The settings available here apply to binding business classes to forms as described in Working With Business Classes.

  • Name for the Dirty Property
    When a user changes any of the business class property values, the form is set to dirty. The value you enter here determines the name of the form's property that indicates whether it is dirty or not.
  • Name for the Make Dirty Event
    An event gets raised once the form becomes dirty. Here you can customize its name.
  • Name for the Data Initialization Method
    The data initialization method referred to here is where the form controls get bound to the data source (business object). Depending on the type of data binding you are using (see Working With Business Classes for more information on the two common data binding scenarios) the code generation engine will produce code for the data initialization method that looks similar to the following:
    public void InitializeDataSource(assetm.Northwind.EmployeesRow employeesRowdata)
{
    this.SuspendLayout();
    this.Save();
    this._IsInitializing = true;
    this.Reset();
    this._EmployeesRowdata = employeesRowdata;
    if((this._EmployeesRowdata != null))
    {
        this.txtTitleOfCourtesy.Text = this._EmployeesRowdata.TitleOfCourtesy;
        this.txtTitle.Text = this._EmployeesRowdata.Title;
        this.txtCountry.Text = this._EmployeesRowdata.Country;
        this.txtRegion.Text = this._EmployeesRowdata.Region;
        this.txtPostalCode.Text = this._EmployeesRowdata.PostalCode;
        this.txtCity.Text = this._EmployeesRowdata.City;
        this.txtStreet.Text = this._EmployeesRowdata.Address;
        this.txtFirstName.Text = this._EmployeesRowdata.FirstName;
        this.txtLastName.Text = this._EmployeesRowdata.LastName;
    }
    this.ResumeLayout(false);
    this._IsInitializing = false;
    this._IsDirty = false;
}
    If you want to omit the call to the method that saves any changes to the business object (marked blue in the code snippet above) deactivate the checkbox next to Save before new Initialize new Datasource.
  • DataSource Extension
    The value you enter here will be appended to the variable name of your business object — providing the checkbox Use as suffix is activated.
  • Name for the Save Data Method
    This sets the name of the method that saves the form control values back to the business object.
  • Name for the Reset Data Method
    This method empties all the controls on the form. Call it if you want to allow the user to create a new record. Set the method's name by entering a value here.
  • Use System.Convert
    This setting is used in the method that is storing control values back to the business object (see Name for the Save Data Method above). If you have a business object with a property type that is different from the type of the corresponding control value, a type conversion needs to be performed in order to write the value to the business object property.
    Example: a TextBox control txtCustomerAge stores the value of the myCustomer.Age business object property which is of type System.Int32. If the Use System.Convert checkbox is not selected, the generated code will be
    myCustomer.Age = int.Parse(txtCustomerAge.Text ); in C# and
    myCustomer.Age = Integer.Parse(txtCustomerAge.Text) in Visual Basic .NET.
    Selecting the checkbox, however, results in the following code:
     myCustomer.Age = System.Convert.ToInt32(txtCustomerAge.Text); in C# and
    myCustomer.Age = System.Convert.ToInt32(txtCustomerAge.Text) in VB .NET respectively.

Back to top

Code View

Check the following if you want the text used as a comment during code generation

In this section you can further customize the generated code, although the changes you make here will not affect the code's functionality. The settings provided are merely intended to organize the code. If you select any of the checkboxes below the "Toggle all" button, the code output will contain additional comments such as //end try ( C#) or 'End try ( Visual Basic .NET) after a try/catch block is complete. This is a convenience feature mainly targeted at C# programmers to increase code readablility.

Activating the Add regions to type level code objects checkbox will add #region/#endregion (C#) or #Region/#End Region (VB.NET) preprocessor directives to the code output, as illustrated by the following excerpt from the InitializeComponent method of a sample form:

#region txtCountry
this.txtCountry.BackColor = System.Drawing.Color.FromArgb(((System.Byte)(255)), ((System.Byte)(255)), ((System.Byte)(192)));
this.txtCountry.ForeColor = System.Drawing.Color.Black;
this.txtCountry.Location = new System.Drawing.Point(80, 114);
this.txtCountry.Name = "txtCountry";
this.txtCountry.Size = new System.Drawing.Size(160, 20);
this.txtCountry.TabIndex = 22;
this.txtCountry.Text = "Country";
#endregion

The initialization of the TextBox txtCountry is wrapped in a region, as are the initializations of all other controls (not shown here).

Back to top

Color settings for code viewing

The settings here apply to the code generation preview window (which is available through the Form Designer's main menu) and are self-explanatory. Change the color of various code elements as you see fit or accept the defaults.

Back to top


Program Options: Form Designer

The settings available in this section apply to the Form Designer and its various features.

They are subdivided as follows:

  • Common
  • Appearance
  • Style Sheets
  • Controls
  • Data Types

Common

Edit Options

If you are using the Clipboard to copy and paste controls you can specify where the controls should be positioned after a paste command. Select Absolutely if the should have the same coordinates as the original control, or specify an offset that suits your needs.

Back to top

Property Options

This setting applies to the Property Grid. Activating it will provide you with a small editor window for text properties. The window is very helpful for editing longer texts, such as error messages.

Back to top

Control Edit Options

Activating this setting will allow the program to automatically assign a name to a checkbox based on the value entered in its "Text" property. This works in both the Property Grid and the QuickProperties Editor. You can specify the maximum length of the text to be used for the name; any characters exceeding this value will be truncated. A configurable prefix will be added at the beginning of the name.

Back to top

Clipboard and Clipcontainer Options

Specify whether you want the Clipcontainer contents available across program starts. If deactivated, the content of the Clipcontainer will be deleted when you close the program.

Back to top

Appearance

Appearance Options

Here you can customize the Form Design Area . Change the size of the grid and enable or disable grid features or the ruler.

Back to top

Design Explorer Options

The Design Explorer displays its information in a tree-structure. These settings allow you to customize its behavior. Auto-Collapse will close any open tree nodes as soon as you open a new one, whereas Auto-Expand automatically opens any available child-nodes once you select a parent node with the mouse.

Back to top

Style Sheets

This section lists the application's default style sheet and all the style sheets you have created yourself. All of the style sheet information is stored in an XML file. If you wish you can browse to and select a different file using the button next to the Style sheet layout file text box.
Further information on how to create and configure style sheets can be found in Creating and editing style sheets via the program options in the Form Designer help.

Back to top

Controls

Preset

In this section you can specify a number of data binding-related settings for each of the Windows Forms controls. Activate a control in the pane on the left and view or edit its corresponding properties in the textbox and drop-down lists on the right.

The value entered in the Control Name Prefix field determines the prefix appended to a control when it is bound to a business class property. Thus, a TextBox control bound to the FirstName property of a Customer class would be set to <prefix>FirstName, where <prefix> is the value you specified.

The Binding Property drop-down list holds all the bindable properties of the control that is selected in the pane on the left. Pick the one you want the business class property to be assigned to.

Handling of Form Changes lists all the events a control can raise. Choose the event you want to employ for setting the form to dirty.

Back to top

Change To

The Forms Designer provides a convenient method to switch between control types as described in Form Design Area.

Select any control in the list on the left and mark the desired alternatives in the list on the right. Clicking on "Show selected only" will display only the controls you have selected.

Back to top

Data Types

The Form Designer contains a group in the Toolbox called Business Class. It displays the properties of a business class along with a proposed set of control types each property can be bound to. The program provides alternative control types to the default and allows you to change the way a business class property is represented by simply dragging the alternative control onto the form you are working on. You can control the specifics of this behavior by making any necessary adjustments in this section.

Select any of the intrinsic .NET Framework datatypes in the list on the left and choose one or more controls from the list on the right to represent this type visually. Click on "Show selected only" to display only the controls you have selected and hide all others.

Back to top


suite4.net.FormDatabase

suite4.net.FormDatabase Documentation

suite4.net.FormDatabase Namespace

The elements of this namespace are used to dynamically load and manipulate form.suite4.net Forms and Controls in Windows Forms and Web Forms contexts.

The LoaderControl and the LoaderForm can be used in a Windows application to display controls that were created with the form.suite4.net application. Both load the controls dynamically from an IForm layout.

The IForm interface provides methods that allow the caller to serialize the IForm instance and its associated business class to XML. The XML is processed by a dedicated Web form loader component (in Macromedia Flash format) to display a form or control on a Web page.

Both the Windows Forms and Web Form elements are capable of receiving user input at runtime and forward updates to a back-end datastore.

A key concept to understand when working with the classes in this namespace is that there is no distinction between a Form or UserControl -- both are represented by the IForm interface.

The Project class provides access to the elements of a form.suite4.net project, such as IForm, IGroup and ITask, all of which represent items that have been configured initially using the form.suite4.net application.

Namespace hierarchy

Classes

Class | Description
DataSourceException | Represents non-fatal errors that occur during the interaction of a LoaderControl or LoaderForm with the data source of an IForm.
LoaderControl | The LoaderControl is a container which an IForm can be loaded into for display in a Windows Forms application.
LoaderException | Represents non-fatal errors that occur during the process of loading an IForm into a LoaderControl or LoaderForm.
LoaderForm | The LoaderForm is used to load an IForm and display it in a Windows Application.
Project | Use this class to load a form.suite4.net IProject. Once you have a reference to the IProject you can access all its elements such as IForm or ITask.
ValidationEventArgs | ValidationEventArgs provides data for the ValidationEventHandler.
WebLoaderAlert | Represents an alert box that gets displayed in the WebLoader component.

Interfaces

Interface | Description
IForm | Represents an IForm object which is contained in an IFormCollection.
IFormCollection | Represents a collection of IForm objects.
IGroup | Represents a Group (a logical container for Forms, UserControls and Reports in a project) which is itself an element of an IGroupCollection.
IGroupCollection | Represents a collection of IGroup objects.
IProject | The main interface of the form.suite4.net FormDatabase. It represents a form.suite4.net project along with its constituent elements, such as forms, tasks and groups.
ITask | Represents a task object which is contained in an ITaskCollection.
ITaskCollection | Represents a collection of ITask objects.
IWebLoaderEvent | Represents an event that can be raised by a control on an IForm that has been loaded into a web page using the WebLoader component.
IWebLoaderEventParameter | Represents a parameter for the IWebLoaderEvent.

Delegates

Delegate | Description
ValidationEventHandler | Represents the method that will handle the event that when the Validation of a data source (business object) property faild.

Enumerations

Enumeration | Description
AssignedTo | Specifies values representing who a specific ITask has been assigned to.
FormSortProperty | Enumeration specifying the IForm property by which an IFormCollection is to be sorted.
FormType | Specifies the different IForm types supported by form.suite4.net.
GroupSortProperty | Enumeration specifying the IGroup property by which an IGroupCollection is to be sorted.
Priority | Specifies values representing the priority of the ITask
TaskSortProperty | Enumeration specifying the ITask property by which an ITaskCollection is to be sorted.
TaskType | Specifies values representing the type of task used in the ITask and ITaskCollection interfaces.
WebLoaderEventType | Specifies the different types of external methods that can be called from the IWebLoaderEvent interface.
WebLoaderParameterType | Specifies the different types of parameters available for use with the IWebLoaderEvent. These parameters get passed to the method specified in the Operation property.

Send comments on this topic.

Copyright © 1998-2005 asset.management gmbh


AssignedTo Enumeration

Specifies values representing who a specific ITask has been assigned to.

[Visual Basic]
Public Enum AssignedTo
[C#]
public enum AssignedTo

Members

Member Name | Description
Customer | The ITask is assigned to a customer.
Designer | The ITask is assigned to a designer.
Developer | The ITask is assigned to a Developer.

Requirements

Namespace: suite4.net.FormDatabase

Assembly: suite4.net.FormDatabase (in suite4.net.FormDatabase.dll)

See Also

suite4.net.FormDatabase Namespace

Send comments on this topic.

Copyright © 1998-2005 asset.management gmbh

Generated from assembly suite4.net.FormDatabase [1.5.0.2910]


DataSourceException Class

Represents non-fatal errors that occur during the interaction of a LoaderControl or LoaderForm with the data source of an IForm.

For a list of all members of this type, see DataSourceException Members.

System.Object
System.Exception
System.ApplicationException
suite4.net.FormDatabase.DataSourceException

[Visual Basic]
Public Class DataSourceException
Inherits ApplicationException
[C#]
public class DataSourceException : ApplicationException

Thread Safety

Public static (Shared in Visual Basic) members of this type are safe for multithreaded operations. Instance members are not guaranteed to be thread-safe.

Remarks

This exception is raised when a LoaderControl or LoaderForm encounters errors while interacting with properties of the data source (business class) object. Specifically:

  • when the LoaderControl/LoaderForm tries to assign a specified data source property value to the control property, or
  • when the LoaderControl/LoaderForm tries to save a control property value to a corresponding data source property.

Requirements

Namespace: suite4.net.FormDatabase

Assembly: suite4.net.FormDatabase (in suite4.net.FormDatabase.dll)

See Also

DataSourceException Members | suite4.net.FormDatabase Namespace


DataSourceException Members

DataSourceException overview

Public Instance Properties

DataSource | Gets a reference to the data source (business class) object that failed to initialize.
HelpLink (inherited from Exception) |
InnerException (inherited from Exception) |
Message (inherited from Exception) |
PropertyName | Gets the name of the property that couldn't be set.
Source (inherited from Exception) |
StackTrace (inherited from Exception) |
TargetSite (inherited from Exception) |

Public Instance Methods

Equals (inherited from Object)
GetBaseException (inherited from Exception)
GetHashCode (inherited from Object)
GetObjectData (inherited from Exception)
GetType (inherited from Object)
ToString (inherited from Exception)

See Also

DataSourceException Class | suite4.net.FormDatabase Namespace


DataSourceException Properties

The properties of the DataSourceException class are listed below. For a complete list of DataSourceException class members, see the DataSourceException Members topic.

Public Instance Properties

DataSource | Gets a reference to the data source (business class) object that failed to initialize.
HelpLink (inherited from Exception) |
InnerException (inherited from Exception) |
Message (inherited from Exception) |
PropertyName | Gets the name of the property that couldn't be set.
Source (inherited from Exception) |
StackTrace (inherited from Exception) |
TargetSite (inherited from Exception) |

See Also

DataSourceException Class | suite4.net.FormDatabase Namespace


DataSource Property

suite4.net.FormDatabase Documentation

DataSourceException.DataSource Property

Gets a reference to the data source (business class) object that failed to initialize.

[Visual Basic]
Public ReadOnly Property DataSource As Object
[C#]
public object DataSource {get;}

Property Value

The reference to the data source (business class) object.

See Also

DataSourceException Class | suite4.net.FormDatabase Namespace


PropertyName Property

suite4.net.FormDatabase Documentation

DataSourceException.PropertyName Property

Gets the name of the property that couldn't be set.

[Visual Basic]
Public ReadOnly Property PropertyName As String
[C#]
public string PropertyName {get;}

Property Value

The name of the property or NULL (Nothing in Visual Basic) if a general LoaderControl/LoaderForm error occurs.

See Also

DataSourceException Class | suite4.net.FormDatabase Namespace


FormSortProperty Enumeration

Enumeration specifying the IForm property by which an IFormCollection is to be sorted.

[Visual Basic]
Public Enum FormSortProperty
[C#]
public enum FormSortProperty

Remarks

The enumeration defaults to Name.

Members

Member Name | Description
Name | The IFormCollection will be sorted by the Name.

Requirements

Namespace: suite4.net.FormDatabase

Assembly: suite4.net.FormDatabase (in suite4.net.FormDatabase.dll)

See Also

suite4.net.FormDatabase Namespace


FormType Enumeration

Specifies the different IForm types supported by form.suite4.net.

[Visual Basic]
Public Enum FormType
[C#]
public enum FormType

Members

Member Name | Description
Form | The IForm is a Windows Form or an ASP.NET Page.
UserControl | The IForm is a Windows Forms UserControl or an ASP.NET UserControl.

Requirements

Namespace: suite4.net.FormDatabase

Assembly: suite4.net.FormDatabase (in suite4.net.FormDatabase.dll)

See Also

suite4.net.FormDatabase Namespace


GroupSortProperty Enumeration

Enumeration specifying the IGroup property by which an IGroupCollection is to be sorted.

[Visual Basic]
Public Enum GroupSortProperty
[C#]
public enum GroupSortProperty

Remarks

The enumeration defaults to Name.

Members

Member Name | Description
Name | The IGroupCollection will be sorted by the Name.

Requirements

Namespace: suite4.net.FormDatabase

Assembly: suite4.net.FormDatabase (in suite4.net.FormDatabase.dll)

See Also

suite4.net.FormDatabase Namespace


IForm Interface

Represents an IForm object which is contained in an IFormCollection.

For a list of all members of this type, see IForm Members.

[Visual Basic]
Public Interface IForm
[C#]
public interface IForm

Requirements

Namespace: suite4.net.FormDatabase

Assembly: suite4.net.FormDatabase (in suite4.net.FormDatabase.dll)

See Also

IForm Members | suite4.net.FormDatabase Namespace


IForm Members

IForm overview

Public Instance Properties

ChildForms | Gets an IFormCollection containing all IForm objects derived from this form.
DataSourceType | Gets the Type of the data source assigned to the IForm.
DataUniqueID | Gets or sets a string the WebLoader uses to uniquely indentify a data source (business class) instance.
Description | Gets the description of the IForm object.
FormType | Gets the FormType of the IForm.
FullName | Gets the full name of the IForm.
Image | Gets an automatically created Image representation of the IForm.
Language | Gets the language that is selected in the form.suite4.net Form Manager for the IForm.
LastModification | Gets a timestamp of the last modification performed on the IForm.
Name | Gets the name of the IForm.
Namespace | Gets the namespace of the IForm.
Next | Gets the next IForm in the IFormCollection.
PreserveFormatting | Gets or sets a value indicating whether the formatting of all controls on the IForm should be preserved when the IForm is displayed using the WebLoader.
Prev | Gets the previous IForm in the IFormCollection.
Resolution | Gets the namespace of the IForm.
Size | Gets the Size of the IForm.
Tasks | Gets the tasks associated with this IForm.
UseDataBinding | Gets a value indicating whether data binding should be used with this IForm.
UserGroup | Gets the UserGroup of the IForm.
WebBackColor | Gets or sets the Color value that will be used in the WebLoader component.
WebLoaderEvent | Gets a IWebLoaderEvent value for use in the WebLoader component.
WebServicePassword | Gets or sets a password used in accessing an XML web service using the WebLoader component.

Public Instance Methods

DeserializeDataSourceFromSwfXml | Deserializes a business object from an XML string. The method takes an existing business object instance and an XML string and updates the business object with the values stored in the XML string.
SerializeDataSourceToSwfXml | Serializes a business object instance to an XML string. The XML is processed by the WebLoader component to display the business object's values in a Macromedia Flash form.
SerializeToSwfXml | Overloaded. Serializes the current IForm, an instance of a business object and a WebLoaderAlert to an XML string. The XML is processed by the WebLoader component to dynamically draw a form and display the business object's values in a Macromedia Flash form.
SetComponentValue | Sets the value of a designated property of a component contained in the IForm.

See Also

IForm Interface | suite4.net.FormDatabase Namespace


IForm Properties

The properties of the IForm interface are listed below. For a complete list of IForm interface members, see the IForm Members topic.

Public Instance Properties

ChildForms | Gets an IFormCollection containing all IForm objects derived from this form.
DataSourceType | Gets the Type of the data source assigned to the IForm.
DataUniqueID | Gets or sets a string the WebLoader uses to uniquely indentify a data source (business class) instance.
Description | Gets the description of the IForm object.
FormType | Gets the FormType of the IForm.
FullName | Gets the full name of the IForm.
Image | Gets an automatically created Image representation of the IForm.
Language | Gets the language that is selected in the form.suite4.net Form Manager for the IForm.
LastModification | Gets a timestamp of the last modification performed on the IForm.
Name | Gets the name of the IForm.
Namespace | Gets the namespace of the IForm.
Next | Gets the next IForm in the IFormCollection.
PreserveFormatting | Gets or sets a value indicating whether the formatting of all controls on the IForm should be preserved when the IForm is displayed using the WebLoader.
Prev | Gets the previous IForm in the IFormCollection.
Resolution | Gets the namespace of the IForm.
Size | Gets the Size of the IForm.
Tasks | Gets the tasks associated with this IForm.
UseDataBinding | Gets a value indicating whether data binding should be used with this IForm.
UserGroup | Gets the UserGroup of the IForm.
WebBackColor | Gets or sets the Color value that will be used in the WebLoader component.
WebLoaderEvent | Gets a IWebLoaderEvent value for use in the WebLoader component.
WebServicePassword | Gets or sets a password used in accessing an XML web service using the WebLoader component.

See Also

IForm Interface | suite4.net.FormDatabase Namespace


ChildForms Property

suite4.net.FormDatabase Documentation

IForm.ChildForms Property

Gets an IFormCollection containing all IForm objects derived from this form.

[Visual Basic]
Property ChildForms As IFormCollection
[C#]
IFormCollection ChildForms {get;}

Property Value

An IFormCollection containing the child forms of this IForm.

See Also

IForm Interface | suite4.net.FormDatabase Namespace


WebLoaderEvent Property

suite4.net.FormDatabase Documentation

IForm.WebLoaderEvent Property

Gets a IWebLoaderEvent value for use in the WebLoader component.

[Visual Basic]
Property WebLoaderEvent As IWebLoaderEvent
[C#]
IWebLoaderEvent WebLoaderEvent {get;}

Property Value

An IWebLoaderEvent.

Remarks

This property is only used with the WebLoader. If an external JavaScript function assigns a new value to DataUniqueID, the WebLoader calls the specified web service to retrieve the data source (business class) values corresponding to the DataUniqueID value.

Example

The following example demonstrates how to serialize an IForm and assign a DataUniqueID.

C# sample

using System;
using suite4.net.FormDatabase;
using suite4.net.Sample;
namespace suite4.net.Web.Sample
{
    public class FormServer : System.Web.Services.WebService
    {
        [System.Web.Services.WebMethod]
        public string SerializeForm(string formName)
        {
            string                    projectFileName;
            Employee                employee;
            IForm                        form;
            IProject                project;
            WebLoaderAlert    webLoaderAlert;

            projectFileName = this.Server.MapPath("\\sample") + "\\sample.fspj";
            project = Project.LoadFromFile(projectFileName);
            if(project != null)
            {
                form = project.GetForm(formName);
                if(form != null)
                {
                    employee = new Employee();
                    employee.EmployeeID    = 1;
                    employee.LastName        = "Robert";
                    employee.LastName        = "King";
                    form.DataUniqueID        = employee.EmployeeID.ToString();
                    form.WebLoaderEvent.WsdlUrl        = "/FormServer/FormServer.asmx?wsdl";
                    form.WebLoaderEvent.Operation    = "GetEmployee";
                    form.WebLoaderEvent.ClearParameters();
                    form.WebLoaderEvent.AddParameter(WebLoaderParameterType.FormDatabase);
                    form.WebLoaderEvent.AddParameter(WebLoaderParameterType.FormName);
                    form.WebLoaderEvent.AddParameter(WebLoaderParameterType.DataUniqueID);
                    return form.SerializeToSwfXml(employee);
                }
                else
                {
                    webLoaderAlert = new WebLoaderAlert();
                    webLoaderAlert.Title = "Failed to load form";
                    webLoaderAlert.Message = "Can't find form " + formName;
                    return webLoaderAlert.SerializeToSwfXml();
                }
            }
            else
            {
                webLoaderAlert = new WebLoaderAlert();
                webLoaderAlert.Title = "Failed to load project";
                webLoaderAlert.Message = "Can't find project\n" + projectFileName;
                return webLoaderAlert.SerializeToSwfXml();
            }
        }
    }
}

VB.Net sample
Imports System
Imports suite4.net.FormDatabase
Imports suite4.net.Sample
Namespace suite4.net.Web.Sample
    Public Class FormServer
     Inherits System.Web.Services.WebService
        <System.Web.Services.WebMethod> _
        Public Function SerializeForm(ByVal formName As String) As String
            Dim projectFileName As String
            Dim employee As Employee
            Dim form As IForm
            Dim project As IProject
            Dim webLoaderAlert As WebLoaderAlert

            projectFileName = Me.Server.MapPath("\\sample") + "\\sample.fspj"
            project = Project.LoadFromFile(projectFileName)
            If Not project Is Nothing Then
                form = project.GetForm(formName)
                If Not form Is Nothing Then
                    employee = New Employee()
                    employee.EmployeeID    = 1
                    employee.LastName        = "Robert"
                    employee.LastName        = "King"
                    form.DataUniqueID        = employee.EmployeeID.ToString()
                    form.WebLoaderEvent.WsdlUrl        = "/FormServer/FormServer.asmx?wsdl"
                    form.WebLoaderEvent.Operation    = "GetEmployee"
                    form.WebLoaderEvent.ClearParameters()
                    form.WebLoaderEvent.AddParameter(WebLoaderParameterType.FormDatabase)
                    form.WebLoaderEvent.AddParameter(WebLoaderParameterType.FormName)
                    form.WebLoaderEvent.AddParameter(WebLoaderParameterType.DataUniqueID)
                    Return form.SerializeToSwfXml(employee)
                Else
                    webLoaderAlert = New WebLoaderAlert()
                    webLoaderAlert.Title = "Failed to load form"
                    webLoaderAlert.Message = "Can't find form " + formName
                    Return webLoaderAlert.SerializeToSwfXml()
                End If
            Else
                webLoaderAlert = New WebLoaderAlert()
                webLoaderAlert.Title = "Failed to load project"
                webLoaderAlert.Message = "Can't find project\n" + projectFileName
                Return webLoaderAlert.SerializeToSwfXml()
            End If
        End Function
    End Class
End Namespace

See Also

IForm Interface | suite4.net.FormDatabase Namespace


DataSourceType Property

suite4.net.FormDatabase Documentation

IForm.DataSourceType Property

Gets the Type of the data source assigned to the IForm.

[Visual Basic]
Property DataSourceType As Type
[C#]
System.Type DataSourceType {get;}

Property Value

The Type of the form's data source.

See Also

IForm Interface | suite4.net.FormDatabase Namespace


DataUniqueID Property

suite4.net.FormDatabase Documentation

IForm.DataUniqueID Property

Gets or sets a string the WebLoader uses to uniquely indentify a data source (business class) instance.

[Visual Basic]
Property DataUniqueID As String
[C#]
string DataUniqueID {get; set;}

Property Value

The unique identifier, or an empty string when none has been assigned.

Remarks

The DataUniqueID can be used as a parameter of an IWebLoaderEvent.

Example

The following example demonstrates how to serialize an IForm and assign a DataUniqueID.

C# sample

using System;
using suite4.net.FormDatabase;
using suite4.net.Sample;
namespace suite4.net.Web.Sample
{
    public class FormServer : System.Web.Services.WebService
    {
        [System.Web.Services.WebMethod]
        public string SerializeForm(string formName)
        {
            string                    projectFileName;
            Employee                employee;
            IForm                        form;
            IProject                project;
            WebLoaderAlert    webLoaderAlert;

            projectFileName = this.Server.MapPath("\\sample") + "\\sample.fspj";
            project = Project.LoadFromFile(projectFileName);
            if(project != null)
            {
                form = project.GetForm(formName);
                if(form != null)
                {
                    employee = new Employee();
                    employee.EmployeeID    = 1;
                    employee.LastName        = "Robert";
                    employee.LastName        = "King";
                    form.DataUniqueID        = employee.EmployeeID.ToString();
                    form.WebLoaderEvent.WsdlUrl        = "/FormServer/FormServer.asmx?wsdl";
                    form.WebLoaderEvent.Operation    = "GetEmployee";
                    form.WebLoaderEvent.ClearParameters();
                    form.WebLoaderEvent.AddParameter(WebLoaderParameterType.FormDatabase);
                    form.WebLoaderEvent.AddParameter(WebLoaderParameterType.FormName);
                    form.WebLoaderEvent.AddParameter(WebLoaderParameterType.DataUniqueID);
                    return form.SerializeToSwfXml(employee);
                }
                else
                {
                    webLoaderAlert = new WebLoaderAlert();
                    webLoaderAlert.Title = "Failed to load form";
                    webLoaderAlert.Message = "Can't find form " + formName;
                    return webLoaderAlert.SerializeToSwfXml();
                }
            }
            else
            {
                webLoaderAlert = new WebLoaderAlert();
                webLoaderAlert.Title = "Failed to load project";
                webLoaderAlert.Message = "Can't find project\n" + projectFileName;
                return webLoaderAlert.SerializeToSwfXml();
            }
        }
    }
}

VB.Net sample
Imports System
Imports suite4.net.FormDatabase
Imports suite4.net.Sample
Namespace suite4.net.Web.Sample
    Public Class FormServer
     Inherits System.Web.Services.WebService
        <System.Web.Services.WebMethod> _
        Public Function SerializeForm(ByVal formName As String) As String
            Dim projectFileName As String
            Dim employee As Employee
            Dim form As IForm
            Dim project As IProject
            Dim webLoaderAlert As WebLoaderAlert

            projectFileName = Me.Server.MapPath("\\sample") + "\\sample.fspj"
            project = Project.LoadFromFile(projectFileName)
            If Not project Is Nothing Then
                form = project.GetForm(formName)
                If Not form Is Nothing Then
                    employee = New Employee()
                    employee.EmployeeID    = 1
                    employee.LastName        = "Robert"
                    employee.LastName        = "King"
                    form.DataUniqueID        = employee.EmployeeID.ToString()
                    form.WebLoaderEvent.WsdlUrl        = "/FormServer/FormServer.asmx?wsdl"
                    form.WebLoaderEvent.Operation    = "GetEmployee"
                    form.WebLoaderEvent.ClearParameters()
                    form.WebLoaderEvent.AddParameter(WebLoaderParameterType.FormDatabase)
                    form.WebLoaderEvent.AddParameter(WebLoaderParameterType.FormName)
                    form.WebLoaderEvent.AddParameter(WebLoaderParameterType.DataUniqueID)
                    Return form.SerializeToSwfXml(employee)
                Else
                    webLoaderAlert = New WebLoaderAlert()
                    webLoaderAlert.Title = "Failed to load form"
                    webLoaderAlert.Message = "Can't find form " + formName
                    Return webLoaderAlert.SerializeToSwfXml()
                End If
            Else
                webLoaderAlert = New WebLoaderAlert()
                webLoaderAlert.Title = "Failed to load project"
                webLoaderAlert.Message = "Can't find project\n" + projectFileName
                Return webLoaderAlert.SerializeToSwfXml()
            End If
        End Function
    End Class
End Namespace

See Also

IForm Interface | suite4.net.FormDatabase Namespace


Description Property

suite4.net.FormDatabase Documentation

IForm.Description Property

Gets the description of the IForm object.

[Visual Basic]
Property Description As String
[C#]
string Description {get;}

Property Value

The description, or an empty String when none has been assigned.

See Also

IForm Interface | suite4.net.FormDatabase Namespace


FormType Property

suite4.net.FormDatabase Documentation

IForm.FormType Property

Gets the FormType of the IForm.

[Visual Basic]
Property FormType As FormType
[C#]
FormType FormType {get;}

Property Value

The FormType of the IForm.

See Also

IForm Interface | suite4.net.FormDatabase Namespace


FullName Property

suite4.net.FormDatabase Documentation

IForm.FullName Property

Gets the full name of the IForm.

[Visual Basic]
Property FullName As String
[C#]
string FullName {get;}

Property Value

The full name of the IForm, consisting of the Namespace and the Name.

See Also

IForm Interface | suite4.net.FormDatabase Namespace


Image Property

suite4.net.FormDatabase Documentation

IForm.Image Property

Gets an automatically created Image representation of the IForm.

[Visual Basic]
Property Image As Image
[C#]
System.Drawing.Image Image {get;}

Property Value

An Image of the IForm layout.

Remarks

The image can't be created when using the FormDatabase in an XML web service context.

See Also

IForm Interface | suite4.net.FormDatabase Namespace


Language Property

suite4.net.FormDatabase Documentation

IForm.Language Property

Gets the language that is selected in the form.suite4.net Form Manager for the IForm.

[Visual Basic]
Property Language As String
[C#]
string Language {get;}

Property Value

The language assigned to the IForm.

Remarks

This property can be used to programmatically filter forms in the application when using the FormDatabase API. The value of this property can only be modified in the form.suite4.net designer.

See Also

IForm Interface | suite4.net.FormDatabase Namespace


LastModification Property

suite4.net.FormDatabase Documentation

IForm.LastModification Property

Gets a timestamp of the last modification performed on the IForm.

[Visual Basic]
Property LastModification As Date
[C#]
System.DateTime LastModification {get;}

Property Value

A DateTime value indicating when the last modification of the form took place.

Remarks

This property is automatically updated by the form.suite4.net designer.

See Also

IForm Interface | suite4.net.FormDatabase Namespace


Name Property

suite4.net.FormDatabase Documentation

IForm.Name Property

Gets the name of the IForm.

[Visual Basic]
Property Name As String
[C#]
string Name {get;}

Property Value

The name of the IForm.

Remarks

The value of this property can only be modified in the form.suite4.net designer.

See Also

IForm Interface | suite4.net.FormDatabase Namespace


Namespace Property

suite4.net.FormDatabase Documentation

IForm.Namespace Property

Gets the namespace of the IForm.

[Visual Basic]
Property Namespace As String
[C#]
string Namespace {get;}

Property Value

The namespace of the IForm.

Remarks

The value of this property can only be modified in the form.suite4.net designer.

See Also

IForm Interface | suite4.net.FormDatabase Namespace


Next Property

suite4.net.FormDatabase Documentation

IForm.Next Property

Gets the next IForm in the IFormCollection.

[Visual Basic]
Property Next As IForm
[C#]
IForm Next {get;}

Property Value

A reference to an IForm object, or NULL (Nothing in Visual Basic) if the IForm is the last element of the IFormCollection.

Example

The following example displays the Name values of all the IForm elements in an IFormCollection.

C# sample

public class Sample
{
    public static void LoadProject()
    {
        suite4.net.FormDatabase.IForm form;
        suite4.net.FormDatabase.IGroup group;
        suite4.net.FormDatabase.IProject project;

        // Load a project from a File
        project = suite4.net.FormDatabase.Project.LoadFromFile(@"C:\sample.fspj");

        // Get the first Group of the Project
        group = project.Groups.First;

        // Get the first Form of the GroupCollection
        form = group.Forms.First;

        while(form != null)
        {
            System.Console.WriteLine("Display the Name of the form...");
            System.Console.WriteLine(form.Name);
            form = form.Next;
        }
    }
}

VB.Net sample
Public Class Sample
    Public Shared Sub LoadProject()
        Dim form As suite4.net.FormDataMyBase.IForm
        Dim group As suite4.net.FormDataMyBase.IGroup
        Dim project As suite4.net.FormDataMyBase.IProject

        ' Load a project from a File
        project = suite4.net.FormDataMyBase.Project.LoadFromFile("C:\sample.fspj")

        ' Get the first Group of the Project
        group = project.Groups.First

        ' Get the first Form of the GroupCollection
        form = group.Forms.First

        While Not form Is Nothing
            System.Console.WriteLine("Display the Name of the form...")
            System.Console.WriteLine(form.Name)
            form = form.Next
        End While
    End Sub
End Class

See Also

IForm Interface | suite4.net.FormDatabase Namespace


PreserveFormatting Property

suite4.net.FormDatabase Documentation

IForm.PreserveFormatting Property

Gets or sets a value indicating whether the formatting of all controls on the IForm should be preserved when the IForm is displayed using the WebLoader.

[Visual Basic]
Property PreserveFormatting As Boolean
[C#]
bool PreserveFormatting {get; set;}

Property Value

A Boolean value indicating whether to preserve all component formatting in the WebLoader. The default value is false.

Remarks

If PreserveFormatting is set to true, control properties such as BackgroundColor or Font are preserved when the IForm is displayed using the WebLoader. If set to false, only a basic set of properties, such as the control's position, size or value is maintained in order to boost Web rendering performance.

For performance reasons it is recommended to set this value to false (default).

See Also

IForm Interface | suite4.net.FormDatabase Namespace


Prev Property

suite4.net.FormDatabase Documentation

IForm.Prev Property

Gets the previous IForm in the IFormCollection.

[Visual Basic]
Property Prev As IForm
[C#]
IForm Prev {get;}

Property Value

A reference to an IForm object, or NULL (Nothing in Visual Basic) if the IForm is the first element of the IFormCollection.

Example

The following example displays the Name values of all the IForm elements in an IFormCollection.

C# sample

public class Sample
{
    public static void LoadProject()
    {
        suite4.net.FormDatabase.IForm form;
        suite4.net.FormDatabase.IGroup group;
        suite4.net.FormDatabase.IProject project;

        // Load a project from a File
        project = suite4.net.FormDatabase.Project.LoadFromFile(@"C:\sample.fspj");

        // Get the first Group of the Project
        group = project.Groups.First;

        // Get the last Form of the GroupCollection
        form = group.Forms.Last;

        while(form != null)
        {
            System.Console.WriteLine("Display the Name of the form...");
            System.Console.WriteLine(form.Name);
            form = form.Prev;
        }
    }
}

VB.Net sample
Public Class Sample
    Public Shared Sub LoadProject()
        Dim form As suite4.net.FormDataMyBase.IForm
        Dim group As suite4.net.FormDataMyBase.IGroup
        Dim project As suite4.net.FormDataMyBase.IProject

        ' Load a project from a File
        project = suite4.net.FormDataMyBase.Project.LoadFromFile("C:\sample.fspj")

        ' Get the first Group of the Project
        group = project.Groups.First

        ' Get the last Form of the GroupCollection
        form = group.Forms.Last

        While Not form Is Nothing
            System.Console.WriteLine("Display the Name of the form...")
            System.Console.WriteLine(form.Name)
            form = form.Prev
        End While
    End Sub
End Class

See Also

IForm Interface | suite4.net.FormDatabase Namespace


Resolution Property

suite4.net.FormDatabase Documentation

IForm.Resolution Property

Gets the namespace of the IForm.

[Visual Basic]
Property Resolution As String
[C#]
string Resolution {get;}

Property Value

The namespace of the IForm.

Remarks

The value of this property can only be modified in the form.suite4.net designer.

See Also

IForm Interface | suite4.net.FormDatabase Namespace


Size Property

suite4.net.FormDatabase Documentation

IForm.Size Property

Gets the Size of the IForm.

[Visual Basic]
Property Size As Size
[C#]
System.Drawing.Size Size {get;}

Property Value

The Size of the IForm

See Also

IForm Interface | suite4.net.FormDatabase Namespace


Tasks Property

suite4.net.FormDatabase Documentation

IForm.Tasks Property

Gets the tasks associated with this IForm.

[Visual Basic]
Property Tasks As ITaskCollection
[C#]
ITaskCollection Tasks {get;}

Property Value

An ITaskCollection containing all the ITask elements associated with this IForm.

See Also

IForm Interface | suite4.net.FormDatabase Namespace


UseDataBinding Property

suite4.net.FormDatabase Documentation

IForm.UseDataBinding Property

Gets a value indicating whether data binding should be used with this IForm.

[Visual Basic]
Property UseDataBinding As Boolean
[C#]
bool UseDataBinding {get;}

Property Value

A Boolean value indicating the use of data binding in this IForm.

Remarks

  • UseDataBinding is used in the LoaderForm or LoaderControl components to govern whether or not a Binding instance should be assigned to the IForm.
  • The value of this property can only be modified in the form.suite4.net designer.

See Also

IForm Interface | suite4.net.FormDatabase Namespace


UserGroup Property

suite4.net.FormDatabase Documentation

IForm.UserGroup Property

Gets the UserGroup of the IForm.

[Visual Basic]
Property UserGroup As String
[C#]
string UserGroup {get;}

Property Value

The UserGroup of the IForm.

Remarks

This property can be used to programmatically filter forms in the application when using the FormDatabase API. The value of this property can only be modified in the form.suite4.net designer.

See Also

IForm Interface | suite4.net.FormDatabase Namespace


WebBackColor Property

suite4.net.FormDatabase Documentation

IForm.WebBackColor Property

Gets or sets the Color value that will be used in the WebLoader component.

[Visual Basic]
Property WebBackColor As Color
[C#]
System.Drawing.Color WebBackColor {get; set;}

Property Value

The Color value to be used. The default value is White.

See Also

IForm Interface | suite4.net.FormDatabase Namespace


WebServicePassword Property

suite4.net.FormDatabase Documentation

IForm.WebServicePassword Property

Gets or sets a password used in accessing an XML web service using the WebLoader component.

[Visual Basic]
Property WebServicePassword As String
[C#]
string WebServicePassword {get; set;}

Property Value

The password used in communicating with an XML web service using the WebLoader component.

See Also

IForm Interface | suite4.net.FormDatabase Namespace


IForm Methods

The methods of the IForm interface are listed below. For a complete list of IForm interface members, see the IForm Members topic.

Public Instance Methods

DeserializeDataSourceFromSwfXml | Deserializes a business object from an XML string. The method takes an existing business object instance and an XML string and updates the business object with the values stored in the XML string.
SerializeDataSourceToSwfXml | Serializes a business object instance to an XML string. The XML is processed by the WebLoader component to display the business object's values in a Macromedia Flash form.
SerializeToSwfXml | Overloaded. Serializes the current IForm, an instance of a business object and a WebLoaderAlert to an XML string. The XML is processed by the WebLoader component to dynamically draw a form and display the business object's values in a Macromedia Flash form.
SetComponentValue | Sets the value of a designated property of a component contained in the IForm.

See Also

IForm Interface | suite4.net.FormDatabase Namespace


IForm.DeserializeDataSourceFromSwfXml Method

Deserializes a business object from an XML string. The method takes an existing business object instance and an XML string and updates the business object with the values stored in the XML string.

[Visual Basic]
Sub DeserializeDataSourceFromSwfXml( _
ByVal swfXml As String, _
ByVal dataSource As Object _
)
[C#]
void DeserializeDataSourceFromSwfXml(
string swfXml,
object dataSource
);

Parameters

swfXml
The XML string containing updated values to be merged with dataSource.
dataSource
The instance of the business object which will be updated with the values of swfXml.

Remarks

  • swfXml is returned from the WebLoader component and contains the changes the user has made in the Flash form.
  • This method is only used in conjunction with the WebLoader component. Use the LoaderControl or the LoaderForm components to display business object values in a Windows Form environment.
  • SWF is the file extension of Macromedia Flash files. These are used by the WebLoader component to display an IForm in a Web page.

See Also

IForm Interface | suite4.net.FormDatabase Namespace


IForm.SerializeDataSourceToSwfXml Method

Serializes a business object instance to an XML string. The XML is processed by the WebLoader component to display the business object's values in a Macromedia Flash form.

[Visual Basic]
Function SerializeDataSourceToSwfXml( _
ByVal dataSource As Object _
) As String
[C#]
string SerializeDataSourceToSwfXml(
object dataSource
);

Parameters

dataSource
An instance of the data source.

Return Value

An XML string representing the business object instance associated with the IForm.

Remarks

  • SWF is the file extension of Macromedia Flash files. These are used by the WebLoader to display an IForm in a Web page.
  • The difference between this method and SerializeToSwfXml lies in the extent of the serialization: SerializeToSwfXml serializes both the IForm and the business object instance whereas SerializeDataSourceToSwfXml serializes the business object (data source) only.
  • This method is only used in conjunction with the WebLoader component. Use the LoaderControl or the LoaderForm components to display business object values in a Windows Form environment.

See Also

IForm Interface | suite4.net.FormDatabase Namespace


SerializeToSwfXml Method

suite4.net.FormDatabase Documentation

IForm.SerializeToSwfXml Method

Serializes the current IForm and an instance of a business object bound to it to an XML string. The XML is processed by the WebLoader component to dynamically draw a form and display the business object's values in a Macromedia Flash form.

Overload List

Serializes the current IForm and an instance of a business object bound to it to an XML string. The XML is processed by the WebLoader component to dynamically draw a form and display the business object's values in a Macromedia Flash form.

string SerializeToSwfXml(object);

Serializes the current IForm and an instance of a business object bound to it to an XML string. The XML is processed by the WebLoader component to dynamically draw a form and display the business object's values in a Macromedia Flash form. After the WebLoader has rendered a form, a specified JavaScript or VBScript function is called.

string SerializeToSwfXml(object,string,string);

Serializes the current IForm, an instance of a business object and a WebLoaderAlert to an XML string. The XML is processed by the WebLoader component to dynamically draw a form and display the business object's values in a Macromedia Flash form.

string SerializeToSwfXml(object,WebLoaderAlert);

Serializes the current IForm, an instance of a business object and a WebLoaderAlert to an XML string. The XML is processed by the WebLoader component to dynamically draw a form and display the business object's values in a Macromedia Flash form. After the WebLoader has rendered a form, a specified JavaScript or VBScript function is called.

string SerializeToSwfXml(object,WebLoaderAlert,string,string);

See Also

IForm Interface | suite4.net.FormDatabase Namespace


IForm.SerializeToSwfXml Method (Object)

Serializes the current IForm and an instance of a business object bound to it to an XML string. The XML is processed by the WebLoader component to dynamically draw a form and display the business object's values in a Macromedia Flash form.

[Visual Basic]
Function SerializeToSwfXml( _
ByVal dataSource As Object _
) As String
[C#]
string SerializeToSwfXml(
object dataSource
);

Parameters

dataSource
The business object instance to be serialized.

Return Value

An XML string representing the IForm and an associated business object instance.

Remarks

  • SWF is the file extension of Macromedia Flash files. These are used by the WebLoader to display an IForm in a Web page.
  • The difference between this method and SerializeDataSourceToSwfXml lies in the extent of the serialization: SerializeDataSourceToSwfXml serializes the business object (data source) only, whereas SerializeToSwfXml serializes both the IForm and the business object instance.
  • This method is only used in conjunction with the WebLoader component. Use the LoaderControl or the LoaderForm components to display business object values in a Windows Forms environment.

Example

The following example demonstrates how to serialize an IForm and assign a DataUniqueID.

C# sample

using System;
using suite4.net.FormDatabase;
using suite4.net.Sample;
namespace suite4.net.Web.Sample
{
    public class FormServer : System.Web.Services.WebService
    {
        [System.Web.Services.WebMethod]
        public string SerializeForm(string formName)
        {
            string                    projectFileName;
            Employee                employee;
            IForm                        form;
            IProject                project;
            WebLoaderAlert    webLoaderAlert;

            projectFileName = this.Server.MapPath("\\sample") + "\\sample.fspj";
            project = Project.LoadFromFile(projectFileName);
            if(project != null)
            {
                form = project.GetForm(formName);
                if(form != null)
                {
                    employee = new Employee();
                    employee.EmployeeID    = 1;
                    employee.LastName        = "Robert";
                    employee.LastName        = "King";
                    form.DataUniqueID        = employee.EmployeeID.ToString();
                    form.WebLoaderEvent.WsdlUrl        = "/FormServer/FormServer.asmx?wsdl";
                    form.WebLoaderEvent.Operation    = "GetEmployee";
                    form.WebLoaderEvent.ClearParameters();
                    form.WebLoaderEvent.AddParameter(WebLoaderParameterType.FormDatabase);
                    form.WebLoaderEvent.AddParameter(WebLoaderParameterType.FormName);
                    form.WebLoaderEvent.AddParameter(WebLoaderParameterType.DataUniqueID);
                    return form.SerializeToSwfXml(employee);
                }
                else
                {
                    webLoaderAlert = new WebLoaderAlert();
                    webLoaderAlert.Title = "Failed to load form";
                    webLoaderAlert.Message = "Can't find form " + formName;
                    return webLoaderAlert.SerializeToSwfXml();
                }
            }
            else
            {
                webLoaderAlert = new WebLoaderAlert();
                webLoaderAlert.Title = "Failed to load project";
                webLoaderAlert.Message = "Can't find project\n" + projectFileName;
                return webLoaderAlert.SerializeToSwfXml();
            }
        }
    }
}

VB.Net sample
Imports System
Imports suite4.net.FormDatabase
Imports suite4.net.Sample
Namespace suite4.net.Web.Sample
    Public Class FormServer
     Inherits System.Web.Services.WebService
        <System.Web.Services.WebMethod> _
        Public Function SerializeForm(ByVal formName As String) As String
            Dim projectFileName As String
            Dim employee As Employee
            Dim form As IForm
            Dim project As IProject
            Dim webLoaderAlert As WebLoaderAlert

            projectFileName = Me.Server.MapPath("\\sample") + "\\sample.fspj"
            project = Project.LoadFromFile(projectFileName)
            If Not project Is Nothing Then
                form = project.GetForm(formName)
                If Not form Is Nothing Then
                    employee = New Employee()
                    employee.EmployeeID    = 1
                    employee.LastName        = "Robert"
                    employee.LastName        = "King"
                    form.DataUniqueID        = employee.EmployeeID.ToString()
                    form.WebLoaderEvent.WsdlUrl        = "/FormServer/FormServer.asmx?wsdl"
                    form.WebLoaderEvent.Operation    = "GetEmployee"
                    form.WebLoaderEvent.ClearParameters()
                    form.WebLoaderEvent.AddParameter(WebLoaderParameterType.FormDatabase)
                    form.WebLoaderEvent.AddParameter(WebLoaderParameterType.FormName)
                    form.WebLoaderEvent.AddParameter(WebLoaderParameterType.DataUniqueID)
                    Return form.SerializeToSwfXml(employee)
                Else
                    webLoaderAlert = New WebLoaderAlert()
                    webLoaderAlert.Title = "Failed to load form"
                    webLoaderAlert.Message = "Can't find form " + formName
                    Return webLoaderAlert.SerializeToSwfXml()
                End If
            Else
                webLoaderAlert = New WebLoaderAlert()
                webLoaderAlert.Title = "Failed to load project"
                webLoaderAlert.Message = "Can't find project\n" + projectFileName
                Return webLoaderAlert.SerializeToSwfXml()
            End If
        End Function
    End Class
End Namespace

See Also

IForm Interface | suite4.net.FormDatabase Namespace | IForm.SerializeToSwfXml Overload List


IForm.SerializeToSwfXml Method (Object, String, String)

Serializes the current IForm and an instance of a business object bound to it to an XML string. The XML is processed by the WebLoader component to dynamically draw a form and display the business object's values in a Macromedia Flash form. After the WebLoader has rendered a form, a specified JavaScript or VBScript function is called.

[Visual Basic]
Function SerializeToSwfXml( _
ByVal dataSource As Object, _
ByVal scriptFunction As String, _
ByVal scriptFunctionArgument As String _
) As String
[C#]
string SerializeToSwfXml(
object dataSource,
string scriptFunction,
string scriptFunctionArgument
);

Parameters

dataSource
The business object instance to be serialized.
scriptFunction
The script function to be called after the rendering of the form has been completed.
scriptFunctionArgument
A parameter for use with the scriptFunction.

Return Value

An XML string representing the IForm and an associated business object instance.

Remarks

  • SWF is the file extension of Macromedia Flash files. These are used by the WebLoader to display an IForm in a Web page.
  • The difference between this method and SerializeDataSourceToSwfXml lies in the extent of the serialization: SerializeDataSourceToSwfXml serializes the business object (data source) only, whereas SerializeToSwfXml serializes both the IForm and the business object instance.
  • This method is only used in conjunction with the WebLoader component. Use the LoaderControl or the LoaderForm components to display business object values in a Windows Forms environment.

Example

The following example demonstrates how to serialize an IForm and with a scriptFunction.

C# sample

form = project.GetForm(formName);
if(form != null)
{
    return form.SerializeToSwfXml(null, "UpdateIFrame", "ShowAll");
}
else
{
    webLoaderAlert = new WebLoaderAlert();
    webLoaderAlert.Title = "Failed to load form";
    webLoaderAlert.Message = "Can't find form " + formName;
    return webLoaderAlert.SerializeToSwfXml();
}

VB.Net sample
form = project.GetForm(formName)
If Not form Is Nothing Then
    Return form.SerializeToSwfXml(Nothing, "UpdateIFrame", "ShowAll")
Else
    webLoaderAlert = New WebLoaderAlert()
    webLoaderAlert.Title = "Failed to load form"
    webLoaderAlert.Message = "Can't find form " + formName
    Return webLoaderAlert.SerializeToSwfXml()
End If

JavaScript sample
<script language="JavaScript">
<!--
var isInternetExplorer = navigator.appName.indexOf('Microsoft') != -1;
function WebLoader_DoFSCommand(command, args)
{
  if(command == 'RedirectToLogin')
  {
    window.location.assign(args);
  }
  else
  {
    var fsObj = isInternetExplorer ? document.all.WebLoader : document.WebLoader;
    var TableFrame = document.getElementById('DataIFrame');
    TableFrame.src = '/support/PostingTable.aspx?Refresh=' + args;
  }
}
if(navigator.appName && navigator.appName.indexOf('Microsoft') != -1
   && navigator.userAgent.indexOf('Windows') != -1
   && navigator.userAgent.indexOf('Windows 3.1') == -1)
{
  document.write('<script language=\"VBScript\"\>\n');
  document.write('On Error Resume Next\n');
  document.write('Sub WebLoader_FSCommand(ByVal command, ByVal args)\n');
  document.write('    Call WebLoader_DoFSCommand(command, args)\n');
  document.write('End Sub\n');
  document.write('</script\>\n');
}
//-->
</script<

See Also

IForm Interface | suite4.net.FormDatabase Namespace | IForm.SerializeToSwfXml Overload List


IForm.SerializeToSwfXml Method (Object, WebLoaderAlert)

Serializes the current IForm, an instance of a business object and a WebLoaderAlert to an XML string. The XML is processed by the WebLoader component to dynamically draw a form and display the business object's values in a Macromedia Flash form.

[Visual Basic]
Function SerializeToSwfXml( _
ByVal dataSource As Object, _
ByVal webLoaderAlert As WebLoaderAlert _
) As String
[C#]
string SerializeToSwfXml(
object dataSource,
WebLoaderAlert webLoaderAlert
);

Parameters

dataSource
The business object instance to be serialized.
webLoaderAlert
A WebLoaderAlert that is to be displayed by the WebLoader.

Return Value

An XML string representing the IForm and an associated business object instance.

Remarks

  • SWF is the file extension of Macromedia Flash files. These are used by the WebLoader to display an IForm in a Web page.
  • The difference between this method and SerializeDataSourceToSwfXml lies in the extent of the serialization: SerializeDataSourceToSwfXml serializes the business object (data source) only, whereas SerializeToSwfXml serializes both the IForm and the business object instance.
  • This method is only used in conjunction with the WebLoader component. Use the LoaderControl or the LoaderForm components to display business object values in a Windows Forms environment.

Example

The following example demonstrates how to serialize an IForm and display an alert to the user.

C# sample

using System;
using System.Collections;
using suite4.net.FormDatabase;
using suite4.net.Sample;
namespace suite4.net.Web.Sample
{
    public class FormServer : System.Web.Services.WebService
    {
        [System.Web.Services.WebMethod]
        public string SerializeForm(string formName)
        {
            string                    projectFileName;
            IForm                        form;
            IProject                project;
            ArrayList                employees;
            WebLoaderAlert    webLoaderAlert;

            projectFileName = this.Server.MapPath("\\sample") + "\\sample.fspj";
            project = Project.LoadFromFile(projectFileName);
            if(project != null)
            {
                form = project.GetForm(formName);
                if(form != null)
                {
                    employees = new ArrayList();
                    employees.Add("Anne Dodsworth");
                    employees.Add("Laura Callahan");
                    employees.Add("Robert King");
                    form.SetComponentValue("lstEmployees", "Items", employees);
                    webLoaderAlert = new WebLoaderAlert();
                    webLoaderAlert.Title = "Select an employee";
                    webLoaderAlert.Message = "Please select an employee\nto see the employee details.";
                    return form.SerializeToSwfXml(null, webLoaderAlert);
                }
                else
                {
                    webLoaderAlert = new WebLoaderAlert();
                    webLoaderAlert.Title = "Failed to load form";
                    webLoaderAlert.Message = "Can't find form " + formName;
                    return webLoaderAlert.SerializeToSwfXml();
                }
            }
            else
            {
                webLoaderAlert = new WebLoaderAlert();
                webLoaderAlert.Title = "Failed to load project";
                webLoaderAlert.Message = "Can't find project\n" + projectFileName;
                return webLoaderAlert.SerializeToSwfXml();
            }
        }
    }
}

VB.Net sample
Imports System
Imports System.Collections
Imports suite4.net.FormDatabase
Imports suite4.net.Sample
Namespace suite4.net.Web.Sample
    Public Class FormServer
     Inherits System.Web.Services.WebService
        <System.Web.Services.WebMethod> _
        Public Function SerializeForm(ByVal formName As String) As String
            Dim projectFileName As String
            Dim form As IForm
            Dim project As IProject
            Dim employees As ArrayList
            Dim webLoaderAlert As WebLoaderAlert

            projectFileName = Me.Server.MapPath("\\sample") + "\\sample.fspj"
            project = Project.LoadFromFile(projectFileName)
            If Not project Is Nothing Then
                form = project.GetForm(formName)
                If Not form Is Nothing Then
                    employees = New ArrayList()
                    employees.Add("Anne Dodsworth")
                    employees.Add("Laura Callahan")
                    employees.Add("Robert King")
                    form.SetComponentValue("lstEmployees", "Items", employees)
                    webLoaderAlert = New WebLoaderAlert()
                    webLoaderAlert.Title = "Select an employee"
                    webLoaderAlert.Message = "Please select an employee\nto see the employee details."
                    Return form.SerializeToSwfXml(Nothing,webLoaderAlert)
                Else
                    webLoaderAlert = New WebLoaderAlert()
                    webLoaderAlert.Title = "Failed to load form"
                    webLoaderAlert.Message = "Can't find form " + formName
                    Return webLoaderAlert.SerializeToSwfXml()
                End If
            Else
                webLoaderAlert = New WebLoaderAlert()
                webLoaderAlert.Title = "Failed to load project"
                webLoaderAlert.Message = "Can't find project\n" + projectFileName
                Return webLoaderAlert.SerializeToSwfXml()
            End If
        End Function
    End Class
End Namespace

See Also

IForm Interface | suite4.net.FormDatabase Namespace | IForm.SerializeToSwfXml Overload List


IForm.SerializeToSwfXml Method (Object, WebLoaderAlert, String, String)

Serializes the current IForm, an instance of a business object and a WebLoaderAlert to an XML string. The XML is processed by the WebLoader component to dynamically draw a form and display the business object's values in a Macromedia Flash form. After the WebLoader has rendered a form, a specified JavaScript or VBScript function is called.

[Visual Basic]
Function SerializeToSwfXml( _
ByVal dataSource As Object, _
ByVal webLoaderAlert As WebLoaderAlert, _
ByVal scriptFunction As String, _
ByVal scriptFunctionArgument As String _
) As String
[C#]
string SerializeToSwfXml(
object dataSource,
WebLoaderAlert webLoaderAlert,
string scriptFunction,
string scriptFunctionArgument
);

Parameters

dataSource
The business object instance to be serialized.
webLoaderAlert
A WebLoaderAlert that is to be displayed by the WebLoader.
scriptFunction
The script function to be called after the rendering of the form has been completed.
scriptFunctionArgument
A parameter for use with the scriptFunction.

Return Value

An XML string representing the IForm and an associated business object instance.

Remarks

  • SWF is the file extension of Macromedia Flash files. These are used by the WebLoader to display an IForm in a Web page.
  • The difference between this method and SerializeDataSourceToSwfXml lies in the extent of the serialization: SerializeDataSourceToSwfXml serializes the business object (data source) only, whereas SerializeToSwfXml serializes both the IForm and the business object instance.
  • This method is only used in conjunction with the WebLoader component. Use the LoaderControl or the LoaderForm components to display business object values in a Windows Forms environment.

Example

The following example demonstrates how to serialize an IForm and with a scriptFunction.

C# sample

form = project.GetForm(formName);
if(form != null)
{
    return form.SerializeToSwfXml(null, "UpdateIFrame", "ShowAll");
}
else
{
    webLoaderAlert = new WebLoaderAlert();
    webLoaderAlert.Title = "Failed to load form";
    webLoaderAlert.Message = "Can't find form " + formName;
    return webLoaderAlert.SerializeToSwfXml();
}

VB.Net sample
form = project.GetForm(formName)
If Not form Is Nothing Then
    Return form.SerializeToSwfXml(Nothing, "UpdateIFrame", "ShowAll")
Else
    webLoaderAlert = New WebLoaderAlert()
    webLoaderAlert.Title = "Failed to load form"
    webLoaderAlert.Message = "Can't find form " + formName
    Return webLoaderAlert.SerializeToSwfXml()
End If

JavaScript sample
<script language="JavaScript">
<!--
var isInternetExplorer = navigator.appName.indexOf('Microsoft') != -1;
function WebLoader_DoFSCommand(command, args)
{
  if(command == 'RedirectToLogin')
  {
    window.location.assign(args);
  }
  else
  {
    var fsObj = isInternetExplorer ? document.all.WebLoader : document.WebLoader;
    var TableFrame = document.getElementById('DataIFrame');
    TableFrame.src = '/support/PostingTable.aspx?Refresh=' + args;
  }
}
if(navigator.appName && navigator.appName.indexOf('Microsoft') != -1
   && navigator.userAgent.indexOf('Windows') != -1
   && navigator.userAgent.indexOf('Windows 3.1') == -1)
{
  document.write('<script language=\"VBScript\"\>\n');
  document.write('On Error Resume Next\n');
  document.write('Sub WebLoader_FSCommand(ByVal command, ByVal args)\n');
  document.write('    Call WebLoader_DoFSCommand(command, args)\n');
  document.write('End Sub\n');
  document.write('</script\>\n');
}
//-->
</script<

See Also

IForm Interface | suite4.net.FormDatabase Namespace | IForm.SerializeToSwfXml Overload List


IForm.SetComponentValue Method

Sets the value of a designated property of a component contained in the IForm.

[Visual Basic]
Sub SetComponentValue( _
ByVal componentName As String, _
ByVal propertyName As String, _
ByVal value As Object _
)
[C#]
void SetComponentValue(
string componentName,
string propertyName,
object value
);

Parameters

componentName
The component's name.
propertyName
The name of the property.
value
The value to be set.

Exceptions

Exception Type | Condition
ArgumentNullException | An argument is null (Nothing in Visual Basic).
LoaderException | The component with the name can't be found in the IForm or the property can't set to the provided value.

Example

The following example demonstrates how to serialize an IForm and display an alert to the user.

C# sample

using System;
using System.Collections;
using suite4.net.FormDatabase;
using suite4.net.Sample;
namespace suite4.net.Web.Sample
{
    public class FormServer : System.Web.Services.WebService
    {
        [System.Web.Services.WebMethod]
        public string SerializeForm(string formName)
        {
            string                    projectFileName;
            IForm                        form;
            IProject                project;
            ArrayList                employees;
            WebLoaderAlert    webLoaderAlert;

            projectFileName = this.Server.MapPath("\\sample") + "\\sample.fspj";
            project = Project.LoadFromFile(projectFileName);
            if(project != null)
            {
                form = project.GetForm(formName);
                if(form != null)
                {
                    employees = new ArrayList();
                    employees.Add("Anne Dodsworth");
                    employees.Add("Laura Callahan");
                    employees.Add("Robert King");
                    form.SetComponentValue("lstEmployees", "Items", employees);
                    webLoaderAlert = new WebLoaderAlert();
                    webLoaderAlert.Title = "Select an employee";
                    webLoaderAlert.Message = "Please select an employee\nto see the employee details.";
                    return form.SerializeToSwfXml(null, webLoaderAlert);
                }
                else
                {
                    webLoaderAlert = new WebLoaderAlert();
                    webLoaderAlert.Title = "Failed to load form";
                    webLoaderAlert.Message = "Can't find form " + formName;
                    return webLoaderAlert.SerializeToSwfXml();
                }
            }
            else
            {
                webLoaderAlert = new WebLoaderAlert();
                webLoaderAlert.Title = "Failed to load project";
                webLoaderAlert.Message = "Can't find project\n" + projectFileName;
                return webLoaderAlert.SerializeToSwfXml();
            }
        }
    }
}

VB.Net sample
Imports System
Imports System.Collections
Imports suite4.net.FormDatabase
Imports suite4.net.Sample
Namespace suite4.net.Web.Sample
    Public Class FormServer
     Inherits System.Web.Services.WebService
        <System.Web.Services.WebMethod> _
        Public Function SerializeForm(ByVal formName As String) As String
            Dim projectFileName As String
            Dim form As IForm
            Dim project As IProject
            Dim employees As ArrayList
            Dim webLoaderAlert As WebLoaderAlert

            projectFileName = Me.Server.MapPath("\\sample") + "\\sample.fspj"
            project = Project.LoadFromFile(projectFileName)
            If Not project Is Nothing Then
                form = project.GetForm(formName)
                If Not form Is Nothing Then
                    employees = New ArrayList()
                    employees.Add("Anne Dodsworth")
                    employees.Add("Laura Callahan")
                    employees.Add("Robert King")
                    form.SetComponentValue("lstEmployees", "Items", employees)
                    webLoaderAlert = New WebLoaderAlert()
                    webLoaderAlert.Title = "Select an employee"
                    webLoaderAlert.Message = "Please select an employee\nto see the employee details."
                    Return form.SerializeToSwfXml(Nothing,webLoaderAlert)
                Else
                    webLoaderAlert = New WebLoaderAlert()
                    webLoaderAlert.Title = "Failed to load form"
                    webLoaderAlert.Message = "Can't find form " + formName
                    Return webLoaderAlert.SerializeToSwfXml()
                End If
            Else
                webLoaderAlert = New WebLoaderAlert()
                webLoaderAlert.Title = "Failed to load project"
                webLoaderAlert.Message = "Can't find project\n" + projectFileName
                Return webLoaderAlert.SerializeToSwfXml()
            End If
        End Function
    End Class
End Namespace

See Also

IForm Interface | suite4.net.FormDatabase Namespace


IFormCollection Interface

Represents a collection of IForm objects.

For a list of all members of this type, see IFormCollection Members.

[Visual Basic]
Public Interface IFormCollection
Implements ICollection, IEnumerable
[C#]
public interface IFormCollection : ICollection, IEnumerable

Remarks

This collection can only contain objects of type IForm.

Requirements

Namespace: suite4.net.FormDatabase

Assembly: suite4.net.FormDatabase (in suite4.net.FormDatabase.dll)

See Also

IFormCollection Members | suite4.net.FormDatabase Namespace


IFormCollection Members

IFormCollection overview

Public Instance Properties

First | Gets the first IForm in the IFormCollection.
Item | Gets an IForm element with a specified name.
Last | Gets the last IForm in the IFormCollection.
SortDirection | Specifies the direction of a sort operation to be performed on the IFormCollection.
SortProperty | Specifies the IForm property to be used in a sort operation on the IFormCollection.

Public Instance Methods

Sort Overloaded. Sorts the elements in the IFormCollection using the specified SortProperty and SortDirection values.

See Also

IFormCollection Interface | suite4.net.FormDatabase Namespace


IFormCollection Properties

The properties of the IFormCollection interface are listed below. For a complete list of IFormCollection interface members, see the IFormCollection Members topic.

Public Instance Properties

First | Gets the first IForm in the IFormCollection.
Item | Gets an IForm element with a specified name.
Last | Gets the last IForm in the IFormCollection.
SortDirection | Specifies the direction of a sort operation to be performed on the IFormCollection.
SortProperty | Specifies the IForm property to be used in a sort operation on the IFormCollection.

See Also

IFormCollection Interface | suite4.net.FormDatabase Namespace


First Property

suite4.net.FormDatabase Documentation

IFormCollection.First Property

Gets the first IForm in the IFormCollection.

[Visual Basic]
Property First As IForm
[C#]
IForm First {get;}

Property Value

The first IForm in the IFormCollection. If there is none, NULL (Nothing in Visual Basic) is returned.

Example

The following example displays the Name values of all the IForm elements in an IFormCollection.

C# sample

public class Sample
{
    public static void LoadProject()
    {
        suite4.net.FormDatabase.IForm form;
        suite4.net.FormDatabase.IGroup group;
        suite4.net.FormDatabase.IProject project;

        // Load a project from a File
        project = suite4.net.FormDatabase.Project.LoadFromFile(@"C:\sample.fspj");

        // Get the first Group of the Project
        group = project.Groups.First;

        // Get the first Form of the GroupCollection
        form = group.Forms.First;

        while(form != null)
        {
            System.Console.WriteLine("Display the Name of the form...");
            System.Console.WriteLine(form.Name);
            form = form.Next;
        }
    }
}

VB.Net sample
Public Class Sample
    Public Shared Sub LoadProject()
        Dim form As suite4.net.FormDataMyBase.IForm
        Dim group As suite4.net.FormDataMyBase.IGroup
        Dim project As suite4.net.FormDataMyBase.IProject

        ' Load a project from a File
        project = suite4.net.FormDataMyBase.Project.LoadFromFile("C:\sample.fspj")

        ' Get the first Group of the Project
        group = project.Groups.First

        ' Get the first Form of the GroupCollection
        form = group.Forms.First

        While Not form Is Nothing
            System.Console.WriteLine("Display the Name of the form...")
            System.Console.WriteLine(form.Name)
            form = form.Next
        End While
    End Sub
End Class

See Also

IFormCollection Interface | suite4.net.FormDatabase Namespace


Item Property

suite4.net.FormDatabase Documentation

IFormCollection.Item Property

Gets an IForm element with a specified name.

[Visual Basic]
Property Item( _
ByVal name As String _
) As IForm
[C#]
IForm this[
string name
] {get;}

Parameters

name
The Name of the IForm to get.

Remarks

Access to collection elements by using an index is not supported.

Exceptions

Exception Type | Condition
ArgumentOutOfRangeException | No element with the specified name exists in the IFormCollection.
NotSupportedException | The caller attempts to retrieve an element using an index.

See Also

IFormCollection Interface | suite4.net.FormDatabase Namespace


Last Property

suite4.net.FormDatabase Documentation

IFormCollection.Last Property

Gets the last IForm in the IFormCollection.

[Visual Basic]
Property Last As IForm
[C#]
IForm Last {get;}

Property Value

The last IForm in the IFormCollection. If there is none, NULL (Nothing in Visual Basic) is returned.

Example

The following example displays the Name values of all the IForm elements in an IFormCollection.

C# sample

public class Sample
{
    public static void LoadProject()
    {
        suite4.net.FormDatabase.IForm form;
        suite4.net.FormDatabase.IGroup group;
        suite4.net.FormDatabase.IProject project;

        // Load a project from a File
        project = suite4.net.FormDatabase.Project.LoadFromFile(@"C:\sample.fspj");

        // Get the first Group of the Project
        group = project.Groups.First;

        // Get the last Form of the GroupCollection
        form = group.Forms.Last;

        while(form != null)
        {
            System.Console.WriteLine("Display the Name of the form...");
            System.Console.WriteLine(form.Name);
            form = form.Prev;
        }
    }
}

VB.Net sample
Public Class Sample
    Public Shared Sub LoadProject()
        Dim form As suite4.net.FormDataMyBase.IForm
        Dim group As suite4.net.FormDataMyBase.IGroup
        Dim project As suite4.net.FormDataMyBase.IProject

        ' Load a project from a File
        project = suite4.net.FormDataMyBase.Project.LoadFromFile("C:\sample.fspj")

        ' Get the first Group of the Project
        group = project.Groups.First

        ' Get the last Form of the GroupCollection
        form = group.Forms.Last

        While Not form Is Nothing
            System.Console.WriteLine("Display the Name of the form...")
            System.Console.WriteLine(form.Name)
            form = form.Prev
        End While
    End Sub
End Class

See Also

IFormCollection Interface | suite4.net.FormDatabase Namespace


SortDirection Property

suite4.net.FormDatabase Documentation

IFormCollection.SortDirection Property

Specifies the direction of a sort operation to be performed on the IFormCollection.

[Visual Basic]
Property SortDirection As ListSortDirection
[C#]
System.ComponentModel.ListSortDirection SortDirection {get; set;}

Property Value

Gets or sets the ListSortDirection of the IFormCollection. The default value is Ascending.

See Also

IFormCollection Interface | suite4.net.FormDatabase Namespace


SortProperty Property

suite4.net.FormDatabase Documentation

IFormCollection.SortProperty Property

Specifies the IForm property to be used in a sort operation on the IFormCollection.

[Visual Basic]
Property SortProperty As FormSortProperty
[C#]
FormSortProperty SortProperty {get; set;}

Property Value

Gets or sets the FormSortProperty of the IFormCollection. The default value is Name.

Remarks

This property is used in the Sort method in conjunction with the SortDirection property.

See Also

IFormCollection Interface | suite4.net.FormDatabase Namespace


IFormCollection Methods

The methods of the IFormCollection interface are listed below. For a complete list of IFormCollection interface members, see the IFormCollection Members topic.

Public Instance Methods

Sort Overloaded. Sorts the elements in the IFormCollection using the specified SortProperty and SortDirection values.

See Also

IFormCollection Interface | suite4.net.FormDatabase Namespace


Sort Method

suite4.net.FormDatabase Documentation

IFormCollection.Sort Method

Sorts the elements in the IFormCollection.

Overload List

Sorts the elements in the IFormCollection.

void Sort();

Sorts the elements in the IFormCollection by the specified SortProperty.

void Sort(FormSortProperty);

Sorts the elements in the IFormCollection using the specified SortProperty and SortDirection values.

void Sort(FormSortProperty,ListSortDirection);

Sorts the elements in the IFormCollection using the specified direction.

void Sort(ListSortDirection);

See Also

IFormCollection Interface | suite4.net.FormDatabase Namespace


IFormCollection.Sort Method ()

Sorts the elements in the IFormCollection.

[Visual Basic]
Sub Sort()
[C#]
void Sort();

Remarks

The IFormCollection will be sorted by the value of the SortProperty property and ordered by the value of the SortDirection property.

See Also

IFormCollection Interface | suite4.net.FormDatabase Namespace | IFormCollection.Sort Overload List


IFormCollection.Sort Method (FormSortProperty)

Sorts the elements in the IFormCollection by the specified SortProperty.

[Visual Basic]
Sub Sort( _
ByVal sortProperty As FormSortProperty _
)
[C#]
void Sort(
FormSortProperty sortProperty
);

Parameters

sortProperty
The SortProperty the collection is to be sorted by.

Remarks

  • The sort direction is determined by the value of the SortDirection.
  • The sortProperty value is stored in the IFormCollection for later reuse.

See Also

IFormCollection Interface | suite4.net.FormDatabase Namespace | IFormCollection.Sort Overload List


IFormCollection.Sort Method (FormSortProperty, ListSortDirection)

Sorts the elements in the IFormCollection using the specified SortProperty and SortDirection values.

[Visual Basic]
Sub Sort( _
ByVal sortProperty As FormSortProperty, _
ByVal sortDirection As ListSortDirection _
)
[C#]
void Sort(
FormSortProperty sortProperty,
ListSortDirection sortDirection
);

Parameters

sortProperty
The SortProperty the collection is to be sorted by.
sortDirection
The SortDirection the collection is to be sorted in.

Remarks

Both the sortProperty and the sortDirection values are stored in the IFormCollection for later reuse.

See Also

IFormCollection Interface | suite4.net.FormDatabase Namespace | IFormCollection.Sort Overload List


IFormCollection.Sort Method (ListSortDirection)

Sorts the elements in the IFormCollection using the specified direction.

[Visual Basic]
Sub Sort( _
ByVal sortDirection As ListSortDirection _
)
[C#]
void Sort(
ListSortDirection sortDirection
);

Parameters

sortDirection
The SortDirection the collection is to be sorted in.

Remarks

  • The IFormCollection will be sorted by the property which is specified in the SortProperty value.
  • The sortDirection value is stored in the IFormCollection for later reuse.

See Also

IFormCollection Interface | suite4.net.FormDatabase Namespace | IFormCollection.Sort Overload List


IGroup Interface

Represents a Group (a logical container for Forms, UserControls and Reports in a project) which is itself an element of an IGroupCollection.

For a list of all members of this type, see IGroup Members.

[Visual Basic]
Public Interface IGroup
[C#]
public interface IGroup

Requirements

Namespace: suite4.net.FormDatabase

Assembly: suite4.net.FormDatabase (in suite4.net.FormDatabase.dll)

See Also

IGroup Members | suite4.net.FormDatabase Namespace


IGroup Members

IGroup overview

Public Instance Properties

Description | Gets or sets the description of the IGroup.
Forms | Gets the IFormCollection associated with this IGroup.
Name | Gets the name of the IGroup.
Next | Gets the next IGroup in the IGroupCollection.
Prev | Gets the previous IGroup in the IGroupCollection.
Tasks | Gets the tasks associated with this IGroup.

See Also

IGroup Interface | suite4.net.FormDatabase Namespace


IGroup Properties

The properties of the IGroup interface are listed below. For a complete list of IGroup interface members, see the IGroup Members topic.

Public Instance Properties

Description | Gets or sets the description of the IGroup.
Forms | Gets the IFormCollection associated with this IGroup.
Name | Gets the name of the IGroup.
Next | Gets the next IGroup in the IGroupCollection.
Prev | Gets the previous IGroup in the IGroupCollection.
Tasks | Gets the tasks associated with this IGroup.

See Also

IGroup Interface | suite4.net.FormDatabase Namespace


Description Property

suite4.net.FormDatabase Documentation

IGroup.Description Property

Gets or sets the description of the IGroup.

[Visual Basic]
Property Description As String
[C#]
string Description {get;}

Property Value

The description of the IGroup.

See Also

IGroup Interface | suite4.net.FormDatabase Namespace


Forms Property

suite4.net.FormDatabase Documentation

IGroup.Forms Property

Gets the IFormCollection associated with this IGroup.

[Visual Basic]
Property Forms As IFormCollection
[C#]
IFormCollection Forms {get;}

Property Value

A IFormCollection of all the Forms that are stored in the IGroup.

See Also

IGroup Interface | suite4.net.FormDatabase Namespace


Name Property

suite4.net.FormDatabase Documentation

IGroup.Name Property

Gets the name of the IGroup.

[Visual Basic]
Property Name As String
[C#]
string Name {get;}

Property Value

The name of the IGroup.

Remarks

The name can only be changed in the form.suite4.net designer.

See Also

IGroup Interface | suite4.net.FormDatabase Namespace


Next Property

suite4.net.FormDatabase Documentation

IGroup.Next Property

Gets the next IGroup in the IGroupCollection.

[Visual Basic]
Property Next As IGroup
[C#]
IGroup Next {get;}

Property Value

A reference to the next IGroup, or NULL (Nothing in Visual Basic) if the IGroup is the last element of the IGroupCollection.

Example

The following example displays the Name values of all the IForm elements in an IFormCollection.

C# sample

public class Sample
{
    public static void LoadProject()
    {
        suite4.net.FormDatabase.IForm form;
        suite4.net.FormDatabase.IGroup group;
        suite4.net.FormDatabase.IProject project;

        // Load a project from a File
        project = suite4.net.FormDatabase.Project.LoadFromFile(@"C:\sample.fspj");

        // Get the first Group of the Project
        group = project.Groups.First;

        // Get the first Form of the GroupCollection
        form = group.Forms.First;

        while(form != null)
        {
            System.Console.WriteLine("Display the Name of the form...");
            System.Console.WriteLine(form.Name);
            form = form.Next;
        }
    }
}

VB.Net sample
Public Class Sample
    Public Shared Sub LoadProject()
        Dim form As suite4.net.FormDataMyBase.IForm
        Dim group As suite4.net.FormDataMyBase.IGroup
        Dim project As suite4.net.FormDataMyBase.IProject

        ' Load a project from a File
        project = suite4.net.FormDataMyBase.Project.LoadFromFile("C:\sample.fspj")

        ' Get the first Group of the Project
        group = project.Groups.First

        ' Get the first Form of the GroupCollection
        form = group.Forms.First

        While Not form Is Nothing
            System.Console.WriteLine("Display the Name of the form...")
            System.Console.WriteLine(form.Name)
            form = form.Next
        End While
    End Sub
End Class

See Also

IGroup Interface | suite4.net.FormDatabase Namespace


Prev Property

suite4.net.FormDatabase Documentation

IGroup.Prev Property

Gets the previous IGroup in the IGroupCollection.

[Visual Basic]
Property Prev As IGroup
[C#]
IGroup Prev {get;}

Property Value

A reference to the previous IGroup, or Null (Nothing in Visual Basic) if the IGroup is the first element of the IGroupCollection.

Example

The following example displays the Name values of all the IForm elements in an IFormCollection.

C# sample

public class Sample
{
    public static void LoadProject()
    {
        suite4.net.FormDatabase.IForm form;
        suite4.net.FormDatabase.IGroup group;
        suite4.net.FormDatabase.IProject project;

        // Load a project from a File
        project = suite4.net.FormDatabase.Project.LoadFromFile(@"C:\sample.fspj");

        // Get the first Group of the Project
        group = project.Groups.First;

        // Get the last Form of the GroupCollection
        form = group.Forms.Last;

        while(form != null)
        {
            System.Console.WriteLine("Display the Name of the form...");
            System.Console.WriteLine(form.Name);
            form = form.Prev;
        }
    }
}

VB.Net sample
Public Class Sample
    Public Shared Sub LoadProject()
        Dim form As suite4.net.FormDataMyBase.IForm
        Dim group As suite4.net.FormDataMyBase.IGroup
        Dim project As suite4.net.FormDataMyBase.IProject

        ' Load a project from a File
        project = suite4.net.FormDataMyBase.Project.LoadFromFile("C:\sample.fspj")

        ' Get the first Group of the Project
        group = project.Groups.First

        ' Get the last Form of the GroupCollection
        form = group.Forms.Last

        While Not form Is Nothing
            System.Console.WriteLine("Display the Name of the form...")
            System.Console.WriteLine(form.Name)
            form = form.Prev
        End While
    End Sub
End Class

See Also

IGroup Interface | suite4.net.FormDatabase Namespace


Tasks Property

suite4.net.FormDatabase Documentation

IGroup.Tasks Property

Gets the tasks associated with this IGroup.

[Visual Basic]
Property Tasks As ITaskCollection
[C#]
ITaskCollection Tasks {get;}

Property Value

An ITaskCollection containing all the ITask elements associated with this IGroup.

See Also

IGroup Interface | suite4.net.FormDatabase Namespace


IGroupCollection Interface

Represents a collection of IGroup objects.

For a list of all members of this type, see IGroupCollection Members.

[Visual Basic]
Public Interface IGroupCollection
Implements ICollection, IEnumerable
[C#]
public interface IGroupCollection : ICollection, IEnumerable

Remarks

This collection can only contain objects of type IGroup.

Requirements

Namespace: suite4.net.FormDatabase

Assembly: suite4.net.FormDatabase (in suite4.net.FormDatabase.dll)

See Also

IGroupCollection Members | suite4.net.FormDatabase Namespace


IGroupCollection Members

IGroupCollection overview

Public Instance Properties

First | Gets the first IGroup in the IGroupCollection.
Item | Gets an IGroup element with a specified name.
Last | Gets the last IGroup in the IGroupCollection.
SortDirection | Specifies the direction of a sort operation to be performed on the IGroupCollection.
SortProperty | Specifies the IGroup property to be used in a sort operation on the IGroupCollection.

Public Instance Methods

Sort Overloaded. Sorts the elements in the IGroupCollection using the specified SortProperty and SortDirection values.

See Also

IGroupCollection Interface | suite4.net.FormDatabase Namespace


IGroupCollection Properties

The properties of the IGroupCollection interface are listed below. For a complete list of IGroupCollection interface members, see the IGroupCollection Members topic.

Public Instance Properties

First | Gets the first IGroup in the IGroupCollection.
Item | Gets an IGroup element with a specified name.
Last | Gets the last IGroup in the IGroupCollection.
SortDirection | Specifies the direction of a sort operation to be performed on the IGroupCollection.
SortProperty | Specifies the IGroup property to be used in a sort operation on the IGroupCollection.

See Also

IGroupCollection Interface | suite4.net.FormDatabase Namespace


First Property

suite4.net.FormDatabase Documentation

IGroupCollection.First Property

Gets the first IGroup in the IGroupCollection.

[Visual Basic]
Property First As IGroup
[C#]
IGroup First {get;}

Property Value

The first IGroup in the IGroupCollection. If there is none, NULL (Nothing in Visual Basic) is returned.

Example

The following example displays the Name values of all the IForm elements in an IFormCollection.

C# sample

public class Sample
{
    public static void LoadProject()
    {
        suite4.net.FormDatabase.IForm form;
        suite4.net.FormDatabase.IGroup group;
        suite4.net.FormDatabase.IProject project;

        // Load a project from a File
        project = suite4.net.FormDatabase.Project.LoadFromFile(@"C:\sample.fspj");

        // Get the first Group of the Project
        group = project.Groups.First;

        // Get the first Form of the GroupCollection
        form = group.Forms.First;

        while(form != null)
        {
            System.Console.WriteLine("Display the Name of the form...");
            System.Console.WriteLine(form.Name);
            form = form.Next;
        }
    }
}

VB.Net sample
Public Class Sample
    Public Shared Sub LoadProject()
        Dim form As suite4.net.FormDataMyBase.IForm
        Dim group As suite4.net.FormDataMyBase.IGroup
        Dim project As suite4.net.FormDataMyBase.IProject

        ' Load a project from a File
        project = suite4.net.FormDataMyBase.Project.LoadFromFile("C:\sample.fspj")

        ' Get the first Group of the Project
        group = project.Groups.First

        ' Get the first Form of the GroupCollection
        form = group.Forms.First

        While Not form Is Nothing
            System.Console.WriteLine("Display the Name of the form...")
            System.Console.WriteLine(form.Name)
            form = form.Next
        End While
    End Sub
End Class

See Also

IGroupCollection Interface | suite4.net.FormDatabase Namespace


Item Property

suite4.net.FormDatabase Documentation

IGroupCollection.Item Property

Gets an IGroup element with a specified name.

[Visual Basic]
Property Item( _
ByVal name As String _
) As IGroup
[C#]
IGroup this[
string name
] {get;}

Parameters

name
The Name of the IGroup to get.

Remarks

Access to collection elements by using an index is not supported.

Exceptions

Exception Type | Condition
ArgumentOutOfRangeException | No element with the specified name exists in the IGroupCollection.
NotSupportedException | The caller attempts to retrieve an element using an index.

See Also

IGroupCollection Interface | suite4.net.FormDatabase Namespace


Last Property

suite4.net.FormDatabase Documentation

IGroupCollection.Last Property

Gets the last IGroup in the IGroupCollection.

[Visual Basic]
Property Last As IGroup
[C#]
IGroup Last {get;}

Property Value

The last IGroup in the IGroupCollection. If there is none, NULL (Nothing in Visual Basic) is returned.

Example

The following example displays the Name values of all the IForm elements in an IFormCollection.

C# sample

public class Sample
{
    public static void LoadProject()
    {
        suite4.net.FormDatabase.IForm form;
        suite4.net.FormDatabase.IGroup group;
        suite4.net.FormDatabase.IProject project;

        // Load a project from a File
        project = suite4.net.FormDatabase.Project.LoadFromFile(@"C:\sample.fspj");

        // Get the first Group of the Project
        group = project.Groups.First;

        // Get the last Form of the GroupCollection
        form = group.Forms.Last;

        while(form != null)
        {
            System.Console.WriteLine("Display the Name of the form...");
            System.Console.WriteLine(form.Name);
            form = form.Prev;
        }
    }
}

VB.Net sample
Public Class Sample
    Public Shared Sub LoadProject()
        Dim form As suite4.net.FormDataMyBase.IForm
        Dim group As suite4.net.FormDataMyBase.IGroup
        Dim project As suite4.net.FormDataMyBase.IProject

        ' Load a project from a File
        project = suite4.net.FormDataMyBase.Project.LoadFromFile("C:\sample.fspj")

        ' Get the first Group of the Project
        group = project.Groups.First

        ' Get the last Form of the GroupCollection
        form = group.Forms.Last

        While Not form Is Nothing
            System.Console.WriteLine("Display the Name of the form...")
            System.Console.WriteLine(form.Name)
            form = form.Prev
        End While
    End Sub
End Class

See Also

IGroupCollection Interface | suite4.net.FormDatabase Namespace


SortDirection Property

suite4.net.FormDatabase Documentation

IGroupCollection.SortDirection Property

Specifies the direction of a sort operation to be performed on the IGroupCollection.

[Visual Basic]
Property SortDirection As ListSortDirection
[C#]
System.ComponentModel.ListSortDirection SortDirection {get; set;}

Property Value

Gets or sets the ListSortDirection of the IGroupCollection. The default value is Ascending.

See Also

IGroupCollection Interface | suite4.net.FormDatabase Namespace


SortProperty Property

suite4.net.FormDatabase Documentation

IGroupCollection.SortProperty Property

Specifies the IGroup property to be used in a sort operation on the IGroupCollection.

[Visual Basic]
Property SortProperty As GroupSortProperty
[C#]
GroupSortProperty SortProperty {get; set;}

Property Value

Gets or sets the GroupSortProperty of the IGroupCollection. The default value is Name.

Remarks

This property is used in the Sort method in conjunction with the SortDirection property.

See Also

IGroupCollection Interface | suite4.net.FormDatabase Namespace


IGroupCollection Methods

The methods of the IGroupCollection interface are listed below. For a complete list of IGroupCollection interface members, see the IGroupCollection Members topic.

Public Instance Methods

Sort Overloaded. Sorts the elements in the IGroupCollection using the specified SortProperty and SortDirection values.

See Also

IGroupCollection Interface | suite4.net.FormDatabase Namespace


Sort Method

suite4.net.FormDatabase Documentation

IGroupCollection.Sort Method

Sorts the elements in the IGroupCollection.

Overload List

Sorts the elements in the IGroupCollection.

void Sort();

Sorts the elements in the IGroupCollection by the specified SortProperty.

void Sort(GroupSortProperty);

Sorts the elements in the IGroupCollection using the specified SortProperty and SortDirection values.

void Sort(GroupSortProperty,ListSortDirection);

Sorts the elements in the IGroupCollection using the specified direction.

void Sort(ListSortDirection);

See Also

IGroupCollection Interface | suite4.net.FormDatabase Namespace


IGroupCollection.Sort Method ()

Sorts the elements in the IGroupCollection.

[Visual Basic]
Sub Sort()
[C#]
void Sort();

Remarks

The IGroupCollection will be sorted by the value of the SortProperty property and ordered by the value of the SortDirection property.

See Also

IGroupCollection Interface | suite4.net.FormDatabase Namespace | IGroupCollection.Sort Overload List


IGroupCollection.Sort Method (GroupSortProperty)

Sorts the elements in the IGroupCollection by the specified SortProperty.

[Visual Basic]
Sub Sort( _
ByVal sortProperty As GroupSortProperty _
)
[C#]
void Sort(
GroupSortProperty sortProperty
);

Parameters

sortProperty
The SortProperty the collection is to be sorted by.

Remarks

  • The sort direction is determined by the value of the SortDirection.
  • The sortProperty value is stored in the IGroupCollection for later reuse.

See Also

IGroupCollection Interface | suite4.net.FormDatabase Namespace | IGroupCollection.Sort Overload List


IGroupCollection.Sort Method (GroupSortProperty, ListSortDirection)

Sorts the elements in the IGroupCollection using the specified SortProperty and SortDirection values.

[Visual Basic]
Sub Sort( _
ByVal sortProperty As GroupSortProperty, _
ByVal sortDirection As ListSortDirection _
)
[C#]
void Sort(
GroupSortProperty sortProperty,
ListSortDirection sortDirection
);

Parameters

sortProperty
The SortProperty the collection is to be sorted by.
sortDirection
The SortDirection the collection is to be sorted in.

Remarks

Both the sortProperty and the sortDirection values are stored in the IGroupCollection for later reuse.

See Also

IGroupCollection Interface | suite4.net.FormDatabase Namespace | IGroupCollection.Sort Overload List


IGroupCollection.Sort Method (ListSortDirection)

Sorts the elements in the IGroupCollection using the specified direction.

[Visual Basic]
Sub Sort( _
ByVal sortDirection As ListSortDirection _
)
[C#]
void Sort(
ListSortDirection sortDirection
);

Parameters

sortDirection
The SortDirection the collection is to be sorted in.

Remarks

  • The IGroupCollection will be sorted by the property which is specified in the SortProperty value.
  • The sortDirection value is stored in the IGroupCollection for later reuse.

See Also

IGroupCollection Interface | suite4.net.FormDatabase Namespace | IGroupCollection.Sort Overload List


IProject Interface

The main interface of the form.suite4.net FormDatabase. It represents a form.suite4.net project along with its constituent elements, such as forms, tasks and groups.

For a list of all members of this type, see IProject Members.

[Visual Basic]
Public Interface IProject
[C#]
public interface IProject

Requirements

Namespace: suite4.net.FormDatabase

Assembly: suite4.net.FormDatabase (in suite4.net.FormDatabase.dll)

See Also

IProject Members | suite4.net.FormDatabase Namespace


IProject Members

IProject overview

Public Instance Properties

Description | Gets the description of the IProject.
Forms | Gets the IFormCollection that the IProject contains.
Groups | Gets the IGroupCollection that the IProject contains.
ImagePathAbsolute | Gets or sets the (absolute) path to a directory on the server where images contained in IForm instances should be stored.
ImagePathRelative | Gets or sets the (relative) path to the directory where images contained in IForm objects are stored on the web server.
Languages | Gets the languages of the IProject.
LastModification | Gets a DateTime value indicating the time of the last modification to the current IProject.
Name | Gets the name of the IProject.
Namespace | Gets the namespace of the IProject.
Resolutions | Gets the resolutions of the IProject.
Tasks | Gets the tasks associated with this IProject.
UserGroups | Gets the UserGroups of the IProject.

Public Instance Methods

GetForm Returns a reference to an IForm object with a specified name.

See Also

IProject Interface | suite4.net.FormDatabase Namespace


IProject Properties

The properties of the IProject interface are listed below. For a complete list of IProject interface members, see the IProject Members topic.

Public Instance Properties

Description | Gets the description of the IProject.
Forms | Gets the IFormCollection that the IProject contains.
Groups | Gets the IGroupCollection that the IProject contains.
ImagePathAbsolute | Gets or sets the (absolute) path to a directory on the server where images contained in IForm instances should be stored.
ImagePathRelative | Gets or sets the (relative) path to the directory where images contained in IForm objects are stored on the web server.
Languages | Gets the languages of the IProject.
LastModification | Gets a DateTime value indicating the time of the last modification to the current IProject.
Name | Gets the name of the IProject.
Namespace | Gets the namespace of the IProject.
Resolutions | Gets the resolutions of the IProject.
Tasks | Gets the tasks associated with this IProject.
UserGroups | Gets the UserGroups of the IProject.

See Also

IProject Interface | suite4.net.FormDatabase Namespace


Description Property

suite4.net.FormDatabase Documentation

IProject.Description Property

Gets the description of the IProject.

[Visual Basic]
Property Description As String
[C#]
string Description {get;}

Property Value

The description of the IProject.

See Also

IProject Interface | suite4.net.FormDatabase Namespace


Forms Property

suite4.net.FormDatabase Documentation

IProject.Forms Property

Gets the IFormCollection that the IProject contains.

[Visual Basic]
Property Forms As IFormCollection
[C#]
IFormCollection Forms {get;}

Property Value

An IFormCollection of all the Forms that are stored in the IProject.

See Also

IProject Interface | suite4.net.FormDatabase Namespace


Groups Property

suite4.net.FormDatabase Documentation

IProject.Groups Property

Gets the IGroupCollection that the IProject contains.

[Visual Basic]
Property Groups As IGroupCollection
[C#]
IGroupCollection Groups {get;}

Property Value

An IGroupCollection of all the Groups in the project.

See Also

IProject Interface | suite4.net.FormDatabase Namespace


ImagePathAbsolute Property

suite4.net.FormDatabase Documentation

IProject.ImagePathAbsolute Property

Gets or sets the (absolute) path to a directory on the server where images contained in IForm instances should be stored.

[Visual Basic]
Property ImagePathAbsolute As String
[C#]
string ImagePathAbsolute {get; set;}

Property Value

An absolute path to a directory for storing IForm images.

Remarks

This property is used by the SerializeToSwfXml method. If the IForm to be serialized contains images, these need to be written to a directory on the server so they can be dynamically loaded by the WebLoader later on. ImagePathAbsolute provides this directory information to callers.

The ASP.NET process account (ASPNET under Windows 2000, or NETWORK SERVICE under Windows Server 2003, respectively) must be granted write permission on this directory since the FormDatabase will dynamically write any images contained in an IForm instance to this directory when the SerializeToSwfXml method is called.

Example

project.ImagePathAbsolute = Server.MapPath("\\MyImageDir");

See Also

IProject Interface | suite4.net.FormDatabase Namespace


ImagePathRelative Property

suite4.net.FormDatabase Documentation

IProject.ImagePathRelative Property

Gets or sets the (relative) path to the directory where images contained in IForm objects are stored on the web server.

[Visual Basic]
Property ImagePathRelative As String
[C#]
string ImagePathRelative {get; set;}

Property Value

A relative path to the directory where IForm images are stored.

Remarks

The value of this property is used by the Macromedia Flash representation of the IForm to load images from the server that are contained in the IForm.

ImagePathAbsolute and ImagePathRelative (once resolved) have to point to the same directory on the web server.

Example

project.ImagePathRelative = "/MyImageDir";

See Also

IProject Interface | suite4.net.FormDatabase Namespace


Languages Property

suite4.net.FormDatabase Documentation

IProject.Languages Property

Gets the languages of the IProject.

[Visual Basic]
Property Languages As ICollection
[C#]
System.Collections.ICollection Languages {get;}

Property Value

All languages that are used in the IProject are returned in an ICollection.

See Also

IProject Interface | suite4.net.FormDatabase Namespace


LastModification Property

suite4.net.FormDatabase Documentation

IProject.LastModification Property

Gets a DateTime value indicating the time of the last modification to the current IProject.

[Visual Basic]
Property LastModification As Date
[C#]
System.DateTime LastModification {get;}

Property Value

The time of the most recent modification to the current IProject.

Example

The following example demonstrates how to load an IProject and get a reference to an IForm.

C# sample

using System;
using System.IO;
using suite4.net.FormDatabase;
namespace suite4.net.Sample
{
    public class Project
    {
        private IProject _project;
        public Project()
        {
        }
        public suite4.net.FormDatabase.IForm GetIForm(string formName)
        {
            FileInfo    fileInfo;
            if(this._project == null)
            {
                this._project = suite4.net.FormDatabase.Project.LoadFromFile("sample.fspj");
            }
            else
            {
                fileInfo = new FileInfo("sample.fspj");
                if(fileInfo.LastWriteTime > this._project.LastModification)
                {
                    // Reload the project if the project has been changed.
                    // This can be done during runtime.
                    this._project = suite4.net.FormDatabase.Project.LoadFromFile("sample.fspj");
                }
            }
            if(this._project != null)
            {
                return this._project.GetForm(formName);
            }
            return null;
        }
    }
}

VB.Net sample
Imports System
Imports System.IO
Imports suite4.net.FormDatabase
Namespace suite4.net.Sample
    Public Class Project
        Private _project As IProject
        Public  Sub New()
        End Sub
        Public Function GetIForm(ByVal formName As String) As suite4.net.FormDataMyBase.IForm
            Dim fileInfo As FileInfo
            If Me._project Is Nothing Then
                Me._project = suite4.net.FormDataMyBase.Project.LoadFromFile("sample.fspj")
            Else
                fileInfo = New FileInfo("sample.fspj")
                If fileInfo.LastWriteTime > Me._project.LastModification Then
                    ' Reload the project if the project has been changed.
                    ' This can be done during runtime.
                    Me._project = suite4.net.FormDataMyBase.Project.LoadFromFile("sample.fspj")
                End If
            End If
            If Not Me._project Is Nothing Then
                Return Me._project.GetForm(formName)
            End If
            Return Nothing
        End Function
    End Class
End Namespace

See Also

IProject Interface | suite4.net.FormDatabase Namespace


Name Property

suite4.net.FormDatabase Documentation

IProject.Name Property

Gets the name of the IProject.

[Visual Basic]
Property Name As String
[C#]
string Name {get;}

Property Value

The name of the IProject.

Remarks

The name value can only be changed in the form.suite4.net designer.

See Also

IProject Interface | suite4.net.FormDatabase Namespace


Namespace Property

suite4.net.FormDatabase Documentation

IProject.Namespace Property

Gets the namespace of the IProject.

[Visual Basic]
Property Namespace As String
[C#]
string Namespace {get;}

Property Value

The namespace of the IProject.

Remarks

The namespace can only be changed in the form.suite4.net designer.

See Also

IProject Interface | suite4.net.FormDatabase Namespace


Resolutions Property

suite4.net.FormDatabase Documentation

IProject.Resolutions Property

Gets the resolutions of the IProject.

[Visual Basic]
Property Resolutions As ICollection
[C#]
System.Collections.ICollection Resolutions {get;}

Property Value

All resolutions that are used in the IProject are returned in an ICollection

See Also

IProject Interface | suite4.net.FormDatabase Namespace


Tasks Property

suite4.net.FormDatabase Documentation

IProject.Tasks Property

Gets the tasks associated with this IProject.

[Visual Basic]
Property Tasks As ITaskCollection
[C#]
ITaskCollection Tasks {get;}

Property Value

An ITaskCollection containing all the ITask elements assigned to this IProject.

See Also

IProject Interface | suite4.net.FormDatabase Namespace


UserGroups Property

suite4.net.FormDatabase Documentation

IProject.UserGroups Property

Gets the UserGroups of the IProject.

[Visual Basic]
Property UserGroups As ICollection
[C#]
System.Collections.ICollection UserGroups {get;}

Property Value

All UserGroups that are used in the IProject are returned in an ICollection

See Also

IProject Interface | suite4.net.FormDatabase Namespace


IProject Methods

The methods of the IProject interface are listed below. For a complete list of IProject interface members, see the IProject Members topic.

Public Instance Methods

GetForm Returns a reference to an IForm object with a specified name.

See Also

IProject Interface | suite4.net.FormDatabase Namespace


IProject.GetForm Method

Returns a reference to an IForm object with a specified name.

[Visual Basic]
Function GetForm( _
ByVal formName As String _
) As IForm
[C#]
IForm GetForm(
string formName
);

Parameters

formName
The name of the IForm. The formName value can be both the FullName or the Name of an IForm.

Return Value

A reference to an IForm object.

Example

The following example demonstrates how to load an IProject and get a reference to an IForm.

C# sample

using System;
using System.IO;
using suite4.net.FormDatabase;
namespace suite4.net.Sample
{
    public class Project
    {
        private IProject _project;
        public Project()
        {
        }
        public suite4.net.FormDatabase.IForm GetIForm(string formName)
        {
            FileInfo    fileInfo;
            if(this._project == null)
            {
                this._project = suite4.net.FormDatabase.Project.LoadFromFile("sample.fspj");
            }
            else
            {
                fileInfo = new FileInfo("sample.fspj");
                if(fileInfo.LastWriteTime > this._project.LastModification)
                {
                    // Reload the project if the project has been changed.
                    // This can be done during runtime.
                    this._project = suite4.net.FormDatabase.Project.LoadFromFile("sample.fspj");
                }
            }
            if(this._project != null)
            {
                return this._project.GetForm(formName);
            }
            return null;
        }
    }
}

VB.Net sample
Imports System
Imports System.IO
Imports suite4.net.FormDatabase
Namespace suite4.net.Sample
    Public Class Project
        Private _project As IProject
        Public  Sub New()
        End Sub
        Public Function GetIForm(ByVal formName As String) As suite4.net.FormDataMyBase.IForm
            Dim fileInfo As FileInfo
            If Me._project Is Nothing Then
                Me._project = suite4.net.FormDataMyBase.Project.LoadFromFile("sample.fspj")
            Else
                fileInfo = New FileInfo("sample.fspj")
                If fileInfo.LastWriteTime > Me._project.LastModification Then
                    ' Reload the project if the project has been changed.
                    ' This can be done during runtime.
                    Me._project = suite4.net.FormDataMyBase.Project.LoadFromFile("sample.fspj")
                End If
            End If
            If Not Me._project Is Nothing Then
                Return Me._project.GetForm(formName)
            End If
            Return Nothing
        End Function
    End Class
End Namespace

See Also

IProject Interface | suite4.net.FormDatabase Namespace


ITask Interface

Represents a task object which is contained in an ITaskCollection.

For a list of all members of this type, see ITask Members.

[Visual Basic]
Public Interface ITask
[C#]
public interface ITask

Requirements

Namespace: suite4.net.FormDatabase

Assembly: suite4.net.FormDatabase (in suite4.net.FormDatabase.dll)

See Also

ITask Members | suite4.net.FormDatabase Namespace


ITask Members

ITask overview

Public Instance Properties

AssignedTo | Gets the AssignedTo value of the ITask in the ITaskCollection.
Description | Gets the description of the ITask in the ITaskCollection.
Index | Gets the index of the ITask in the ITaskCollection.
Next | Gets the next ITask in the ITaskCollection.
Prev | Gets the previous ITask in the ITaskCollection.
Priority | Gets the Priority of the ITask in the ITaskCollection.
TaskType | Gets the TaskType value of the ITask in then ITaskCollection.
Title | Gets the title of the ITask in the ITaskCollection.

See Also

ITask Interface | suite4.net.FormDatabase Namespace


ITask Properties

The properties of the ITask interface are listed below. For a complete list of ITask interface members, see the ITask Members topic.

Public Instance Properties

AssignedTo | Gets the AssignedTo value of the ITask in the ITaskCollection.
Description | Gets the description of the ITask in the ITaskCollection.
Index | Gets the index of the ITask in the ITaskCollection.
Next | Gets the next ITask in the ITaskCollection.
Prev | Gets the previous ITask in the ITaskCollection.
Priority | Gets the Priority of the ITask in the ITaskCollection.
TaskType | Gets the TaskType value of the ITask in then ITaskCollection.
Title | Gets the title of the ITask in the ITaskCollection.

See Also

ITask Interface | suite4.net.FormDatabase Namespace


AssignedTo Property

suite4.net.FormDatabase Documentation

ITask.AssignedTo Property

Gets the AssignedTo value of the ITask in the ITaskCollection.

[Visual Basic]
Property AssignedTo As AssignedTo
[C#]
AssignedTo AssignedTo {get;}

Property Value

The AssignedTo value of the ITask.

See Also

ITask Interface | suite4.net.FormDatabase Namespace


Description Property

suite4.net.FormDatabase Documentation

ITask.Description Property

Gets the description of the ITask in the ITaskCollection.

[Visual Basic]
Property Description As String
[C#]
string Description {get;}

Property Value

The description of the ITask.

See Also

ITask Interface | suite4.net.FormDatabase Namespace


Index Property

suite4.net.FormDatabase Documentation

ITask.Index Property

Gets the index of the ITask in the ITaskCollection.

[Visual Basic]
Property Index As Integer
[C#]
int Index {get;}

Property Value

The index of the ITask object.

See Also

ITask Interface | suite4.net.FormDatabase Namespace


Next Property

suite4.net.FormDatabase Documentation

ITask.Next Property

Gets the next ITask in the ITaskCollection.

[Visual Basic]
Property Next As ITask
[C#]
ITask Next {get;}

Property Value

A reference to the next ITask, or NULL (Nothing in Visual Basic) if the ITask is the last element of the ITaskCollection.

Example

The following example displays the Name values of all the IForm elements in an IFormCollection.

C# sample

public class Sample
{
    public static void LoadProject()
    {
        suite4.net.FormDatabase.IForm form;
        suite4.net.FormDatabase.IGroup group;
        suite4.net.FormDatabase.IProject project;

        // Load a project from a File
        project = suite4.net.FormDatabase.Project.LoadFromFile(@"C:\sample.fspj");

        // Get the first Group of the Project
        group = project.Groups.First;

        // Get the first Form of the GroupCollection
        form = group.Forms.First;

        while(form != null)
        {
            System.Console.WriteLine("Display the Name of the form...");
            System.Console.WriteLine(form.Name);
            form = form.Next;
        }
    }
}

VB.Net sample
Public Class Sample
    Public Shared Sub LoadProject()
        Dim form As suite4.net.FormDataMyBase.IForm
        Dim group As suite4.net.FormDataMyBase.IGroup
        Dim project As suite4.net.FormDataMyBase.IProject

        ' Load a project from a File
        project = suite4.net.FormDataMyBase.Project.LoadFromFile("C:\sample.fspj")

        ' Get the first Group of the Project
        group = project.Groups.First

        ' Get the first Form of the GroupCollection
        form = group.Forms.First

        While Not form Is Nothing
            System.Console.WriteLine("Display the Name of the form...")
            System.Console.WriteLine(form.Name)
            form = form.Next
        End While
    End Sub
End Class

See Also

ITask Interface | suite4.net.FormDatabase Namespace


Prev Property

suite4.net.FormDatabase Documentation

ITask.Prev Property

Gets the previous ITask in the ITaskCollection.

[Visual Basic]
Property Prev As ITask
[C#]
ITask Prev {get;}

Property Value

A reference to the previous ITask, or NULL (Nothing in Visual Basic) if the ITask is the first element of the ITaskCollection.

Example

The following example displays the Name values of all the IForm elements in an IFormCollection.

C# sample

public class Sample
{
    public static void LoadProject()
    {
        suite4.net.FormDatabase.IForm form;
        suite4.net.FormDatabase.IGroup group;
        suite4.net.FormDatabase.IProject project;

        // Load a project from a File
        project = suite4.net.FormDatabase.Project.LoadFromFile(@"C:\sample.fspj");

        // Get the first Group of the Project
        group = project.Groups.First;

        // Get the last Form of the GroupCollection
        form = group.Forms.Last;

        while(form != null)
        {
            System.Console.WriteLine("Display the Name of the form...");
            System.Console.WriteLine(form.Name);
            form = form.Prev;
        }
    }
}

VB.Net sample
Public Class Sample
    Public Shared Sub LoadProject()
        Dim form As suite4.net.FormDataMyBase.IForm
        Dim group As suite4.net.FormDataMyBase.IGroup
        Dim project As suite4.net.FormDataMyBase.IProject

        ' Load a project from a File
        project = suite4.net.FormDataMyBase.Project.LoadFromFile("C:\sample.fspj")

        ' Get the first Group of the Project
        group = project.Groups.First

        ' Get the last Form of the GroupCollection
        form = group.Forms.Last

        While Not form Is Nothing
            System.Console.WriteLine("Display the Name of the form...")
            System.Console.WriteLine(form.Name)
            form = form.Prev
        End While
    End Sub
End Class

See Also

ITask Interface | suite4.net.FormDatabase Namespace


Priority Property

suite4.net.FormDatabase Documentation

ITask.Priority Property

Gets the Priority of the ITask in the ITaskCollection.

[Visual Basic]
Property Priority As Priority
[C#]
Priority Priority {get;}

Property Value

The priority of the ITask.

See Also

ITask Interface | suite4.net.FormDatabase Namespace


TaskType Property

suite4.net.FormDatabase Documentation

ITask.TaskType Property

Gets the TaskType value of the ITask in then ITaskCollection.

[Visual Basic]
Property TaskType As TaskType
[C#]
TaskType TaskType {get;}

Property Value

The TaskType value of the ITask.

See Also

ITask Interface | suite4.net.FormDatabase Namespace


Title Property

suite4.net.FormDatabase Documentation

ITask.Title Property

Gets the title of the ITask in the ITaskCollection.

[Visual Basic]
Property Title As String
[C#]
string Title {get;}

Property Value

The title of the ITask.

See Also

ITask Interface | suite4.net.FormDatabase Namespace


ITaskCollection Interface

Represents a collection of ITask objects.

For a list of all members of this type, see ITaskCollection Members.

[Visual Basic]
Public Interface ITaskCollection
Implements ICollection, IEnumerable
[C#]
public interface ITaskCollection : ICollection, IEnumerable

Remarks

This collection can only contain objects of type ITask.

Requirements

Namespace: suite4.net.FormDatabase

Assembly: suite4.net.FormDatabase (in suite4.net.FormDatabase.dll)

See Also

ITaskCollection Members | suite4.net.FormDatabase Namespace


ITaskCollection Members

ITaskCollection overview

Public Instance Properties

First | Gets the first ITask in the ITaskCollection.
Item | Gets the ITask element at the specified index.
Last | Gets the last ITask in the ITaskCollection.
SortDirection | Specifies the direction of a sort operation to be performed on the ITaskCollection.
SortProperty | Specifies the ITask property to be used in a sort operation on the ITaskCollection.

Public Instance Methods

Sort Overloaded. Sorts the elements in the ITaskCollection using the specified SortProperty and SortDirection values.

See Also

ITaskCollection Interface | suite4.net.FormDatabase Namespace


ITaskCollection Properties

The properties of the ITaskCollection interface are listed below. For a complete list of ITaskCollection interface members, see the ITaskCollection Members topic.

Public Instance Properties

First | Gets the first ITask in the ITaskCollection.
Item | Gets the ITask element at the specified index.
Last | Gets the last ITask in the ITaskCollection.
SortDirection | Specifies the direction of a sort operation to be performed on the ITaskCollection.
SortProperty | Specifies the ITask property to be used in a sort operation on the ITaskCollection.

See Also

ITaskCollection Interface | suite4.net.FormDatabase Namespace


First Property

suite4.net.FormDatabase Documentation

ITaskCollection.First Property

Gets the first ITask in the ITaskCollection.

[Visual Basic]
Property First As ITask
[C#]
ITask First {get;}

Property Value

The first ITask in the ITaskCollection. If there is none, NULL (Nothing in Visual Basic) is returned.

Example

The following example displays the Name values of all the IForm elements in an IFormCollection.

C# sample

public class Sample
{
    public static void LoadProject()
    {
        suite4.net.FormDatabase.IForm form;
        suite4.net.FormDatabase.IGroup group;
        suite4.net.FormDatabase.IProject project;

        // Load a project from a File
        project = suite4.net.FormDatabase.Project.LoadFromFile(@"C:\sample.fspj");

        // Get the first Group of the Project
        group = project.Groups.First;

        // Get the first Form of the GroupCollection
        form = group.Forms.First;

        while(form != null)
        {
            System.Console.WriteLine("Display the Name of the form...");
            System.Console.WriteLine(form.Name);
            form = form.Next;
        }
    }
}

VB.Net sample
Public Class Sample
    Public Shared Sub LoadProject()
        Dim form As suite4.net.FormDataMyBase.IForm
        Dim group As suite4.net.FormDataMyBase.IGroup
        Dim project As suite4.net.FormDataMyBase.IProject

        ' Load a project from a File
        project = suite4.net.FormDataMyBase.Project.LoadFromFile("C:\sample.fspj")

        ' Get the first Group of the Project
        group = project.Groups.First

        ' Get the first Form of the GroupCollection
        form = group.Forms.First

        While Not form Is Nothing
            System.Console.WriteLine("Display the Name of the form...")
            System.Console.WriteLine(form.Name)
            form = form.Next
        End While
    End Sub
End Class

See Also

ITaskCollection Interface | suite4.net.FormDatabase Namespace


Item Property

suite4.net.FormDatabase Documentation

ITaskCollection.Item Property

Gets the ITask element at the specified index.

[Visual Basic]
Property Item( _
ByVal index As Integer _
) As ITask
[C#]
ITask this[
int index
] {get;}

Parameters

index
The index value of the ITask to get.

Exceptions

Exception Type | Condition
ArgumentOutOfRangeException | No element exists at the specified index position in the ITaskCollection.

See Also

ITaskCollection Interface | suite4.net.FormDatabase Namespace


Last Property

suite4.net.FormDatabase Documentation

ITaskCollection.Last Property

Gets the last ITask in the ITaskCollection.

[Visual Basic]
Property Last As ITask
[C#]
ITask Last {get;}

Property Value

The last ITask in the ITaskCollection. If there is none, NULL (Nothing in Visual Basic) is returned.

Example

The following example displays the Name values of all the IForm elements in an IFormCollection.

C# sample

public class Sample
{
    public static void LoadProject()
    {
        suite4.net.FormDatabase.IForm form;
        suite4.net.FormDatabase.IGroup group;
        suite4.net.FormDatabase.IProject project;

        // Load a project from a File
        project = suite4.net.FormDatabase.Project.LoadFromFile(@"C:\sample.fspj");

        // Get the first Group of the Project
        group = project.Groups.First;

        // Get the last Form of the GroupCollection
        form = group.Forms.Last;

        while(form != null)
        {
            System.Console.WriteLine("Display the Name of the form...");
            System.Console.WriteLine(form.Name);
            form = form.Prev;
        }
    }
}

VB.Net sample
Public Class Sample
    Public Shared Sub LoadProject()
        Dim form As suite4.net.FormDataMyBase.IForm
        Dim group As suite4.net.FormDataMyBase.IGroup
        Dim project As suite4.net.FormDataMyBase.IProject

        ' Load a project from a File
        project = suite4.net.FormDataMyBase.Project.LoadFromFile("C:\sample.fspj")

        ' Get the first Group of the Project
        group = project.Groups.First

        ' Get the last Form of the GroupCollection
        form = group.Forms.Last

        While Not form Is Nothing
            System.Console.WriteLine("Display the Name of the form...")
            System.Console.WriteLine(form.Name)
            form = form.Prev
        End While
    End Sub
End Class

See Also

ITaskCollection Interface | suite4.net.FormDatabase Namespace


SortDirection Property

suite4.net.FormDatabase Documentation

ITaskCollection.SortDirection Property

Specifies the direction of a sort operation to be performed on the ITaskCollection.

[Visual Basic]
Property SortDirection As ListSortDirection
[C#]
System.ComponentModel.ListSortDirection SortDirection {get; set;}

Property Value

Gets or sets the ListSortDirection of the ITaskCollection. The default value is Ascending.

See Also

ITaskCollection Interface | suite4.net.FormDatabase Namespace


SortProperty Property

suite4.net.FormDatabase Documentation

ITaskCollection.SortProperty Property

Specifies the ITask property to be used in a sort operation on the ITaskCollection.

[Visual Basic]
Property SortProperty As TaskSortProperty
[C#]
TaskSortProperty SortProperty {get; set;}

Property Value

Gets or sets the TaskSortProperty of the ITaskCollection. The default value is Title.

Remarks

This property is used in the Sort method in conjunction with the SortDirection property.

See Also

ITaskCollection Interface | suite4.net.FormDatabase Namespace


ITaskCollection Methods

The methods of the ITaskCollection interface are listed below. For a complete list of ITaskCollection interface members, see the ITaskCollection Members topic.

Public Instance Methods

Sort Overloaded. Sorts the elements in the ITaskCollection using the specified SortProperty and SortDirection values.

See Also

ITaskCollection Interface | suite4.net.FormDatabase Namespace


Sort Method

suite4.net.FormDatabase Documentation

ITaskCollection.Sort Method

Sorts the elements in the ITaskCollection.

Overload List

Sorts the elements in the ITaskCollection.

void Sort();

Sorts the elements in the ITaskCollection by the specified SortProperty.

void Sort(TaskSortProperty);

Sorts the elements in the ITaskCollection using the specified SortProperty and SortDirection values.

void Sort(TaskSortProperty,ListSortDirection);

Sorts the elements in the ITaskCollection using the specified direction.

void Sort(ListSortDirection);

See Also

ITaskCollection Interface | suite4.net.FormDatabase Namespace


ITaskCollection.Sort Method ()

Sorts the elements in the ITaskCollection.

[Visual Basic]
Sub Sort()
[C#]
void Sort();

Remarks

The ITaskCollection will be sorted by the value of the SortProperty property and ordered by the value of the SortDirection property.

See Also

ITaskCollection Interface | suite4.net.FormDatabase Namespace | ITaskCollection.Sort Overload List


ITaskCollection.Sort Method (TaskSortProperty)

Sorts the elements in the ITaskCollection by the specified SortProperty.

[Visual Basic]
Sub Sort( _
ByVal sortProperty As TaskSortProperty _
)
[C#]
void Sort(
TaskSortProperty sortProperty
);

Parameters

sortProperty
The SortProperty the collection is to be sorted by.

Remarks

  • The sort direction is determined by the value of the SortDirection.
  • The sortProperty value is stored in the ITaskCollection for later reuse.

See Also

ITaskCollection Interface | suite4.net.FormDatabase Namespace | ITaskCollection.Sort Overload List


ITaskCollection.Sort Method (TaskSortProperty, ListSortDirection)

Sorts the elements in the ITaskCollection using the specified SortProperty and SortDirection values.

[Visual Basic]
Sub Sort( _
ByVal sortProperty As TaskSortProperty, _
ByVal sortDirection As ListSortDirection _
)
[C#]
void Sort(
TaskSortProperty sortProperty,
ListSortDirection sortDirection
);

Parameters

sortProperty
The SortProperty the collection is to be sorted by.
sortDirection
The SortDirection the collection is to be sorted in.

Remarks

Both the sortProperty and the sortDirection values are stored in the ITaskCollection for later reuse.

See Also

ITaskCollection Interface | suite4.net.FormDatabase Namespace | ITaskCollection.Sort Overload List


ITaskCollection.Sort Method (ListSortDirection)

Sorts the elements in the ITaskCollection using the specified direction.

[Visual Basic]
Sub Sort( _
ByVal sortDirection As ListSortDirection _
)
[C#]
void Sort(
ListSortDirection sortDirection
);

Parameters

sortDirection
The SortDirection the collection is to be sorted in.

Remarks

  • The ITaskCollection will be sorted by the property which is specified in the SortProperty value.
  • The sortDirection value is stored in the ITaskCollection for later reuse.

See Also

ITaskCollection Interface | suite4.net.FormDatabase Namespace | ITaskCollection.Sort Overload List


IWebLoaderEvent Interface

Represents an event that can be raised by a control on an IForm that has been loaded into a web page using the WebLoader component.

For a list of all members of this type, see IWebLoaderEvent Members.

[Visual Basic]
Public Interface IWebLoaderEvent
[C#]
public interface IWebLoaderEvent

Requirements

Namespace: suite4.net.FormDatabase

Assembly: suite4.net.FormDatabase (in suite4.net.FormDatabase.dll)

See Also

IWebLoaderEvent Members | suite4.net.FormDatabase Namespace


IWebLoaderEvent Members

IWebLoaderEvent overview

Public Instance Properties

EventName | Gets the name of the IWebLoaderEvent.
EventType | Gets the WebLoaderEventType of the IWebLoaderEvent interface.
Operation | Gets or sets the method or operation name to be called in handling the IWebLoaderEvent.
Parameters | Gets the Parameters associated with the IWebLoaderEvent.
WsdlUrl | Gets or sets the URL to a WSDL document describing the web service that is going to be called in the IWebLoaderEvent handler.

Public Instance Methods

AddParameter | Overloaded. Adds a (user-defined) IWebLoaderEventParameter instance to the Parameters collection.
ClearParameters | Empties the Parameters collection.

See Also

IWebLoaderEvent Interface | suite4.net.FormDatabase Namespace


IWebLoaderEvent Properties

The properties of the IWebLoaderEvent interface are listed below. For a complete list of IWebLoaderEvent interface members, see the IWebLoaderEvent Members topic.

Public Instance Properties

EventName | Gets the name of the IWebLoaderEvent.
EventType | Gets the WebLoaderEventType of the IWebLoaderEvent interface.
Operation | Gets or sets the method or operation name to be called in handling the IWebLoaderEvent.
Parameters | Gets the Parameters associated with the IWebLoaderEvent.
WsdlUrl | Gets or sets the URL to a WSDL document describing the web service that is going to be called in the IWebLoaderEvent handler.

See Also

IWebLoaderEvent Interface | suite4.net.FormDatabase Namespace


EventName Property

suite4.net.FormDatabase Documentation

IWebLoaderEvent.EventName Property

Gets the name of the IWebLoaderEvent.

[Visual Basic]
Property EventName As String
[C#]
string EventName {get;}

Property Value

The name of the IWebLoaderEvent.

See Also

IWebLoaderEvent Interface | suite4.net.FormDatabase Namespace


EventType Property

suite4.net.FormDatabase Documentation

IWebLoaderEvent.EventType Property

Gets the WebLoaderEventType of the IWebLoaderEvent interface.

[Visual Basic]
Property EventType As WebLoaderEventType
[C#]
WebLoaderEventType EventType {get;}

Property Value

The WebLoaderEventType of the IWebLoaderEvent interface

See Also

IWebLoaderEvent Interface | suite4.net.FormDatabase Namespace


Operation Property

suite4.net.FormDatabase Documentation

IWebLoaderEvent.Operation Property

Gets or sets the method or operation name to be called in handling the IWebLoaderEvent.

[Visual Basic]
Property Operation As String
[C#]
string Operation {get; set;}

Property Value

Depending on the value of WebLoaderEventType, this property returns the name of either a web service operation or a client-side JavaScript method.

Example

The value is the method name only, without parameters or parentheses, such as:

GetForm

See Also

IWebLoaderEvent Interface | suite4.net.FormDatabase Namespace


Parameters Property

suite4.net.FormDatabase Documentation

IWebLoaderEvent.Parameters Property

Gets the Parameters associated with the IWebLoaderEvent.

[Visual Basic]
Property Parameters As ICollection
[C#]
System.Collections.ICollection Parameters {get;}

Property Value

An ICollection containing all IWebLoaderEventParameter instances that are associated with the IWebLoaderEvent interface.

Remarks

Adding parameters to the collection is achieved by calling the AddParameter method.

See Also

IWebLoaderEvent Interface | suite4.net.FormDatabase Namespace


WsdlUrl Property

suite4.net.FormDatabase Documentation

IWebLoaderEvent.WsdlUrl Property

Gets or sets the URL to a WSDL document describing the web service that is going to be called in the IWebLoaderEvent handler.

[Visual Basic]
Property WsdlUrl As String
[C#]
string WsdlUrl {get; set;}

Property Value

The path to a WSDL document containing the formal description of a web service that is to be called in handling the IWebLoaderEvent.

Remarks

A WSDL (Web Services Description Language) document represents the formal description of a web service. The URL should contain a root-relative path to the document (see the example). This way, the server name is not included in the URL and modifications of the WsdlUrl value can be avoided when moving the application from a staging to a production environment.

Example

Root-relative URL for a .NET web service:

/FormServer/FormServer.asmx?wsdl

See Also

IWebLoaderEvent Interface | suite4.net.FormDatabase Namespace


IWebLoaderEvent Methods

The methods of the IWebLoaderEvent interface are listed below. For a complete list of IWebLoaderEvent interface members, see the IWebLoaderEvent Members topic.

Public Instance Methods

AddParameter | Overloaded. Adds a (user-defined) IWebLoaderEventParameter instance to the Parameters collection.
ClearParameters | Empties the Parameters collection.

See Also

IWebLoaderEvent Interface | suite4.net.FormDatabase Namespace


AddParameter Method

suite4.net.FormDatabase Documentation

IWebLoaderEvent.AddParameter Method

Adds an IWebLoaderEventParameter instance to the Parameters collection.

Overload List

Adds an IWebLoaderEventParameter instance to the Parameters collection.

void AddParameter(WebLoaderParameterType);

Adds a (user-defined) IWebLoaderEventParameter instance to the Parameters collection.

void AddParameter(WebLoaderParameterType,string);

See Also

IWebLoaderEvent Interface | suite4.net.FormDatabase Namespace


IWebLoaderEvent.AddParameter Method (WebLoaderParameterType)

Adds an IWebLoaderEventParameter instance to the Parameters collection.

[Visual Basic]
Sub AddParameter( _
ByVal parameterType As WebLoaderParameterType _
)
[C#]
void AddParameter(
WebLoaderParameterType parameterType
);

Parameters

parameterType
The WebLoaderParameterType of the IWebLoaderEventParameter.

Remarks

Use this overload to add parameters with a WebLoaderParameterType other than UserDefined to the Parameters collection.

See Also

IWebLoaderEvent Interface | suite4.net.FormDatabase Namespace | IWebLoaderEvent.AddParameter Overload List


IWebLoaderEvent.AddParameter Method (WebLoaderParameterType, String)

Adds a (user-defined) IWebLoaderEventParameter instance to the Parameters collection.

[Visual Basic]
Sub AddParameter( _
ByVal parameterType As WebLoaderParameterType, _
ByVal parameterValue As String _
)
[C#]
void AddParameter(
WebLoaderParameterType parameterType,
string parameterValue
);

Parameters

parameterType
The WebLoaderParameterType of the IWebLoaderEventParameter.
parameterValue
The value assigned to parameterType.

Remarks

Use this overload to add a user-defined parameter to the Parameters collection.

See Also

IWebLoaderEvent Interface | suite4.net.FormDatabase Namespace | IWebLoaderEvent.AddParameter Overload List


IWebLoaderEvent.ClearParameters Method

Empties the Parameters collection.

[Visual Basic]
Sub ClearParameters()
[C#]
void ClearParameters();

See Also

IWebLoaderEvent Interface | suite4.net.FormDatabase Namespace


IWebLoaderEventParameter Interface

Represents a parameter for the IWebLoaderEvent.

For a list of all members of this type, see IWebLoaderEventParameter Members.

[Visual Basic]
Public Interface IWebLoaderEventParameter
[C#]
public interface IWebLoaderEventParameter

Requirements

Namespace: suite4.net.FormDatabase

Assembly: suite4.net.FormDatabase (in suite4.net.FormDatabase.dll)

See Also

IWebLoaderEventParameter Members | suite4.net.FormDatabase Namespace


IWebLoaderEventParameter Members

IWebLoaderEventParameter overview

Public Instance Properties

Parameter | Gets the value of a user-defined parameter for the IWebLoaderEvent.
ParameterType | Gets the WebLoaderParameterType of the IWebLoaderEventParameter.

See Also

IWebLoaderEventParameter Interface | suite4.net.FormDatabase Namespace


IWebLoaderEventParameter Properties

The properties of the IWebLoaderEventParameter interface are listed below. For a complete list of IWebLoaderEventParameter interface members, see the IWebLoaderEventParameter Members topic.

Public Instance Properties

Parameter | Gets the value of a user-defined parameter for the IWebLoaderEvent.
ParameterType | Gets the WebLoaderParameterType of the IWebLoaderEventParameter.

See Also

IWebLoaderEventParameter Interface | suite4.net.FormDatabase Namespace


Parameter Property

suite4.net.FormDatabase Documentation

IWebLoaderEventParameter.Parameter Property

Gets the value of a user-defined parameter for the IWebLoaderEvent.

[Visual Basic]
Property Parameter As String
[C#]
string Parameter {get;}

Property Value

The value of the user-defined parameter (if the value of ParameterType is UserDefined) or NULL (Nothing in Visual Basic).

Remarks

The parameter is only provided to the WebLoader when the ParameterType is set to UserDefined.

See Also

IWebLoaderEventParameter Interface | suite4.net.FormDatabase Namespace


ParameterType Property

suite4.net.FormDatabase Documentation

IWebLoaderEventParameter.ParameterType Property

Gets the WebLoaderParameterType of the IWebLoaderEventParameter.

[Visual Basic]
Property ParameterType As WebLoaderParameterType
[C#]
WebLoaderParameterType ParameterType {get;}

Property Value

The WebLoaderParameterType value of the IWebLoaderEventParameter instance.

See Also

IWebLoaderEventParameter Interface | suite4.net.FormDatabase Namespace


LoaderControl Class

The LoaderControl is a container which an IForm can be loaded into for display in a Windows Forms application.

For a list of all members of this type, see LoaderControl Members.

System.Object
System.MarshalByRefObject
System.ComponentModel.Component
System.Windows.Forms.Control
suite4.net.FormDatabase.LoaderControl

[Visual Basic]
Public Class LoaderControl
Inherits Control
[C#]
public class LoaderControl : Control

Thread Safety

Public static (Shared in Visual Basic) members of this type are safe for multithreaded operations. Instance members are not guaranteed to be thread-safe.

Requirements

Namespace: suite4.net.FormDatabase

Assembly: suite4.net.FormDatabase (in suite4.net.FormDatabase.dll)

See Also

LoaderControl Members | suite4.net.FormDatabase Namespace


LoaderControl Members

LoaderControl overview

Public Instance Constructors

LoaderControl Overloaded. Initializes a new instance of the LoaderControl class.

Public Instance Properties

AccessibilityObject (inherited from Control) |
AccessibleDefaultActionDescription (inherited from Control) |
AccessibleDescription (inherited from Control) |
AccessibleName (inherited from Control) |
AccessibleRole (inherited from Control) |
AllowDrop (inherited from Control) |
AllowEvents | Gets or sets a Boolean value determining whether or not the DirtyChanged event will be raised.
Anchor (inherited from Control) |
BackColor (inherited from Control) |
BackgroundImage (inherited from Control) |
BindingContext (inherited from Control) |
Bottom (inherited from Control) |
Bounds (inherited from Control) |
CanFocus (inherited from Control) |
CanSelect (inherited from Control) |
Capture (inherited from Control) |
CausesValidation (inherited from Control) |
ClientRectangle (inherited from Control) |
ClientSize (inherited from Control) |
CompanyName (inherited from Control) |
Container (inherited from Component) |
ContainsFocus (inherited from Control) |
ContextMenu (inherited from Control) |
Controls (inherited from Control) |
Created (inherited from Control) |
Cursor (inherited from Control) |
DataBindings (inherited from Control) |
DataSource | Gets the business class instance which is the data source of the MemberForm.
DisplayRectangle (inherited from Control) |
Disposing (inherited from Control) |
Dock (inherited from Control) |
Enabled (inherited from Control) |
Focused (inherited from Control) |
Font (inherited from Control) |
ForeColor (inherited from Control) |
Handle (inherited from Control) |
HasChildren (inherited from Control) |
Height (inherited from Control) |
ImeMode (inherited from Control) |
InvokeRequired (inherited from Control) |
IsAccessible (inherited from Control) |
IsDirty | Gets a Boolean value that informs the caller whether the user has made changes to the values displayed in the MemberForm.
IsDisposed (inherited from Control) |
IsHandleCreated (inherited from Control) |
Left (inherited from Control) |
Location (inherited from Control) |
MemberForm | Gets the IForm hosted by the LoaderControl.
Name (inherited from Control) |
Parent (inherited from Control) |
ProductName (inherited from Control) |
ProductVersion (inherited from Control) |
RecreatingHandle (inherited from Control) |
Region (inherited from Control) |
Right (inherited from Control) |
RightToLeft (inherited from Control) |
RootControl | Gets the Form or UserControl that has been set as the base control for modification by the LoaderControl's IForm.
Site (inherited from Control) |
Size (inherited from Control) |
TabIndex (inherited from Control) |
TabStop (inherited from Control) |
Tag (inherited from Control) |
Text (inherited from Control) |
Top (inherited from Control) |
TopLevelControl (inherited from Control) |
Visible (inherited from Control) |
Width (inherited from Control) |
WindowTarget (inherited from Control) |

Public Instance Methods

BeginInvoke (inherited from Control) | Overloaded.
BringToFront (inherited from Control) |
Contains (inherited from Control) |
CreateControl (inherited from Control) |
CreateGraphics (inherited from Control) |
CreateObjRef (inherited from MarshalByRefObject) |
Dispose (inherited from Component) |
DoDragDrop (inherited from Control) |
EndInvoke (inherited from Control) |
Equals (inherited from Object) |
FindForm (inherited from Control) |
Focus (inherited from Control) |
GetChildAtPoint (inherited from Control) |
GetContainerControl (inherited from Control) |
GetHashCode (inherited from Object) |
GetLifetimeService (inherited from MarshalByRefObject) |
GetNextControl (inherited from Control) |
GetType (inherited from Object) |
Hide (inherited from Control) |
InitializeDataSource | Assigns the values of the data source (business object) properties to the corresponding properties of the IForm controls as specified in the form.suite4.net designer.
InitializeLifetimeService (inherited from MarshalByRefObject) |
Invalidate (inherited from Control) | Overloaded.
Invoke (inherited from Control) | Overloaded.
PerformLayout (inherited from Control) | Overloaded.
PointToClient (inherited from Control) |
PointToScreen (inherited from Control) |
PreProcessMessage (inherited from Control) |
RectangleToClient (inherited from Control) |
RectangleToScreen (inherited from Control) |
Refresh (inherited from Control) |
Reset | Resets the LoaderControl to the state it was in immediately after construction and discards all changes made during the lifetime of the LoaderControl instance.
ResetBackColor (inherited from Control) |
ResetBindings (inherited from Control) |
ResetCursor (inherited from Control) |
ResetFont (inherited from Control) |
ResetForeColor (inherited from Control) |
ResetImeMode (inherited from Control) |
ResetRightToLeft (inherited from Control) |
ResetText (inherited from Control) |
ResumeLayout (inherited from Control) | Overloaded.
Save | Writes the MemberForm values back to the data source (business object).
Scale (inherited from Control) | Overloaded.
Select (inherited from Control) |
SelectNextControl (inherited from Control) |
SendToBack (inherited from Control) |
SetBounds (inherited from Control) | Overloaded.
Show (inherited from Control) |
SuspendLayout (inherited from Control) |
ToString (inherited from Component) |
Update (inherited from Control) |

Public Instance Events

BackColorChanged (inherited from Control) |
BackgroundImageChanged (inherited from Control) |
BindingContextChanged (inherited from Control) |
CausesValidationChanged (inherited from Control) |
ChangeUICues (inherited from Control) |
Click (inherited from Control) |
ContextMenuChanged (inherited from Control) |
ControlAdded (inherited from Control) |
ControlRemoved (inherited from Control) |
CursorChanged (inherited from Control) |
DirtyChanged | The DirtyChanged event is raised when the user changes any of the values displayed in the MemberForm.
Disposed (inherited from Component) |
DockChanged (inherited from Control) |
DoubleClick (inherited from Control) |
DragDrop (inherited from Control) |
DragEnter (inherited from Control) |
DragLeave (inherited from Control) |
DragOver (inherited from Control) |
EnabledChanged (inherited from Control) |
Enter (inherited from Control) |
FontChanged (inherited from Control) |
ForeColorChanged (inherited from Control) |
GiveFeedback (inherited from Control) |
GotFocus (inherited from Control) |
HandleCreated (inherited from Control) |
HandleDestroyed (inherited from Control) |
HelpRequested (inherited from Control) |
ImeModeChanged (inherited from Control) |
Invalidated (inherited from Control) |
KeyDown (inherited from Control) |
KeyPress (inherited from Control) |
KeyUp (inherited from Control) |
Layout (inherited from Control) |
Leave (inherited from Control) |
LocationChanged (inherited from Control) |
LostFocus (inherited from Control) |
MouseDown (inherited from Control) |
MouseEnter (inherited from Control) |
MouseHover (inherited from Control) |
MouseLeave (inherited from Control) |
MouseMove (inherited from Control) |
MouseUp (inherited from Control) |
MouseWheel (inherited from Control) |
Move (inherited from Control) |
Paint (inherited from Control) |
ParentChanged (inherited from Control) |
QueryAccessibilityHelp (inherited from Control) |
QueryContinueDrag (inherited from Control) |
Resize (inherited from Control) |
RightToLeftChanged (inherited from Control) |
SizeChanged (inherited from Control) |
StyleChanged (inherited from Control) |
SystemColorsChanged (inherited from Control) |
TabIndexChanged (inherited from Control) |
TabStopChanged (inherited from Control) |
TextChanged (inherited from Control) |
Validated (inherited from Control) |
Validating (inherited from Control) |
VisibleChanged (inherited from Control) |

See Also

LoaderControl Class | suite4.net.FormDatabase Namespace


LoaderControl Constructor

Creates a new LoaderControl instance.

Overload List

Creates a new LoaderControl instance.

public LoaderControl();

Creates a new LoaderControl instance using the specified IForm.

public LoaderControl(IForm);

Creates a new LoaderControl instance using the specified IForm and data source.

public LoaderControl(IForm,object);

Creates a new LoaderControl instance using the specified Control and an IForm.

public LoaderControl(Control,IForm);

Creates a new LoaderControl instance using the specified Control, an IForm and a data source.

public LoaderControl(Control,IForm,object);

See Also

LoaderControl Class | suite4.net.FormDatabase Namespace


LoaderControl Constructor ()

Creates a new LoaderControl instance.

[Visual Basic]
Overloads Public Sub New()
[C#]
public LoaderControl();

See Also

LoaderControl Class | suite4.net.FormDatabase Namespace | LoaderControl Constructor Overload List


LoaderControl Constructor (IForm)

Creates a new LoaderControl instance using the specified IForm.

[Visual Basic]
Overloads Public Sub New( _
ByVal memberForm As IForm _
)
[C#]
public LoaderControl(
IForm memberForm
);

Parameters

memberForm
The IForm to be loaded into the control.

See Also

LoaderControl Class | suite4.net.FormDatabase Namespace | LoaderControl Constructor Overload List


LoaderControl Constructor (IForm, Object)

Creates a new LoaderControl instance using the specified IForm and data source.

[Visual Basic]
Overloads Public Sub New( _
ByVal memberForm As IForm, _
ByVal dataSource As Object _
)
[C#]
public LoaderControl(
IForm memberForm,
object dataSource
);

Parameters

memberForm
The IForm to be loaded into the control.
dataSource
The data source (business object) to be bound to the controls of the IForm specified in the form parameter.

See Also

LoaderControl Class | suite4.net.FormDatabase Namespace | LoaderControl Constructor Overload List


LoaderControl Constructor (Control, IForm)

Creates a new LoaderControl instance using the specified Control and an IForm.

[Visual Basic]
Overloads Public Sub New( _
ByVal rootControl As Control, _
ByVal memberForm As IForm _
)
[C#]
public LoaderControl(
Control rootControl,
IForm memberForm
);

Parameters

rootControl
A Form or UserControl instance that is to be merged with the IForm specified in the form parameter.
memberForm
An IForm instance which will be used to mask the rootForm.

Remarks

The IForm specified in the form parameter masks the rootControl. See the discussion at RootControl for more information.

See Also

LoaderControl Class | suite4.net.FormDatabase Namespace | LoaderControl Constructor Overload List


LoaderControl Constructor (Control, IForm, Object)

Creates a new LoaderControl instance using the specified Control, an IForm and a data source.

[Visual Basic]
Overloads Public Sub New( _
ByVal rootControl As Control, _
ByVal memberForm As IForm, _
ByVal dataSource As Object _
)
[C#]
public LoaderControl(
Control rootControl,
IForm memberForm,
object dataSource
);

Parameters

rootControl
A Form or UserControl instance that is to be merged with the IForm specified in the form parameter.
memberForm
An IForm instance which will be used to mask the rootForm.
dataSource
The data source (business object) to be bound to the controls of form.

Remarks

The IForm specified in the form parameter masks the rootControl. See the discussion at RootControl for more information.

See Also

LoaderControl Class | suite4.net.FormDatabase Namespace | LoaderControl Constructor Overload List


LoaderControl Properties

The properties of the LoaderControl class are listed below. For a complete list of LoaderControl class members, see the LoaderControl Members topic.

Public Instance Properties

AccessibilityObject (inherited from Control) |
AccessibleDefaultActionDescription (inherited from Control) |
AccessibleDescription (inherited from Control) |
AccessibleName (inherited from Control) |
AccessibleRole (inherited from Control) |
AllowDrop (inherited from Control) |
AllowEvents | Gets or sets a Boolean value determining whether or not the DirtyChanged event will be raised.
Anchor (inherited from Control) |
BackColor (inherited from Control) |
BackgroundImage (inherited from Control) |
BindingContext (inherited from Control) |
Bottom (inherited from Control) |
Bounds (inherited from Control) |
CanFocus (inherited from Control) |
CanSelect (inherited from Control) |
Capture (inherited from Control) |
CausesValidation (inherited from Control) |
ClientRectangle (inherited from Control) |
ClientSize (inherited from Control) |
CompanyName (inherited from Control) |
Container (inherited from Component) |
ContainsFocus (inherited from Control) |
ContextMenu (inherited from Control) |
Controls (inherited from Control) |
Created (inherited from Control) |
Cursor (inherited from Control) |
DataBindings (inherited from Control) |
DataSource | Gets the business class instance which is the data source of the MemberForm.
DisplayRectangle (inherited from Control) |
Disposing (inherited from Control) |
Dock (inherited from Control) |
Enabled (inherited from Control) |
Focused (inherited from Control) |
Font (inherited from Control) |
ForeColor (inherited from Control) |
Handle (inherited from Control) |
HasChildren (inherited from Control) |
Height (inherited from Control) |
ImeMode (inherited from Control) |
InvokeRequired (inherited from Control) |
IsAccessible (inherited from Control) |
IsDirty | Gets a Boolean value that informs the caller whether the user has made changes to the values displayed in the MemberForm.
IsDisposed (inherited from Control) |
IsHandleCreated (inherited from Control) |
Left (inherited from Control) |
Location (inherited from Control) |
MemberForm | Gets the IForm hosted by the LoaderControl.
Name (inherited from Control) |
Parent (inherited from Control) |
ProductName (inherited from Control) |
ProductVersion (inherited from Control) |
RecreatingHandle (inherited from Control) |
Region (inherited from Control) |
Right (inherited from Control) |
RightToLeft (inherited from Control) |
RootControl | Gets the Form or UserControl that has been set as the base control for modification by the LoaderControl's IForm.
Site (inherited from Control) |
Size (inherited from Control) |
TabIndex (inherited from Control) |
TabStop (inherited from Control) |
Tag (inherited from Control) |
Text (inherited from Control) |
Top (inherited from Control) |
TopLevelControl (inherited from Control) |
Visible (inherited from Control) |
Width (inherited from Control) |
WindowTarget (inherited from Control) |

See Also

LoaderControl Class | suite4.net.FormDatabase Namespace


AllowEvents Property

suite4.net.FormDatabase Documentation

LoaderControl.AllowEvents Property

Gets or sets a Boolean value determining whether or not the DirtyChanged event will be raised.

[Visual Basic]
Public Property AllowEvents As Boolean
[C#]
public bool AllowEvents {get; set;}

Property Value

The default value of this property is true. When it is set to false, the DirtyChanged event will not be raised.

See Also

LoaderControl Class | suite4.net.FormDatabase Namespace


DataSource Property

suite4.net.FormDatabase Documentation

LoaderControl.DataSource Property

Gets the business class instance which is the data source of the MemberForm.

[Visual Basic]
Public ReadOnly Property DataSource As Object
[C#]
public object DataSource {get;}

Property Value

The business class instance providing the values to be diplayed in the MemberForm.

Remarks

The value of this property can only be set in the constructor.

See Also

LoaderControl Class | suite4.net.FormDatabase Namespace


IsDirty Property

suite4.net.FormDatabase Documentation

LoaderControl.IsDirty Property

Gets a Boolean value that informs the caller whether the user has made changes to the values displayed in the MemberForm.

[Visual Basic]
Public ReadOnly Property IsDirty As Boolean
[C#]
public bool IsDirty {get;}

Property Value

true if an edit operation has been performed on the data, otherwise false.

Remarks

IsDirty is only used when UseDataBinding is false.

See Also

LoaderControl Class | suite4.net.FormDatabase Namespace


MemberForm Property

suite4.net.FormDatabase Documentation

LoaderControl.MemberForm Property

Gets the IForm hosted by the LoaderControl.

[Visual Basic]
Public ReadOnly Property MemberForm As IForm
[C#]
public IForm MemberForm {get;}

Property Value

The IForm that has been loaded into the LoaderControl.

Remarks

The value of this property can only be set in the constructor.

See Also

LoaderControl Class | suite4.net.FormDatabase Namespace


RootControl Property

suite4.net.FormDatabase Documentation

LoaderControl.RootControl Property

Gets the Form or UserControl that has been set as the base control for modification by the LoaderControl's IForm.

[Visual Basic]
Public ReadOnly Property RootControl As Control
[C#]
public System.Windows.Forms.Control RootControl {get;}

Property Value

The default value of this property is NULL (Nothing in Visual Basic). It can only be set in the class constructor.

Remarks

The LoaderControl provides the possibility to modify the properties of an existing Form or UserControl instance by using an IForm. This works as follows:

  1. Using an appropriate constructor, the Form/UserControl and the IForm instances are loaded into the LoaderControl. They are assigned to the RootControl and MemberForm properties respectively.
  2. The LoaderControl inspects RootControl and MemberForm and looks for controls with the same name and type in both.
  3. In any controls that are found, the original property values of the controls in RootControl are overwritten by those set in MemberForm.
  4. The LoaderControl renders the result of the merge between the RootControl and the MemberForm.

Used this way, the IForm set in MemberForm acts as a kind of mask over the RootControl. Possible uses of this technique include showing/hiding of controls based on user roles, or localization of form labels for different user languages.

See Also

LoaderControl Class | suite4.net.FormDatabase Namespace


LoaderControl Methods

The methods of the LoaderControl class are listed below. For a complete list of LoaderControl class members, see the LoaderControl Members topic.

Public Instance Methods

BeginInvoke (inherited from Control) | Overloaded.
BringToFront (inherited from Control) |
Contains (inherited from Control) |
CreateControl (inherited from Control) |
CreateGraphics (inherited from Control) |
CreateObjRef (inherited from MarshalByRefObject) |
Dispose (inherited from Component) |
DoDragDrop (inherited from Control) |
EndInvoke (inherited from Control) |
Equals (inherited from Object) |
FindForm (inherited from Control) |
Focus (inherited from Control) |
GetChildAtPoint (inherited from Control) |
GetContainerControl (inherited from Control) |
GetHashCode (inherited from Object) |
GetLifetimeService (inherited from MarshalByRefObject) |
GetNextControl (inherited from Control) |
GetType (inherited from Object) |
Hide (inherited from Control) |
InitializeDataSource | Assigns the values of the data source (business object) properties to the corresponding properties of the IForm controls as specified in the form.suite4.net designer.
InitializeLifetimeService (inherited from MarshalByRefObject) |
Invalidate (inherited from Control) | Overloaded.
Invoke (inherited from Control) | Overloaded.
PerformLayout (inherited from Control) | Overloaded.
PointToClient (inherited from Control) |
PointToScreen (inherited from Control) |
PreProcessMessage (inherited from Control) |
RectangleToClient (inherited from Control) |
RectangleToScreen (inherited from Control) |
Refresh (inherited from Control) |
Reset | Resets the LoaderControl to the state it was in immediately after construction and discards all changes made during the lifetime of the LoaderControl instance.
ResetBackColor (inherited from Control) |
ResetBindings (inherited from Control) |
ResetCursor (inherited from Control) |
ResetFont (inherited from Control) |
ResetForeColor (inherited from Control) |
ResetImeMode (inherited from Control) |
ResetRightToLeft (inherited from Control) |
ResetText (inherited from Control) |
ResumeLayout (inherited from Control) | Overloaded.
Save | Writes the MemberForm values back to the data source (business object).
Scale (inherited from Control) | Overloaded.
Select (inherited from Control) |
SelectNextControl (inherited from Control) |
SendToBack (inherited from Control) |
SetBounds (inherited from Control) | Overloaded.
Show (inherited from Control) |
SuspendLayout (inherited from Control) |
ToString (inherited from Component) |
Update (inherited from Control) |

See Also

LoaderControl Class | suite4.net.FormDatabase Namespace


LoaderControl.InitializeDataSource Method

Assigns the values of the data source (business object) properties to the corresponding properties of the IForm controls as specified in the form.suite4.net designer.

[Visual Basic]
Public Sub InitializeDataSource( _
ByVal dataSource As Object _
)
[C#]
public void InitializeDataSource(
object dataSource
);

Parameters

dataSource
The data source (business object) to be bound to the controls of the IForm specified in the MemberForm property.

Exceptions

Exception Type | Condition
DataSourceException | The LoaderControl failed to initialize the data source (business object).
LoaderException | The LoaderControl doesn't contain a MemberForm.

See Also

LoaderControl Class | suite4.net.FormDatabase Namespace


LoaderControl.Reset Method

Resets the LoaderControl to the state it was in immediately after construction and discards all changes made during the lifetime of the LoaderControl instance.

[Visual Basic]
Public Sub Reset()
[C#]
public void Reset();

Remarks

Reference types are set to NULL (Nothing in Visual Basic), value types are set to their default values.

See Also

LoaderControl Class | suite4.net.FormDatabase Namespace


LoaderControl.Save Method

Writes the MemberForm values back to the data source (business object).

[Visual Basic]
Public Sub Save( _
ByVal dataSource As Object _
)
[C#]
public void Save(
object dataSource
);

Parameters

dataSource
The data source object the data is to be written to.

Exceptions

Exception Type | Condition
DataSourceException | The LoaderControl failed to write the MemberForm values back to the data source (business object).

See Also

LoaderControl Class | suite4.net.FormDatabase Namespace


LoaderControl Events

The events of the LoaderControl class are listed below. For a complete list of LoaderControl class members, see the LoaderControl Members topic.

Public Instance Events

BackColorChanged (inherited from Control) |
BackgroundImageChanged (inherited from Control) |
BindingContextChanged (inherited from Control) |
CausesValidationChanged (inherited from Control) |
ChangeUICues (inherited from Control) |
Click (inherited from Control) |
ContextMenuChanged (inherited from Control) |
ControlAdded (inherited from Control) |
ControlRemoved (inherited from Control) |
CursorChanged (inherited from Control) |
DirtyChanged | The DirtyChanged event is raised when the user changes any of the values displayed in the MemberForm.
Disposed (inherited from Component) |
DockChanged (inherited from Control) |
DoubleClick (inherited from Control) |
DragDrop (inherited from Control) |
DragEnter (inherited from Control) |
DragLeave (inherited from Control) |
DragOver (inherited from Control) |
EnabledChanged (inherited from Control) |
Enter (inherited from Control) |
FontChanged (inherited from Control) |
ForeColorChanged (inherited from Control) |
GiveFeedback (inherited from Control) |
GotFocus (inherited from Control) |
HandleCreated (inherited from Control) |
HandleDestroyed (inherited from Control) |
HelpRequested (inherited from Control) |
ImeModeChanged (inherited from Control) |
Invalidated (inherited from Control) |
KeyDown (inherited from Control) |
KeyPress (inherited from Control) |
KeyUp (inherited from Control) |
Layout (inherited from Control) |
Leave (inherited from Control) |
LocationChanged (inherited from Control) |
LostFocus (inherited from Control) |
MouseDown (inherited from Control) |
MouseEnter (inherited from Control) |
MouseHover (inherited from Control) |
MouseLeave (inherited from Control) |
MouseMove (inherited from Control) |
MouseUp (inherited from Control) |
MouseWheel (inherited from Control) |
Move (inherited from Control) |
Paint (inherited from Control) |
ParentChanged (inherited from Control) |
QueryAccessibilityHelp (inherited from Control) |
QueryContinueDrag (inherited from Control) |
Resize (inherited from Control) |
RightToLeftChanged (inherited from Control) |
SizeChanged (inherited from Control) |
StyleChanged (inherited from Control) |
SystemColorsChanged (inherited from Control) |
TabIndexChanged (inherited from Control) |
TabStopChanged (inherited from Control) |
TextChanged (inherited from Control) |
Validated (inherited from Control) |
Validating (inherited from Control) |
VisibleChanged (inherited from Control) |

See Also

LoaderControl Class | suite4.net.FormDatabase Namespace


LoaderControl.DirtyChanged Event

The DirtyChanged event is raised when the user changes any of the values displayed in the MemberForm.

[Visual Basic]
Public Event DirtyChanged As EventHandler
[C#]
public event EventHandler DirtyChanged;

Remarks

The event is only raised when the IForm is not using data binding, in which case the UseDataBinding value will be false.

See Also

LoaderControl Class | suite4.net.FormDatabase Namespace


LoaderException Class

Represents non-fatal errors that occur during the process of loading an IForm into a LoaderControl or LoaderForm.

For a list of all members of this type, see LoaderException Members.

System.Object
System.Exception
System.ApplicationException
suite4.net.FormDatabase.LoaderException

[Visual Basic]
Public Class LoaderException
Inherits ApplicationException
[C#]
public class LoaderException : ApplicationException

Thread Safety

Public static (Shared in Visual Basic) members of this type are safe for multithreaded operations. Instance members are not guaranteed to be thread-safe.

Remarks

This exception is raised when a LoaderControl or LoaderForm encounters errors while loading an IForm component. Specifically:

  • when the LoaderControl or LoaderForm fails to create an instance of the specified component, or
  • when the LoaderControl or LoaderForm fails in the attempt to overwrite a property of the specified component.

Requirements

Namespace: suite4.net.FormDatabase

Assembly: suite4.net.FormDatabase (in suite4.net.FormDatabase.dll)

See Also

LoaderException Members | suite4.net.FormDatabase Namespace


LoaderException Members

LoaderException overview

Public Instance Properties

ComponentName | Gets the name of the component that failed to initialize.
HelpLink (inherited from Exception) |
InnerException (inherited from Exception) |
Message (inherited from Exception) |
PropertyName | Gets the name of the property that couldn't be initialized.
Source (inherited from Exception) |
StackTrace (inherited from Exception) |
TargetSite (inherited from Exception) |

Public Instance Methods

Equals (inherited from Object)
GetBaseException (inherited from Exception)
GetHashCode (inherited from Object)
GetObjectData (inherited from Exception)
GetType (inherited from Object)
ToString (inherited from Exception)

See Also

LoaderException Class | suite4.net.FormDatabase Namespace


LoaderException Properties

The properties of the LoaderException class are listed below. For a complete list of LoaderException class members, see the LoaderException Members topic.

Public Instance Properties

ComponentName | Gets the name of the component that failed to initialize.
HelpLink (inherited from Exception) |
InnerException (inherited from Exception) |
Message (inherited from Exception) |
PropertyName | Gets the name of the property that couldn't be initialized.
Source (inherited from Exception) |
StackTrace (inherited from Exception) |
TargetSite (inherited from Exception) |

See Also

LoaderException Class | suite4.net.FormDatabase Namespace


ComponentName Property

suite4.net.FormDatabase Documentation

LoaderException.ComponentName Property

Gets the name of the component that failed to initialize.

[Visual Basic]
Public ReadOnly Property ComponentName As String
[C#]
public string ComponentName {get;}

Property Value

The name of the component or NULL (Nothing in Visual Basic) if a general LoaderControl/LoaderForm error occurs.

Remarks

The component or control can't be initialized when a reference is missing or the LoaderControl/LoaderForm can't find a constructor.

See Also

LoaderException Class | suite4.net.FormDatabase Namespace


PropertyName Property

suite4.net.FormDatabase Documentation

LoaderException.PropertyName Property

Gets the name of the property that couldn't be initialized.

[Visual Basic]
Public ReadOnly Property PropertyName As String
[C#]
public string PropertyName {get;}

Property Value

The name of the property or NULL (Nothing in Visual Basic) if a general LoaderControl/LoaderForm error occurs.

See Also

LoaderException Class | suite4.net.FormDatabase Namespace


LoaderForm Class

The LoaderForm is used to load an IForm and display it in a Windows Application.

For a list of all members of this type, see LoaderForm Members.

System.Object
System.MarshalByRefObject
System.ComponentModel.Component
System.Windows.Forms.Control
System.Windows.Forms.ScrollableControl
System.Windows.Forms.ContainerControl
System.Windows.Forms.Form
suite4.net.FormDatabase.LoaderForm

[Visual Basic]
Public Class LoaderForm
Inherits Form
[C#]
public class LoaderForm : Form

Thread Safety

Public static (Shared in Visual Basic) members of this type are safe for multithreaded operations. Instance members are not guaranteed to be thread-safe.

Requirements

Namespace: suite4.net.FormDatabase

Assembly: suite4.net.FormDatabase (in suite4.net.FormDatabase.dll)

See Also

LoaderForm Members | suite4.net.FormDatabase Namespace


LoaderForm Members

LoaderForm overview

Public Instance Constructors

LoaderForm Overloaded. Initializes a new instance of the LoaderForm class.

Public Instance Properties

AcceptButton (inherited from Form) |
AccessibilityObject (inherited from Control) |
AccessibleDefaultActionDescription (inherited from Control) |
AccessibleDescription (inherited from Control) |
AccessibleName (inherited from Control) |
AccessibleRole (inherited from Control) |
ActiveControl (inherited from ContainerControl) |
ActiveMdiChild (inherited from Form) |
AllowDrop (inherited from Control) |
AllowEvents | Gets or sets a Boolean value determining whether or not the DirtyChanged event will be raised.
AllowTransparency (inherited from Form) |
Anchor (inherited from Control) |
AutoScale (inherited from Form) |
AutoScaleBaseSize (inherited from Form) |
AutoScroll (inherited from Form) |
AutoScrollMargin (inherited from ScrollableControl) |
AutoScrollMinSize (inherited from ScrollableControl) |
AutoScrollPosition (inherited from ScrollableControl) |
BackColor (inherited from Form) |
BackgroundImage (inherited from Control) |
BindingContext (inherited from ContainerControl) |
Bottom (inherited from Control) |
Bounds (inherited from Control) |
CancelButton (inherited from Form) |
CanFocus (inherited from Control) |
CanSelect (inherited from Control) |
Capture (inherited from Control) |
CausesValidation (inherited from Control) |
ClientRectangle (inherited from Control) |
ClientSize (inherited from Form) |
CompanyName (inherited from Control) |
Container (inherited from Component) |
ContainsFocus (inherited from Control) |
ContextMenu (inherited from Control) |
ControlBox (inherited from Form) |
Controls (inherited from Control) |
Created (inherited from Control) |
Cursor (inherited from Control) |
DataBindings (inherited from Control) |
DataSource | Gets the business class instance which is the data source of the MemberForm.
DesktopBounds (inherited from Form) |
DesktopLocation (inherited from Form) |
DialogResult (inherited from Form) |
DisplayRectangle (inherited from ScrollableControl) |
Disposing (inherited from Control) |
Dock (inherited from Control) |
DockPadding (inherited from ScrollableControl) |
Enabled (inherited from Control) |
Focused (inherited from Control) |
Font (inherited from Control) |
ForeColor (inherited from Control) |
FormBorderStyle (inherited from Form) |
Handle (inherited from Control) |
HasChildren (inherited from Control) |
Height (inherited from Control) |
HelpButton (inherited from Form) |
Icon (inherited from Form) |
ImeMode (inherited from Control) |
InvokeRequired (inherited from Control) |
IsAccessible (inherited from Control) |
IsDirty | ets a Boolean value that informs the caller whether the user has made changes to the values displayed in the MemberForm.
IsDisposed (inherited from Control) |
IsHandleCreated (inherited from Control) |
IsMdiChild (inherited from Form) |
IsMdiContainer (inherited from Form) |
IsRestrictedWindow (inherited from Form) |
KeyPreview (inherited from Form) |
Left (inherited from Control) |
Location (inherited from Control) |
MaximizeBox (inherited from Form) |
MaximumSize (inherited from Form) |
MdiChildren (inherited from Form) |
MdiParent (inherited from Form) |
MemberForm | Gets the IForm hosted by the LoaderForm.
Menu (inherited from Form) |
MergedMenu (inherited from Form) |
MinimizeBox (inherited from Form) |
MinimumSize (inherited from Form) |
Modal (inherited from Form) |
Name (inherited from Control) |
Opacity (inherited from Form) |
OwnedForms (inherited from Form) |
Owner (inherited from Form) |
Parent (inherited from Control) |
ParentForm (inherited from ContainerControl) |
ProductName (inherited from Control) |
ProductVersion (inherited from Control) |
RecreatingHandle (inherited from Control) |
Region (inherited from Control) |
Right (inherited from Control) |
RightToLeft (inherited from Control) |
RootControl | Gets the Form or UserControl that has been set as the base control for modification by the LoaderForm's IForm.
ShowInTaskbar (inherited from Form) |
Site (inherited from Control) |
Size (inherited from Form) |
SizeGripStyle (inherited from Form) |
StartPosition (inherited from Form) |
TabIndex (inherited from Form) |
TabStop (inherited from Control) |
Tag (inherited from Control) |
Text (inherited from Control) |
Top (inherited from Control) |
TopLevel (inherited from Form) |
TopLevelControl (inherited from Control) |
TopMost (inherited from Form) |
TransparencyKey (inherited from Form) |
Visible (inherited from Control) |
Width (inherited from Control) |
WindowState (inherited from Form) |
WindowTarget (inherited from Control) |

Public Instance Methods

Activate (inherited from Form) |
AddOwnedForm (inherited from Form) |
BeginInvoke (inherited from Control) | Overloaded.
BringToFront (inherited from Control) |
Close (inherited from Form) |
Contains (inherited from Control) |
CreateControl (inherited from Control) |
CreateGraphics (inherited from Control) |
CreateObjRef (inherited from MarshalByRefObject) |
Dispose (inherited from Component) |
DoDragDrop (inherited from Control) |
EndInvoke (inherited from Control) |
Equals (inherited from Object) |
FindForm (inherited from Control) |
Focus (inherited from Control) |
GetChildAtPoint (inherited from Control) |
GetContainerControl (inherited from Control) |
GetHashCode (inherited from Object) |
GetLifetimeService (inherited from MarshalByRefObject) |
GetNextControl (inherited from Control) |
GetType (inherited from Object) |
Hide (inherited from Control) |
InitializeDataSource | Assigns the values of the data source (business object) properties to the corresponding properties of the IForm controls as specified in the form.suite4.net designer.
InitializeLifetimeService (inherited from MarshalByRefObject) |
Invalidate (inherited from Control) | Overloaded.
Invoke (inherited from Control) | Overloaded.
LayoutMdi (inherited from Form) |
PerformLayout (inherited from Control) | Overloaded.
PointToClient (inherited from Control) |
PointToScreen (inherited from Control) |
PreProcessMessage (inherited from Control) |
RectangleToClient (inherited from Control) |
RectangleToScreen (inherited from Control) |
Refresh (inherited from Control) |
RemoveOwnedForm (inherited from Form) |
Reset | Resets the LoaderForm to the state it was in immediately after construction and discards all changes made during the lifetime of the LoaderForm instance.
ResetBackColor (inherited from Control) |
ResetBindings (inherited from Control) |
ResetCursor (inherited from Control) |
ResetFont (inherited from Control) |
ResetForeColor (inherited from Control) |
ResetImeMode (inherited from Control) |
ResetRightToLeft (inherited from Control) |
ResetText (inherited from Control) |
ResumeLayout (inherited from Control) | Overloaded.
Save | Writes the MemberForm values back to the data source (business object).
Scale (inherited from Control) | Overloaded.
ScrollControlIntoView (inherited from ScrollableControl) |
Select (inherited from Control) |
SelectNextControl (inherited from Control) |
SendToBack (inherited from Control) |
SetAutoScrollMargin (inherited from ScrollableControl) |
SetBounds (inherited from Control) | Overloaded.
SetDesktopBounds (inherited from Form) |
SetDesktopLocation (inherited from Form) |
Show (inherited from Control) |
ShowDialog (inherited from Form) | Overloaded.
SuspendLayout (inherited from Control) |
ToString (inherited from Form) |
Update (inherited from Control) |
Validate (inherited from ContainerControl) |

Public Instance Events

Activated (inherited from Form) |
BackColorChanged (inherited from Control) |
BackgroundImageChanged (inherited from Control) |
BindingContextChanged (inherited from Control) |
CausesValidationChanged (inherited from Control) |
ChangeUICues (inherited from Control) |
Click (inherited from Control) |
Closed (inherited from Form) |
Closing (inherited from Form) |
ContextMenuChanged (inherited from Control) |
ControlAdded (inherited from Control) |
ControlRemoved (inherited from Control) |
CursorChanged (inherited from Control) |
Deactivate (inherited from Form) |
DirtyChanged | The DirtyChanged event is raised when the user changes any of the values displayed in the MemberForm.
Disposed (inherited from Component) |
DockChanged (inherited from Control) |
DoubleClick (inherited from Control) |
DragDrop (inherited from Control) |
DragEnter (inherited from Control) |
DragLeave (inherited from Control) |
DragOver (inherited from Control) |
EnabledChanged (inherited from Control) |
Enter (inherited from Control) |
FontChanged (inherited from Control) |
ForeColorChanged (inherited from Control) |
GiveFeedback (inherited from Control) |
GotFocus (inherited from Control) |
HandleCreated (inherited from Control) |
HandleDestroyed (inherited from Control) |
HelpRequested (inherited from Control) |
ImeModeChanged (inherited from Control) |
InputLanguageChanged (inherited from Form) |
InputLanguageChanging (inherited from Form) |
Invalidated (inherited from Control) |
KeyDown (inherited from Control) |
KeyPress (inherited from Control) |
KeyUp (inherited from Control) |
Layout (inherited from Control) |
Leave (inherited from Control) |
Load (inherited from Form) |
LocationChanged (inherited from Control) |
LostFocus (inherited from Control) |
MaximizedBoundsChanged (inherited from Form) |
MaximumSizeChanged (inherited from Form) |
MdiChildActivate (inherited from Form) |
MenuComplete (inherited from Form) |
MenuStart (inherited from Form) |
MinimumSizeChanged (inherited from Form) |
MouseDown (inherited from Control) |
MouseEnter (inherited from Control) |
MouseHover (inherited from Control) |
MouseLeave (inherited from Control) |
MouseMove (inherited from Control) |
MouseUp (inherited from Control) |
MouseWheel (inherited from Control) |
Move (inherited from Control) |
Paint (inherited from Control) |
ParentChanged (inherited from Control) |
QueryAccessibilityHelp (inherited from Control) |
QueryContinueDrag (inherited from Control) |
Resize (inherited from Control) |
RightToLeftChanged (inherited from Control) |
SizeChanged (inherited from Control) |
StyleChanged (inherited from Control) |
SystemColorsChanged (inherited from Control) |
TabIndexChanged (inherited from Form) |
TabStopChanged (inherited from Control) |
TextChanged (inherited from Control) |
Validated (inherited from Control) |
Validating (inherited from Control) |
VisibleChanged (inherited from Control) |

See Also

LoaderForm Class | suite4.net.FormDatabase Namespace


LoaderForm Constructor

Creates a new LoaderForm instance.

Overload List

Creates a new LoaderForm instance.

public LoaderForm();

Creates a new LoaderForm instance using the specified IForm.

public LoaderForm(IForm);

Creates a new LoaderForm instance using the specified IForm and data source.

public LoaderForm(IForm,object);

Creates a new LoaderForm instance using the specified Control and an IForm.

public LoaderForm(Control,IForm);

Creates a new LoaderForm instance using the specified Control, an IForm and a data source.

public LoaderForm(Control,IForm,object);

See Also

LoaderForm Class | suite4.net.FormDatabase Namespace


LoaderForm Constructor ()

Creates a new LoaderForm instance.

[Visual Basic]
Overloads Public Sub New()
[C#]
public LoaderForm();

See Also

LoaderForm Class | suite4.net.FormDatabase Namespace | LoaderForm Constructor Overload List


LoaderForm Constructor (IForm)

Creates a new LoaderForm instance using the specified IForm.

[Visual Basic]
Overloads Public Sub New( _
ByVal memberForm As IForm _
)
[C#]
public LoaderForm(
IForm memberForm
);

Parameters

memberForm
The IForm to be loaded into the form.

See Also

LoaderForm Class | suite4.net.FormDatabase Namespace | LoaderForm Constructor Overload List


LoaderForm Constructor (IForm, Object)

Creates a new LoaderForm instance using the specified IForm and data source.

[Visual Basic]
Overloads Public Sub New( _
ByVal memberForm As IForm, _
ByVal dataSource As Object _
)
[C#]
public LoaderForm(
IForm memberForm,
object dataSource
);

Parameters

memberForm
The IForm to be loaded into the form.
dataSource
The data source (business object) to be bound to the controls of the IForm specified in the form parameter.

See Also

LoaderForm Class | suite4.net.FormDatabase Namespace | LoaderForm Constructor Overload List


LoaderForm Constructor (Control, IForm)

Creates a new LoaderForm instance using the specified Control and an IForm.

[Visual Basic]
Overloads Public Sub New( _
ByVal rootControl As Control, _
ByVal memberForm As IForm _
)
[C#]
public LoaderForm(
Control rootControl,
IForm memberForm
);

Parameters

rootControl
A Form or UserControl instance that is to be merged with the IForm specified in the form parameter.
memberForm
An IForm instance which will be used to mask the rootForm.

Remarks

The IForm specified in the form parameter masks the rootControl. See the discussion at RootControl for more information.

See Also

LoaderForm Class | suite4.net.FormDatabase Namespace | LoaderForm Constructor Overload List


LoaderForm Constructor (Control, IForm, Object)

Creates a new LoaderForm instance using the specified Control, an IForm and a data source.

[Visual Basic]
Overloads Public Sub New( _
ByVal rootControl As Control, _
ByVal memberForm As IForm, _
ByVal dataSource As Object _
)
[C#]
public LoaderForm(
Control rootControl,
IForm memberForm,
object dataSource
);

Parameters

rootControl
A Form or UserControl instance that is to be merged with the IForm specified in the form parameter.
memberForm
An IForm instance which will be used to mask the rootForm.
dataSource
The data source (business object) to be bound to the controls of form.

Remarks

The IForm specified in the form parameter masks the rootControl. See the discussion at RootControl for more information.

See Also

LoaderForm Class | suite4.net.FormDatabase Namespace | LoaderForm Constructor Overload List


LoaderForm Properties

The properties of the LoaderForm class are listed below. For a complete list of LoaderForm class members, see the LoaderForm Members topic.

Public Instance Properties

AcceptButton (inherited from Form) |
AccessibilityObject (inherited from Control) |
AccessibleDefaultActionDescription (inherited from Control) |
AccessibleDescription (inherited from Control) |
AccessibleName (inherited from Control) |
AccessibleRole (inherited from Control) |
ActiveControl (inherited from ContainerControl) |
ActiveMdiChild (inherited from Form) |
AllowDrop (inherited from Control) |
AllowEvents | Gets or sets a Boolean value determining whether or not the DirtyChanged event will be raised.
AllowTransparency (inherited from Form) |
Anchor (inherited from Control) |
AutoScale (inherited from Form) |
AutoScaleBaseSize (inherited from Form) |
AutoScroll (inherited from Form) |
AutoScrollMargin (inherited from ScrollableControl) |
AutoScrollMinSize (inherited from ScrollableControl) |
AutoScrollPosition (inherited from ScrollableControl) |
BackColor (inherited from Form) |
BackgroundImage (inherited from Control) |
BindingContext (inherited from ContainerControl) |
Bottom (inherited from Control) |
Bounds (inherited from Control) |
CancelButton (inherited from Form) |
CanFocus (inherited from Control) |
CanSelect (inherited from Control) |
Capture (inherited from Control) |
CausesValidation (inherited from Control) |
ClientRectangle (inherited from Control) |
ClientSize (inherited from Form) |
CompanyName (inherited from Control) |
Container (inherited from Component) |
ContainsFocus (inherited from Control) |
ContextMenu (inherited from Control) |
ControlBox (inherited from Form) |
Controls (inherited from Control) |
Created (inherited from Control) |
Cursor (inherited from Control) |
DataBindings (inherited from Control) |
DataSource | Gets the business class instance which is the data source of the MemberForm.
DesktopBounds (inherited from Form) |
DesktopLocation (inherited from Form) |
DialogResult (inherited from Form) |
DisplayRectangle (inherited from ScrollableControl) |
Disposing (inherited from Control) |
Dock (inherited from Control) |
DockPadding (inherited from ScrollableControl) |
Enabled (inherited from Control) |
Focused (inherited from Control) |
Font (inherited from Control) |
ForeColor (inherited from Control) |
FormBorderStyle (inherited from Form) |
Handle (inherited from Control) |
HasChildren (inherited from Control) |
Height (inherited from Control) |
HelpButton (inherited from Form) |
Icon (inherited from Form) |
ImeMode (inherited from Control) |
InvokeRequired (inherited from Control) |
IsAccessible (inherited from Control) |
IsDirty | ets a Boolean value that informs the caller whether the user has made changes to the values displayed in the MemberForm.
IsDisposed (inherited from Control) |
IsHandleCreated (inherited from Control) |
IsMdiChild (inherited from Form) |
IsMdiContainer (inherited from Form) |
IsRestrictedWindow (inherited from Form) |
KeyPreview (inherited from Form) |
Left (inherited from Control) |
Location (inherited from Control) |
MaximizeBox (inherited from Form) |
MaximumSize (inherited from Form) |
MdiChildren (inherited from Form) |
MdiParent (inherited from Form) |
MemberForm | Gets the IForm hosted by the LoaderForm.
Menu (inherited from Form) |
MergedMenu (inherited from Form) |
MinimizeBox (inherited from Form) |
MinimumSize (inherited from Form) |
Modal (inherited from Form) |
Name (inherited from Control) |
Opacity (inherited from Form) |
OwnedForms (inherited from Form) |
Owner (inherited from Form) |
Parent (inherited from Control) |
ParentForm (inherited from ContainerControl) |
ProductName (inherited from Control) |
ProductVersion (inherited from Control) |
RecreatingHandle (inherited from Control) |
Region (inherited from Control) |
Right (inherited from Control) |
RightToLeft (inherited from Control) |
RootControl | Gets the Form or UserControl that has been set as the base control for modification by the LoaderForm's IForm.
ShowInTaskbar (inherited from Form) |
Site (inherited from Control) |
Size (inherited from Form) |
SizeGripStyle (inherited from Form) |
StartPosition (inherited from Form) |
TabIndex (inherited from Form) |
TabStop (inherited from Control) |
Tag (inherited from Control) |
Text (inherited from Control) |
Top (inherited from Control) |
TopLevel (inherited from Form) |
TopLevelControl (inherited from Control) |
TopMost (inherited from Form) |
TransparencyKey (inherited from Form) |
Visible (inherited from Control) |
Width (inherited from Control) |
WindowState (inherited from Form) |
WindowTarget (inherited from Control) |

See Also

LoaderForm Class | suite4.net.FormDatabase Namespace


AllowEvents Property

suite4.net.FormDatabase Documentation

LoaderForm.AllowEvents Property

Gets or sets a Boolean value determining whether or not the DirtyChanged event will be raised.

[Visual Basic]
Public Property AllowEvents As Boolean
[C#]
public bool AllowEvents {get; set;}

Property Value

The default value of this property is true. When it is set to false, the DirtyChanged event will not be raised.

See Also

LoaderForm Class | suite4.net.FormDatabase Namespace


DataSource Property

suite4.net.FormDatabase Documentation

LoaderForm.DataSource Property

Gets the business class instance which is the data source of the MemberForm.

[Visual Basic]
Public ReadOnly Property DataSource As Object
[C#]
public object DataSource {get;}

Property Value

The business class instance providing the values to be diplayed in the MemberForm.

Remarks

The value of this property can only be set in the constructor.

See Also

LoaderForm Class | suite4.net.FormDatabase Namespace


IsDirty Property

suite4.net.FormDatabase Documentation

LoaderForm.IsDirty Property

ets a Boolean value that informs the caller whether the user has made changes to the values displayed in the MemberForm.

[Visual Basic]
Public ReadOnly Property IsDirty As Boolean
[C#]
public bool IsDirty {get;}

Property Value

true if an edit operation has been performed on the data, otherwise false.

Remarks

IsDirty is only used when UseDataBinding is false.

See Also

LoaderForm Class | suite4.net.FormDatabase Namespace


MemberForm Property

suite4.net.FormDatabase Documentation

LoaderForm.MemberForm Property

Gets the IForm hosted by the LoaderForm.

[Visual Basic]
Public ReadOnly Property MemberForm As IForm
[C#]
public IForm MemberForm {get;}

Property Value

The IForm that has been loaded into the LoaderForm.

Remarks

The value of this property can only be set in the constructor.

See Also

LoaderForm Class | suite4.net.FormDatabase Namespace


RootControl Property

suite4.net.FormDatabase Documentation

LoaderForm.RootControl Property

Gets the Form or UserControl that has been set as the base control for modification by the LoaderForm's IForm.

[Visual Basic]
Public Property RootControl As Control
[C#]
public System.Windows.Forms.Control RootControl {get; set;}

Property Value

The default value of this property is NULL (Nothing in Visual Basic). It can only be set in the class constructor.

Remarks

The LoaderForm provides the possibility to modify the properties of an existing Form or UserControl instance by using an IForm. This works as follows:

  1. Using an appropriate constructor, the Form/UserControl and the IForm instances are loaded into the LoaderForm. They are assigned to the RootControl and MemberForm properties respectively.
  2. The LoaderForm inspects the RootControl and the MemberForm and looks for controls with the same name and type in both.
  3. In any controls that are found, the original property values of the controls in the RootControl are overwritten by those set in the MemberForm.
  4. The LoaderForm renders the result of the merge between the RootControl and the MemberForm.

Used this way, the IForm set in MemberForm acts as a kind of mask over the RootControl. Possible uses of this technique include showing/hiding of controls based on user roles, or localization of form labels for different user languages.

See Also

LoaderForm Class | suite4.net.FormDatabase Namespace


LoaderForm Methods

The methods of the LoaderForm class are listed below. For a complete list of LoaderForm class members, see the LoaderForm Members topic.

Public Instance Methods

Activate (inherited from Form) |
AddOwnedForm (inherited from Form) |
BeginInvoke (inherited from Control) | Overloaded.
BringToFront (inherited from Control) |
Close (inherited from Form) |
Contains (inherited from Control) |
CreateControl (inherited from Control) |
CreateGraphics (inherited from Control) |
CreateObjRef (inherited from MarshalByRefObject) |
Dispose (inherited from Component) |
DoDragDrop (inherited from Control) |
EndInvoke (inherited from Control) |
Equals (inherited from Object) |
FindForm (inherited from Control) |
Focus (inherited from Control) |
GetChildAtPoint (inherited from Control) |
GetContainerControl (inherited from Control) |
GetHashCode (inherited from Object) |
GetLifetimeService (inherited from MarshalByRefObject) |
GetNextControl (inherited from Control) |
GetType (inherited from Object) |
Hide (inherited from Control) |
InitializeDataSource | Assigns the values of the data source (business object) properties to the corresponding properties of the IForm controls as specified in the form.suite4.net designer.
InitializeLifetimeService (inherited from MarshalByRefObject) |
Invalidate (inherited from Control) | Overloaded.
Invoke (inherited from Control) | Overloaded.
LayoutMdi (inherited from Form) |
PerformLayout (inherited from Control) | Overloaded.
PointToClient (inherited from Control) |
PointToScreen (inherited from Control) |
PreProcessMessage (inherited from Control) |
RectangleToClient (inherited from Control) |
RectangleToScreen (inherited from Control) |
Refresh (inherited from Control) |
RemoveOwnedForm (inherited from Form) |
Reset | Resets the LoaderForm to the state it was in immediately after construction and discards all changes made during the lifetime of the LoaderForm instance.
ResetBackColor (inherited from Control) |
ResetBindings (inherited from Control) |
ResetCursor (inherited from Control) |
ResetFont (inherited from Control) |
ResetForeColor (inherited from Control) |
ResetImeMode (inherited from Control) |
ResetRightToLeft (inherited from Control) |
ResetText (inherited from Control) |
ResumeLayout (inherited from Control) | Overloaded.
Save | Writes the MemberForm values back to the data source (business object).
Scale (inherited from Control) | Overloaded.
ScrollControlIntoView (inherited from ScrollableControl) |
Select (inherited from Control) |
SelectNextControl (inherited from Control) |
SendToBack (inherited from Control) |
SetAutoScrollMargin (inherited from ScrollableControl) |
SetBounds (inherited from Control) | Overloaded.
SetDesktopBounds (inherited from Form) |
SetDesktopLocation (inherited from Form) |
Show (inherited from Control) |
ShowDialog (inherited from Form) | Overloaded.
SuspendLayout (inherited from Control) |
ToString (inherited from Form) |
Update (inherited from Control) |
Validate (inherited from ContainerControl) |

See Also

LoaderForm Class | suite4.net.FormDatabase Namespace


LoaderForm.InitializeDataSource Method

Assigns the values of the data source (business object) properties to the corresponding properties of the IForm controls as specified in the form.suite4.net designer.

[Visual Basic]
Public Sub InitializeDataSource( _
ByVal dataSource As Object _
)
[C#]
public void InitializeDataSource(
object dataSource
);

Parameters

dataSource
The data source (business object) to be bound to the controls of the IForm specified in the MemberForm property.

Exceptions

Exception Type | Condition
DataSourceException | The LoaderForm failed to initialize the data source (business object).
LoaderException | The LoaderForm doesn't contain a MemberForm.

See Also

LoaderForm Class | suite4.net.FormDatabase Namespace


LoaderForm.Reset Method

Resets the LoaderForm to the state it was in immediately after construction and discards all changes made during the lifetime of the LoaderForm instance.

[Visual Basic]
Public Sub Reset()
[C#]
public void Reset();

Remarks

Reference types are set to NULL (Nothing in Visual Basic), value types are set to their default values.

See Also

LoaderForm Class | suite4.net.FormDatabase Namespace


LoaderForm.Save Method

Writes the MemberForm values back to the data source (business object).

[Visual Basic]
Public Sub Save( _
ByVal dataSource As Object _
)
[C#]
public void Save(
object dataSource
);

Parameters

dataSource
The data source object the data is to be written to.

Exceptions

Exception Type | Condition
DataSourceException | The LoaderForm failed to write the MemberForm values back to the data source (business object).

See Also

LoaderForm Class | suite4.net.FormDatabase Namespace


LoaderForm Events

The events of the LoaderForm class are listed below. For a complete list of LoaderForm class members, see the LoaderForm Members topic.

Public Instance Events

Activated (inherited from Form) |
BackColorChanged (inherited from Control) |
BackgroundImageChanged (inherited from Control) |
BindingContextChanged (inherited from Control) |
CausesValidationChanged (inherited from Control) |
ChangeUICues (inherited from Control) |
Click (inherited from Control) |
Closed (inherited from Form) |
Closing (inherited from Form) |
ContextMenuChanged (inherited from Control) |
ControlAdded (inherited from Control) |
ControlRemoved (inherited from Control) |
CursorChanged (inherited from Control) |
Deactivate (inherited from Form) |
DirtyChanged | The DirtyChanged event is raised when the user changes any of the values displayed in the MemberForm.
Disposed (inherited from Component) |
DockChanged (inherited from Control) |
DoubleClick (inherited from Control) |
DragDrop (inherited from Control) |
DragEnter (inherited from Control) |
DragLeave (inherited from Control) |
DragOver (inherited from Control) |
EnabledChanged (inherited from Control) |
Enter (inherited from Control) |
FontChanged (inherited from Control) |
ForeColorChanged (inherited from Control) |
GiveFeedback (inherited from Control) |
GotFocus (inherited from Control) |
HandleCreated (inherited from Control) |
HandleDestroyed (inherited from Control) |
HelpRequested (inherited from Control) |
ImeModeChanged (inherited from Control) |
InputLanguageChanged (inherited from Form) |
InputLanguageChanging (inherited from Form) |
Invalidated (inherited from Control) |
KeyDown (inherited from Control) |
KeyPress (inherited from Control) |
KeyUp (inherited from Control) |
Layout (inherited from Control) |
Leave (inherited from Control) |
Load (inherited from Form) |
LocationChanged (inherited from Control) |
LostFocus (inherited from Control) |
MaximizedBoundsChanged (inherited from Form) |
MaximumSizeChanged (inherited from Form) |
MdiChildActivate (inherited from Form) |
MenuComplete (inherited from Form) |
MenuStart (inherited from Form) |
MinimumSizeChanged (inherited from Form) |
MouseDown (inherited from Control) |
MouseEnter (inherited from Control) |
MouseHover (inherited from Control) |
MouseLeave (inherited from Control) |
MouseMove (inherited from Control) |
MouseUp (inherited from Control) |
MouseWheel (inherited from Control) |
Move (inherited from Control) |
Paint (inherited from Control) |
ParentChanged (inherited from Control) |
QueryAccessibilityHelp (inherited from Control) |
QueryContinueDrag (inherited from Control) |
Resize (inherited from Control) |
RightToLeftChanged (inherited from Control) |
SizeChanged (inherited from Control) |
StyleChanged (inherited from Control) |
SystemColorsChanged (inherited from Control) |
TabIndexChanged (inherited from Form) |
TabStopChanged (inherited from Control) |
TextChanged (inherited from Control) |
Validated (inherited from Control) |
Validating (inherited from Control) |
VisibleChanged (inherited from Control) |

See Also

LoaderForm Class | suite4.net.FormDatabase Namespace


LoaderForm.DirtyChanged Event

The DirtyChanged event is raised when the user changes any of the values displayed in the MemberForm.

[Visual Basic]
Public Event DirtyChanged As EventHandler
[C#]
public event EventHandler DirtyChanged;

Remarks

The event is only raised when the IForm is not using data binding, in which case the UseDataBinding value will be false.

See Also

LoaderForm Class | suite4.net.FormDatabase Namespace


Priority Enumeration

Specifies values representing the priority of the ITask

[Visual Basic]
Public Enum Priority
[C#]
public enum Priority

Members

Member Name | Description
High | The ITask has a high priority.
Medium | The ITask has a medium priority.
Low | The ITask has a low priority.

Requirements

Namespace: suite4.net.FormDatabase

Assembly: suite4.net.FormDatabase (in suite4.net.FormDatabase.dll)

See Also

suite4.net.FormDatabase Namespace


Project Class

Use this class to load a form.suite4.net IProject. Once you have a reference to the IProject you can access all its elements such as IForm or ITask.

For a list of all members of this type, see Project Members.

System.Object
suite4.net.FormDatabase.Project

[Visual Basic]
Public Class Project
[C#]
public class Project

Thread Safety

Public static (Shared in Visual Basic) members of this type are safe for multithreaded operations. Instance members are not guaranteed to be thread-safe.

Requirements

Namespace: suite4.net.FormDatabase

Assembly: suite4.net.FormDatabase (in suite4.net.FormDatabase.dll)

See Also

Project Members | suite4.net.FormDatabase Namespace


Project Members

Project overview

Public Static (Shared) Methods

LoadFromFile Static (Shared in Visual Basic) method that loads an IProject from a project file.

Public Instance Methods

Equals (inherited from Object)
GetHashCode (inherited from Object)
GetType (inherited from Object)
ToString (inherited from Object)

See Also

Project Class | suite4.net.FormDatabase Namespace


Project Methods

The methods of the Project class are listed below. For a complete list of Project class members, see the Project Members topic.

Public Static (Shared) Methods

LoadFromFile Static (Shared in Visual Basic) method that loads an IProject from a project file.

Public Instance Methods

Equals (inherited from Object)
GetHashCode (inherited from Object)
GetType (inherited from Object)
ToString (inherited from Object)

See Also

Project Class | suite4.net.FormDatabase Namespace


Project.LoadFromFile Method

Static (Shared in Visual Basic) method that loads an IProject from a project file.

[Visual Basic]
Public Shared Function LoadFromFile( _
ByVal fileName As String _
) As IProject
[C#]
public static IProject LoadFromFile(
string fileName
);

Parameters

fileName
The name of the project file.

Return Value

A reference to an IProject as stored in fileName.

Example

The following example demonstrates how to load an IProject and get a reference to an IForm.

C# sample

using System;
using System.IO;
using suite4.net.FormDatabase;
namespace suite4.net.Sample
{
    public class Project
    {
        private IProject _project;
        public Project()
        {
        }
        public suite4.net.FormDatabase.IForm GetIForm(string formName)
        {
            FileInfo    fileInfo;
            if(this._project == null)
            {
                this._project = suite4.net.FormDatabase.Project.LoadFromFile("sample.fspj");
            }
            else
            {
                fileInfo = new FileInfo("sample.fspj");
                if(fileInfo.LastWriteTime > this._project.LastModification)
                {
                    // Reload the project if the project has been changed.
                    // This can be done during runtime.
                    this._project = suite4.net.FormDatabase.Project.LoadFromFile("sample.fspj");
                }
            }
            if(this._project != null)
            {
                return this._project.GetForm(formName);
            }
            return null;
        }
    }
}

VB.Net sample
Imports System
Imports System.IO
Imports suite4.net.FormDatabase
Namespace suite4.net.Sample
    Public Class Project
        Private _project As IProject
        Public  Sub New()
        End Sub
        Public Function GetIForm(ByVal formName As String) As suite4.net.FormDataMyBase.IForm
            Dim fileInfo As FileInfo
            If Me._project Is Nothing Then
                Me._project = suite4.net.FormDataMyBase.Project.LoadFromFile("sample.fspj")
            Else
                fileInfo = New FileInfo("sample.fspj")
                If fileInfo.LastWriteTime > Me._project.LastModification Then
                    ' Reload the project if the project has been changed.
                    ' This can be done during runtime.
                    Me._project = suite4.net.FormDataMyBase.Project.LoadFromFile("sample.fspj")
                End If
            End If
            If Not Me._project Is Nothing Then
                Return Me._project.GetForm(formName)
            End If
            Return Nothing
        End Function
    End Class
End Namespace

See Also

Project Class | suite4.net.FormDatabase Namespace


TaskSortProperty Enumeration

Enumeration specifying the ITask property by which an ITaskCollection is to be sorted.

[Visual Basic]
Public Enum TaskSortProperty
[C#]
public enum TaskSortProperty

Remarks

The enumeration defaults to Title.

Members

Member Name | Description
Title | The ITaskCollection will be sorted by the Title property.
AssignedTo | The ITaskCollection will be sorted by the AssignedTo property.
Priority | The ITaskCollection will be sorted by the Priority property.
TaskType | The ITaskCollection will be sorted by the TaskType property.

Requirements

Namespace: suite4.net.FormDatabase

Assembly: suite4.net.FormDatabase (in suite4.net.FormDatabase.dll)

See Also

suite4.net.FormDatabase Namespace


TaskType Enumeration

Specifies values representing the type of task used in the ITask and ITaskCollection interfaces.

[Visual Basic]
Public Enum TaskType
[C#]
public enum TaskType

Members

Member Name | Description
Task | The ITask is a task without a description.
TaskDescription | The ITask is both a task and a description.
Description | The ITask is a description.

Requirements

Namespace: suite4.net.FormDatabase

Assembly: suite4.net.FormDatabase (in suite4.net.FormDatabase.dll)

See Also

suite4.net.FormDatabase Namespace


ValidationEventArgs Class

ValidationEventArgs provides data for the ValidationEventHandler.

For a list of all members of this type, see ValidationEventArgs Members.

System.Object
System.EventArgs
System.ComponentModel.CancelEventArgs
suite4.net.FormDatabase.ValidationEventArgs

[Visual Basic]
Public Class ValidationEventArgs
Inherits CancelEventArgs
Implements IDisposable
[C#]
public class ValidationEventArgs : CancelEventArgs, IDisposable

Thread Safety

Public static (Shared in Visual Basic) members of this type are safe for multithreaded operations. Instance members are not guaranteed to be thread-safe.

Requirements

Namespace: suite4.net.FormDatabase

Assembly: suite4.net.FormDatabase (in suite4.net.FormDatabase.dll)

See Also

ValidationEventArgs Members | suite4.net.FormDatabase Namespace


ValidationEventArgs Members

ValidationEventArgs overview

Public Instance Properties

Cancel (inherited from CancelEventArgs) |
CurrentValue | Gets or sets a value the current value of the Control.
OrginalValue | Gets the orginal value from the data source (business object) that was assignd by the LoaderControl or the LoaderForm.

Public Instance Methods

Equals (inherited from Object)
GetHashCode (inherited from Object)
GetType (inherited from Object)
ToString (inherited from Object)

See Also

ValidationEventArgs Class | suite4.net.FormDatabase Namespace


ValidationEventArgs Properties

The properties of the ValidationEventArgs class are listed below. For a complete list of ValidationEventArgs class members, see the ValidationEventArgs Members topic.

Public Instance Properties

Cancel (inherited from CancelEventArgs) |
CurrentValue | Gets or sets a value the current value of the Control.
OrginalValue | Gets the orginal value from the data source (business object) that was assignd by the LoaderControl or the LoaderForm.

See Also

ValidationEventArgs Class | suite4.net.FormDatabase Namespace


CurrentValue Property

suite4.net.FormDatabase Documentation

ValidationEventArgs.CurrentValue Property

Gets or sets a value the current value of the Control.

[Visual Basic]
Public Property CurrentValue As Object
[C#]
public object CurrentValue {get; set;}

Property Value

The current value of the Control that can not validated to the data source (business object).

See Also

ValidationEventArgs Class | suite4.net.FormDatabase Namespace


OrginalValue Property

suite4.net.FormDatabase Documentation

ValidationEventArgs.OrginalValue Property

Gets the orginal value from the data source (business object) that was assignd by the LoaderControl or the LoaderForm.

[Visual Basic]
Public ReadOnly Property OrginalValue As Object
[C#]
public object OrginalValue {get;}

Property Value

Null or (Nothing in Visual Basic) when no value provided by the data source (business object).

See Also

ValidationEventArgs Class | suite4.net.FormDatabase Namespace


ValidationEventHandler Delegate

Represents the method that will handle the event that when the Validation of a data source (business object) property faild.

[Visual Basic]
Public Delegate Sub ValidationEventHandler( _
ByVal sender As Object, _
ByVal validationEventArgs As ValidationEventArgs _
)
[C#]
public delegate void ValidationEventHandler(
object sender,
ValidationEventArgs validationEventArgs
);

Parameters

sender
The source Control of the event.
validationEventArgs
A ValidationEventArgs that contains the event data.

Requirements

Namespace: suite4.net.FormDatabase

Assembly: suite4.net.FormDatabase (in suite4.net.FormDatabase.dll)

See Also

suite4.net.FormDatabase Namespace


WebLoaderAlert Class

Represents an alert box that gets displayed in the WebLoader component.

For a list of all members of this type, see WebLoaderAlert Members.

System.Object
suite4.net.FormDatabase.WebLoaderAlert

[Visual Basic]
NotInheritable Public Class WebLoaderAlert
[C#]
public sealed class WebLoaderAlert

Thread Safety

Public static (Shared in Visual Basic) members of this type are safe for multithreaded operations. Instance members are not guaranteed to be thread-safe.

Requirements

Namespace: suite4.net.FormDatabase

Assembly: suite4.net.FormDatabase (in suite4.net.FormDatabase.dll)

See Also

WebLoaderAlert Members | suite4.net.FormDatabase Namespace


WebLoaderAlert Members

WebLoaderAlert overview

Public Instance Constructors

WebLoaderAlert Overloaded. Initializes a new instance of the WebLoaderAlert class.

Public Instance Properties

Message | Gets or sets the message of the alert box.
Title | Gets or sets the title of the alert box.

Public Instance Methods

Equals (inherited from Object) |
GetHashCode (inherited from Object) |
GetType (inherited from Object) |
SerializeToSwfXml | Serializes the WebLoaderAlert for processing by the WebLoader component.
ToString (inherited from Object) |

See Also

WebLoaderAlert Class | suite4.net.FormDatabase Namespace


WebLoaderAlert Constructor

Creates a new WebLoaderAlert instance.

Overload List

Creates a new WebLoaderAlert instance.

public WebLoaderAlert();

Creates a new WebLoaderAlert instance using the provided Title and Message.

public WebLoaderAlert(string,string);

See Also

WebLoaderAlert Class | suite4.net.FormDatabase Namespace


WebLoaderAlert Constructor ()

Creates a new WebLoaderAlert instance.

[Visual Basic]
Overloads Public Sub New()
[C#]
public WebLoaderAlert();

See Also

WebLoaderAlert Class | suite4.net.FormDatabase Namespace | WebLoaderAlert Constructor Overload List


WebLoaderAlert Constructor (String, String)

Creates a new WebLoaderAlert instance using the provided Title and Message.

[Visual Basic]
Overloads Public Sub New( _
ByVal title As String, _
ByVal message As String _
)
[C#]
public WebLoaderAlert(
string title,
string message
);

Parameters

title
The title of the alert box.
message
The message of the alert box.

See Also

WebLoaderAlert Class | suite4.net.FormDatabase Namespace | WebLoaderAlert Constructor Overload List


WebLoaderAlert Properties

The properties of the WebLoaderAlert class are listed below. For a complete list of WebLoaderAlert class members, see the WebLoaderAlert Members topic.

Public Instance Properties

Message | Gets or sets the message of the alert box.
Title | Gets or sets the title of the alert box.

See Also

WebLoaderAlert Class | suite4.net.FormDatabase Namespace


Message Property

suite4.net.FormDatabase Documentation

WebLoaderAlert.Message Property

Gets or sets the message of the alert box.

[Visual Basic]
Public Property Message As String
[C#]
public string Message {get; set;}

Property Value

The message assigned to the WebLoaderAlert.

See Also

WebLoaderAlert Class | suite4.net.FormDatabase Namespace


Title Property

suite4.net.FormDatabase Documentation

WebLoaderAlert.Title Property

Gets or sets the title of the alert box.

[Visual Basic]
Public Property Title As String
[C#]
public string Title {get; set;}

Property Value

The title assigned to the WebLoaderAlert.

See Also

WebLoaderAlert Class | suite4.net.FormDatabase Namespace


WebLoaderAlert Methods

The methods of the WebLoaderAlert class are listed below. For a complete list of WebLoaderAlert class members, see the WebLoaderAlert Members topic.

Public Instance Methods

Equals (inherited from Object) | Determines whether the specified Object is equal to the current Object.
GetHashCode (inherited from Object) | Serves as a hash function for a particular type, suitable for use in hashing algorithms and data structures like a hash table.
GetType (inherited from Object) | Gets the Type of the current instance.
SerializeToSwfXml | Overloaded. Serializes the WebLoaderAlert for processing by the WebLoader component.
ToString (inherited from Object) | Returns a String that represents the current Object.

See Also

WebLoaderAlert Class | suite4.net.FormDatabase Namespace


SerializeToSwfXml Method

suite4.net.FormDatabase Documentation

WebLoaderAlert.SerializeToSwfXml Method

Serializes the WebLoaderAlert for processing by the WebLoader component.

Overload List

Serializes the WebLoaderAlert for processing by the WebLoader component.

public string SerializeToSwfXml();

Serializes the WebLoaderAlert for processing by the WebLoader component. After the WebLoader has shown the a Alert, a specified JavaScript or VBScript function is called.

public string SerializeToSwfXml(string,string);

See Also

WebLoaderAlert Class | suite4.net.FormDatabase Namespace


WebLoaderAlert.SerializeToSwfXml Method ()

Serializes the WebLoaderAlert for processing by the WebLoader component.

[Visual Basic]
Overloads Public Function SerializeToSwfXml() As String
[C#]
public string SerializeToSwfXml();

Return Value

An XML string representing the WebLoaderAlert.

Remarks

The WebLoader component will parse the XML string and create an alert box based on the string's contents.

Example

C# sample

private string AlertException(System.Exception ex)
{
    suite4.net.FormDatabase.WebLoaderAlert    webLoaderAlert;

    webLoaderAlert = new suite4.net.FormDatabase.WebLoaderAlert();
    webLoaderAlert.Title = ex.Source;
    webLoaderAlert.Message = ex.Message;
    return webLoaderAlert.SerializeToSwfXml();
} // end private string AlertException(System.Exception ex)

VB.Net sample
Private Function AlertException(ByVal ex As System.Exception) As String
    Dim webLoaderAlert As suite4.net.FormDataMyBase.WebLoaderAlert

    webLoaderAlert = New suite4.net.FormDataMyBase.WebLoaderAlert()
    webLoaderAlert.Title = ex.Source
    webLoaderAlert.Message = ex.Message
    Return webLoaderAlert.SerializeToSwfXml()
End Function

See Also

WebLoaderAlert Class | suite4.net.FormDatabase Namespace | WebLoaderAlert.SerializeToSwfXml Overload List


WebLoaderAlert.SerializeToSwfXml Method (String, String)

Serializes the WebLoaderAlert for processing by the WebLoader component. After the WebLoader has shown the a Alert, a specified JavaScript or VBScript function is called.

[Visual Basic]
Overloads Public Function SerializeToSwfXml( _
ByVal scriptFunction As String, _
ByVal scriptFunctionArgument As String _
) As String
[C#]
public string SerializeToSwfXml(
string scriptFunction,
string scriptFunctionArgument
);

Parameters

scriptFunction
The script function to be called after the rendering of the form has been completed.
scriptFunctionArgument
A parameter for use with the scriptFunction.

Return Value

An XML string representing the WebLoaderAlert.

Remarks

The WebLoader component will parse the XML string and create an alert box based on the string's contents.

Example

C# sample

private string AlertException(System.Exception ex)
{
    suite4.net.FormDatabase.WebLoaderAlert    webLoaderAlert;

    webLoaderAlert = new suite4.net.FormDatabase.WebLoaderAlert();
    webLoaderAlert.Title = ex.Source;
    webLoaderAlert.Message = ex.Message;
    return webLoaderAlert.SerializeToSwfXml();
} // end private string AlertException(System.Exception ex)

VB.Net sample
Private Function AlertException(ByVal ex As System.Exception) As String
    Dim webLoaderAlert As suite4.net.FormDataMyBase.WebLoaderAlert

    webLoaderAlert = New suite4.net.FormDataMyBase.WebLoaderAlert()
    webLoaderAlert.Title = ex.Source
    webLoaderAlert.Message = ex.Message
    Return webLoaderAlert.SerializeToSwfXml()
End Function

JavaScript sample
<script language="JavaScript">
<!--
var isInternetExplorer = navigator.appName.indexOf('Microsoft') != -1;
function WebLoader_DoFSCommand(command, args)
{
  if(command == 'RedirectToLogin')
  {
    window.location.assign(args);
  }
  else
  {
    var fsObj = isInternetExplorer ? document.all.WebLoader : document.WebLoader;
    var TableFrame = document.getElementById('DataIFrame');
    TableFrame.src = '/support/PostingTable.aspx?Refresh=' + args;
  }
}
if(navigator.appName && navigator.appName.indexOf('Microsoft') != -1
   && navigator.userAgent.indexOf('Windows') != -1
   && navigator.userAgent.indexOf('Windows 3.1') == -1)
{
  document.write('<script language=\"VBScript\"\>\n');
  document.write('On Error Resume Next\n');
  document.write('Sub WebLoader_FSCommand(ByVal command, ByVal args)\n');
  document.write('    Call WebLoader_DoFSCommand(command, args)\n');
  document.write('End Sub\n');
  document.write('</script\>\n');
}
//-->
</script<

See Also

WebLoaderAlert Class | suite4.net.FormDatabase Namespace | WebLoaderAlert.SerializeToSwfXml Overload List


WebLoaderEventType Enumeration

Specifies the different types of external methods that can be called from the IWebLoaderEvent interface.

[Visual Basic]
Public Enum WebLoaderEventType
[C#]
public enum WebLoaderEventType

Members

Member Name | Description
JavaScript | The WebLoader calls a client-side JavaScript function.
WebService | The WebLoader calls a web service with the parameters specified in the IWebLoaderEvent interface.

Requirements

Namespace: suite4.net.FormDatabase

Assembly: suite4.net.FormDatabase (in suite4.net.FormDatabase.dll)

See Also

suite4.net.FormDatabase Namespace


WebLoaderParameterType Enumeration

Specifies the different types of parameters available for use with the IWebLoaderEvent. These parameters get passed to the method specified in the Operation property.

[Visual Basic]
Public Enum WebLoaderParameterType
[C#]
public enum WebLoaderParameterType

Members

Member Name | Description
Component | The name of the control that raised the event.
ComponentValue | The value of the control that raised the event.
FormDatabase | The IWebLoaderEvent passes the value of the provided FormDatabase.
FormName | The name of the IForm.
DataSource | IWebLoaderEvent passes the values of the business class instance associated with the IForm.
DataUniqueID | The value of the DataUniqueID.
UserDefined | A user-defined value.

Requirements

Namespace: suite4.net.FormDatabase

Assembly: suite4.net.FormDatabase (in suite4.net.FormDatabase.dll)

See Also

suite4.net.FormDatabase Namespace


Glossary

Group
Used in the Form Manager, a Group denotes a logical grouping of forms and/or controls. The grouping is reflected in the generated code through namespaces. If you export the form.suite4.net project as a Visual Studio .NET project, a separate folder will be created for each group.
Inherited Form
A form based on a Root Form (see below). It inherits the properties of the Root Form and can be manipulated independently of the Root Form.
Note: This feature is available in the Professional and higher versions of form.suite4.net only.
Root Form
A base form which is the container of controls and from which other forms (Inherited Forms, see above) can be derived.


WebLoaderAlert.SerializeToSwfXml Method

Serializes the WebLoaderAlert for processing by the WebLoader component.

[Visual Basic]
Public Function SerializeToSwfXml() As String
[C#]
public string SerializeToSwfXml();

Return Value

An XML string representing the WebLoaderAlert.

Remarks

The WebLoader component will parse the XML string and create an alert box based on the string's contents.

See Also

WebLoaderAlert Class | suite4.net.FormDatabase Namespace


suite4.net.FormDatabaseHierarchy

suite4.net.FormDatabase Documentation

suite4.net.FormDatabase Hierarchy

System.Object
suite4.net.FormDatabase.IForm
suite4.net.FormDatabase.IFormCollection ---- System.Collections.ICollection, System.Collections.IEnumerable
suite4.net.FormDatabase.IGroup
suite4.net.FormDatabase.IGroupCollection ---- System.Collections.ICollection, System.Collections.IEnumerable
suite4.net.FormDatabase.IProject
suite4.net.FormDatabase.ITask
suite4.net.FormDatabase.ITaskCollection ---- System.Collections.ICollection, System.Collections.IEnumerable
suite4.net.FormDatabase.IWebLoaderEvent
suite4.net.FormDatabase.IWebLoaderEventParameter
suite4.net.FormDatabase.Project
suite4.net.FormDatabase.WebLoaderAlert
System.Delegate ---- System.ICloneable, System.Runtime.Serialization.ISerializable
System.MulticastDelegate
suite4.net.FormDatabase.ValidationEventHandler
System.EventArgs
System.ComponentModel.CancelEventArgs
suite4.net.FormDatabase.ValidationEventArgs ---- System.IDisposable
System.Exception ---- System.Runtime.Serialization.ISerializable
System.ApplicationException
suite4.net.FormDatabase.DataSourceException
suite4.net.FormDatabase.LoaderException
System.MarshalByRefObject
System.ComponentModel.Component ---- System.ComponentModel.IComponent, System.IDisposable
System.Windows.Forms.Control ---- System.ComponentModel.ISynchronizeInvoke, System.Windows.Forms.IWin32Window
suite4.net.FormDatabase.LoaderControl
System.Windows.Forms.ScrollableControl
System.Windows.Forms.ContainerControl ---- System.Windows.Forms.IContainerControl
System.Windows.Forms.Form
suite4.net.FormDatabase.LoaderForm
System.ValueType
System.Enum ---- System.IComparable, System.IConvertible, System.IFormattable
suite4.net.FormDatabase.AssignedTo
suite4.net.FormDatabase.FormSortProperty
suite4.net.FormDatabase.FormType
suite4.net.FormDatabase.GroupSortProperty
suite4.net.FormDatabase.Priority
suite4.net.FormDatabase.TaskSortProperty
suite4.net.FormDatabase.TaskType
suite4.net.FormDatabase.WebLoaderEventType
suite4.net.FormDatabase.WebLoaderParameterType

See Also

suite4.net.FormDatabase Namespace


Form Designer: Format Menu

Format Menu

The following commands are available in the Form Designer's Format menu:

  • Snap To Grid: Used to enable or disable snapping form elements to the Form Designer's grid. If set to active, the controls will adapt their position to the grid's horizontal and vertical lines during insertion, moving and resizing.
    If you want to place a control outside the grid lines even while snap to grid is activated, you can do this by using Ctrl and the arrow keys (←, →, ↑, ↓).
    If you want to change the control size independently of the grid, use Shift + Ctrl and the arrow keys (←, →, ↑, ↓).
    If you want to change the control size in grid steps, use Shift and the arrow keys (←, →, ↑, ↓).
  • Align: align selected controls in relation to each other.
    Left | Align controls to the leftmost selected control.
    Center | Align the center points of the controls along a horizontal axis.
    Right | Align controls to the rightmost selected control.
    Top | Align controls to their topmost selected control.
    Middle | Align the center points of the controls along a vertical axis.
    Bottom | Align controls to their bottommost selected control.
    Grid | Align controls to the Form Designer's grid.
  • Match Size : resize selected controls to the same size as the main selected control:
    Width | Match the selected controls' widths.
    Match to Grid | Match the controls' size to the grid.
    Height | Match the selected controls' heights.
    Both | Match both height and width of the selected controls.
  • Horizontal Spacing: adjust horizontal spacing between selected controls:
    Space | Space selected controls evenly horizontally.
    Increase | Increase horizontal spacing between selected controls.
    Decrease | Decrease horizontal spacing between selected controls.
    Remove | Remove horizontal spacing between selected controls.
  • Vertical Spacing: adjust vertical spacing between selected controls:
    Space | Space selected controls evenly vertically.
    Increase | Increase vertical spacing between selected controls.
    Decrease | Decrease vertical spacing between selected controls.
    Remove | Remove vertical spacing between selected controls.

The menu commands under Align, Match Size, Horizontal Spacing and Vertical Spacing are available only if at least two controls are selected. The last control selected becomes the reference for setting the other controls' properties.

  • Center in Form
    Horizontally | Center selected control horizontally on the form.
    Vertically | Center selected control vertically on the form.
  • Arrange
    Bring to Front | Place the control at the top of the stacking order.
    Send to Back | Place the control below all other selected controls.
  • Copy Appearance: Copy the appearance settings of a control to the clipboard for subsequent application to another control.
  • Apply Appearance: Apply appearance settings stored in the clipboard to the selected control.
  • Lock: Prevent changes to a control.