Delphi Form Object Snippets


As the most important building block of any Delphi application, the TForm object is most of the times used as is. Delphi's TForm object provides enough properties and events to help you do (and control) whatever needed with it. Sometimes you'll find out that a few events or properties are missing... Try creating a simple form application. Now...

15 June, 2013   

Example shows here How to Clone a Delphi Form. Note: when you create a new clone from an existing form, the clone's OnCreate will not execute.

08 May, 2012   

Here shown an example for how to clone a Delphi Form

The ActiveControl property of a Delphi Form object specifies what control has the input focus. You can use this property to set what control is (initially) focused when the form is created and displayed to the user. If you want to move the mouse cursor to the control with the focus, you can use the next code in the form's OnCreate event handler...

08 May, 2012   

To tell if the mouse is over Delphi Form

11 November, 2013   

These are two JavaScript functions that should of course be properly called on "onkeyup" event in the appropriate fields.

Shows how to focus a control in a Windows Form. If you are working with Web forms it is very simple, you just use "WebControl.Focus()" but this does not work for Windows Forms.

01 March, 2011   

Mouse Move Paint . A simple program for drawing using mouse move event in vb.net 2005 version... This code is compatible with : VB 2005, VB 2008, VB 2010 Steps For Creation:- --------------------------- 1. Change the background color of the form1 as white. 2. Then, double click the form and change the event as mouse move click event. 3. Now,...

Here's a simple trick to execute a Delphi object's method by name:

his snippet was created under the inspiration of using the django-multilingual package. Also an additional code is used to solve the problem of saving the many-to-many relations in embedded forms (http://trac.symfony-project.org/ticket/5867#comment:21). The idea is that in all embedded I18n forms appears checkbox "delete" for each...

06 February, 2012   

ASP Forms and User Input from HTML form

05 September, 2013   

Making a transparent form. Add a Button (Button1) to a Delphi form (Form1)...

By default, Delphi gets its date/time, currency and numeric format from Control Panel's International settings. We can set the constants defined in Delphi, like DecimalSeparator, ShortDateFormat and others like in the code below. To a complete list of these variables, look at Currency and date/time formatting variables in Delphi Help.

Maxscript UI & Graphical RPManager - Control multiple object properties with single object for

11 February, 2013   

Quicktime still requires the double-object method to get it done across all browsers. Not super pretty, but it does get the job done.

09 April, 2011   

On form, insert a Page Break after the first group of fields. This creates two "pages" in the form, which can be toggled using a command button on each.

A short and simple code snippet using voice output with Delphi

If you want to react on user maximizing or minimizing a Delphi form, use the code.

23 April, 2011   

Below is a basic feedback form script 'feedback.asp'. You can add your own validation. Once the visitor has filled in all the form textfields an email will be sent with the feedback details including the date and time and the visitor's IP address to the email specified in the script.

23 March, 2011   

When using forms within your web site, there may be times when you will want to include an example of what you'd like your visitors to fill in your form field. Although you could place some default text within your form field, your users would need to delete the default text in order to type in their own information.