Create a new VCL Forms Application project,
Code Two
Class :
One is a tform class; the other is a tform1 class; tform1 inherits from tform.
Tform is the parent class of tform1, and tform1 is the Child class of tform.
unit unit1;
VaR B: byte; W: word; C: Cardinal; begin {byte is a 1-byte (8-bit) unsigned integer with a maximum value of 111111112} ASM mov B, 111111b; end; showmessage (inttostr (B); {255} {word is a 2-byte (16-bit) unsigned integer with a maximum value of 11111
In this example:
After the message wm_nchittest is returned, the result parameter indicates the part of the window where the mouse is located.
Form Design Steps: after creating a project, add a menu; set the autoscroll attribute of
Download the source code in this example and run:
Production process:
1. After creating a new project, add form2, form3, form4, and form5;
2. Add a tprogressbar and tlabel respectively on form5 (use the default name );
3. Open the project
Problem Source: http://www.cnblogs.com/del/archive/2008/05/14/1089344.html#1196271
In this example:
Code File:
Unit unit1; interfaceuses windows, messages, sysutils, variants, classes, graphics, controls, forms, dialogs,
// Single-character char and ansichar (in the current version (2007), they are the same thing, only 1 byte) var C: Char; {the value range of the char type is: #0 .. #255, in hexadecimal format: #$0 .. # $ ff} begin {value assignment in decimal
I have known a value assignment instruction (mov) of an Assembly and an addition instruction (ADD), so I can give an example.
For example: Add ax, BX; this is equivalent to ax: = AX + bx in Delphi;
In addition, a list is provided in
Function length (S: String {string; or an array}): integer;
Example:
// String (same as ansistring in Delphi 2007) var S: string; I: integer; begin S: = 'delphi '; I: = length (s ); showmessage (inttostr (I); {6} end;
//
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service