Delphi Language
Here are a few examples of declaring and initializing constant arrays in Delphi:
type TShopItem = record Name : string; Price : currency; end;
const Days : array[0..6] of string = ( 'Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat' ) ;
CursorMode : array[boolean] of TCursor = ( crHourGlass, crSQLWait ) ;
Define {$ifdef CONSOLIDATE} cbConsolidated.EnableAlign := true {$ENDIF}
Items : array[1..3] of TShopItem = ( (Name : 'Clock'; Price : 20.99), (Name : 'Pencil'; Price : 15.75), (Name : 'Board'; Price : 42.96) ) ;
Create Date : 01 ธันวาคม 2551 |
Last Update : 2 ธันวาคม 2551 10:43:55 น. |
|
0 comments
|
Counter : 642 Pageviews. |
|
|
|
|
|