Üye Girişi

Kullanıcı Adı:  Parola:   Kayıp Parola

Başlığı Görüntüle

 Başlığı Yazdır
Delphi 2007 ipuçları
MuhBim
#1 Mesajı Yazdır
Mesaj Tarihi 07-04-2010 22:22
Süper Yönetici

Mesaj Sayısı: 41
Katılım Tarihi: 19.04.07

Çok satır açıklama satırı yapmak/silmek için, satır/satırları seçin ve
CTRL+/
basın.
----------2-----------
{} yerine (* *) olduğu gibi; [ ] yerine de (. .) yapabilirsiniz...
----------3-----------
uses
Windows, Messages, SysUtils,
klas in 'C:\kutuphanem\klas.pas', //buraya dikkat!
Classes;
----------4-----------
compile = CTRL+F9
build = Shift+F9
----------5-----------
with obj1 do
with obj2 do
with objn do
statement
EŞİTTİR:
with obj1, obj2, ..., objn do
statement
----------6-----------
dinamik çok boyutlu dizi kullanımı
var Ints: array of array of Integer;
SetLength(Ints,10); //ilk kolon 10 elemanlı
SetLength(Ints[2], 5);//5 sütun da 2. boyut için
var (.NET için)
a: array [,,] of integer; // 3 boyutlu dizi
b: array [,] of integer; // 2 boyutlu dizi
begin
a := New(array[3,5,7] of integer); // boyut belirlemek
b := New(array[,] of integer, ((1,2,3), (4,5,6))); // ilk değer ataması
----------7-----------
out var gibidir fakat sadece output olacağından ilk değer yollansa bile gözardı edilir.
procedure GetInfo(out Info: SomeRecordType);
----------8-----------
Dizi parametre ve boyutlu string parametre olarak kullanamasak da çözümü var.
procedure Check(S: string[20]); // syntax error, parametrede boyut belirtilemez!
Çözüm
type TString20 = string[20];
procedure Check(S: TString20);
----------9-----------
parametrede ilk değer atama
function MyFunction(X: Real = 3.5; Y: Real = 3.5): Real;
olabilir ama,
function MyFunction(X, Y: Real = 3.5): Real; // syntax error
----------10----------
var
Ch: Char;
asm
MOV CH, 1 //CH char değil cx'in üst byte'ı
end;
Çözüm
MOV &Ch, 1 //üzerine bindirme operatörü override operator &
----------11----------
Standard rutinler
Procedure or function Description
Addr= Returns a pointer to a specified object.
AllocMem= Allocates a memory block and initializes each byte to zero.
ArcTan= Calculates the arctangent of the given number.
Assert= Raises an exception if the passed expression does not evaluate to true.
Assigned= Tests for a nil (unassigned) pointer or procedural variable.
Beep= Generates a standard beep.
Break= Causes control to exit a for, while, or repeat statement.
ByteToCharIndex= Returns the position of the character containing a specified byte in a string.
Chr= Returns the character for a specified integer value.
Close= Closes a file.
CompareMem= Performs a binary comparison of two memory images.
CompareStr= Compares strings case sensitively.
CompareText= Compares strings by ordinal value and is not case sensitive.
Continue= Returns control to the next iteration of for, while, or repeat statements.
Copy= Returns a substring of a string or a segment of a dynamic array.
Cos= Calculates the cosine of an angle.
CurrToStr= Converts a currency variable to a string.
Dat=e Returns the current date.
DateTimeToStr= Converts a variable of type TDateTime to a string.
DateToStr= Converts a variable of type TDateTime to a string.
Dec= Decrements an ordinal variable or a typed pointer variable.
Dispose= Releases dynamically allocated variable memory.
ExceptAddr= Returns the address at which the current exception was raised.
Exit= Exits from the current procedure.
Exp= Calculates the exponential of X.
FillChar= Fills contiguous bytes with a specified value.
Finalize= Uninitializes a dynamically allocated variable.
FloatToStr= Converts a floating point value to a string.
FloatToStrF= Converts a floating point value to a string, using specified format.
FmtLoadStr= Returns formatted output using a resourced format string.
FmtStr= Assembles a formatted string from a series of arrays.
Format= Assembles a string from a format string and a series of arrays.
FormatDateTime= Formats a date-and-time value.
FormatFloat= Formats a floating point value.
FreeMem= Releases allocated memory.
GetMem= Allocates dynamic memory and a pointer to the address of the block.
Halt= Initiates abnormal termination of a program.
Hi= Returns the high-order byte of an expression as an unsigned value.
High= Returns the highest value in the range of a type, array, or string.
Inc= Increments an ordinal variable or a typed pointer variable.
Initialize= Initializes a dynamically allocated variable.
Insert= Inserts a substring at a specified point in a string.
Int= Returns the integer part of a real number.
IntToStr= Converts an integer to a string.
Length= Returns the length of a string or array.
Lo =Returns the low-order byte of an expression as an unsigned value.
Low =Returns the lowest value in the range of a type, array, or string.
LowerCase= Converts an ASCII string to lowercase.
MaxIntValue =Returns the largest signed value in an integer array.
MaxValue= Returns the largest signed value in an array.
MinIntValue =Returns the smallest signed value in an integer array.
MinValue= Returns smallest signed value in an array.
New =Creates a dynamic allocated variable memory and references it with a specified pointer.
Now= Returns the current date and time.
Ord =Returns the ordinal integer value of an ordinal-type expression.
Pos =Returns the index of the first single-byte character of a specified substring in a string.
Pred= Returns the predecessor of an ordinal value.
Ptr =Converts a value to a pointer.
Random =Generates random numbers within a specified range.
ReallocMem =Reallocates a dynamically allocatable memory.
Round= Returns the value of a real rounded to the nearest whole number.
SetLength= Sets the dynamic length of a string variable or array.
SetString= Sets the contents and length of the given string.
ShowException= Displays an exception message with its address.
ShowMessage= Displays a message box with an unformatted string and an OK button.
ShowMessageFmt= Displays a message box with a formatted string and an OK button.
Sin Returns= the sine of an angle in radians.
SizeOf =Returns the number of bytes occupied by a variable or type.
Sqr= Returns the square of a number.
Sqrt =Returns the square root of a number.
Str= Converts an integer or real number into a string.
StrToCurr= Converts a string to a currency value.
StrToDate= Converts a string to a date format (TDateTime).
StrToDateTime= Converts a string to a TDateTime.
StrToFloat= Converts a string to a floating-point value.
StrToInt= Converts a string to an integer.
StrToTime= Converts a string to a time format (TDateTime).
StrUpper= Returns an ASCII string in upper case.
Succ= Returns the successor of an ordinal value.
Sum =Returns the sum of the elements from an array.
Time= Returns the current time.
TimeToStr= Converts a variable of type TDateTime to a string.
Trunc =Truncates a real number to an integer.
UniqueString= Ensures that a string has only one reference. (The string may be copied to produce a single reference.)
UpCase= Converts a character to uppercase.
UpperCase= Returns a string in uppercase.
VarArrayCreate= Creates a variant array.
VarArrayDimCount= Returns number of dimensions of a variant array.
VarArrayHighBound= Returns high bound for a dimension in a variant array.
VarArrayLock= Locks a variant array and returns a pointer to the data.
VarArrayLowBound =Returns the low bound of a dimension in a variant array.
VarArrayOf =Creates and fills a one-dimensional variant array.
VarArrayRedim =Resizes a variant array.
VarArrayRef= Returns a reference to the passed variant array.
VarArrayUnlock= Unlocks a variant array.
VarAsType= Converts a variant to specified type.
VarCast= Converts a variant to a specified type, storing the result in a variable.
VarClear =Clears a variant.
VarCopy= Copies a variant.
VarToStr= Converts variant to string.
VarType =Returns type code of specified variant.
 
http://www.programyukle.org
Atlanilacak Forum:

En Çok İndirilenlerYeni Eklenenler

image Outlook Express 6.0 [14975]  
image SPSS 15.0 [13145]  
image Msn Dondurucu ( Msn F... [12881]  
image GTA Mod Installer v2.2... [9669]  
image Cep Okey [9614]  
image Eşli Batak 2.0.0.8 [8551]  
image Cepte Televizyon v1.5 [7155]  
image Nokia N70 İçin Full Pr... [6216]  
image Championship Manager 0... [4359]  
image Ders dağıtım programı ... [4258]  
image CurrPortS 2.12 [18.12.2014]
image PHTML Encoder 6.4 [18.12.2014]
image DzSoft PHP Editor 4.2.7.7 [18.12.2014]
image KoolMoves 9.2.1 [18.12.2014]
image Chicken Invaders 2 2.0 [18.12.2014]
image Natalie Brooks: Kayıp Krallığın ... [18.12.2014]
image Zuma Deluxe 1.0 [18.12.2014]
image Bus Driver 1.5 [18.12.2014]
image Mario Forever 5.8 [18.12.2014]
image Icy Tower 1.5.1 [18.12.2014]
site statistics

Edit by MuhBim
Copyright © 2007 Programyukle.Org
Powered by PHP-Fusion copyright © 2002 - 2018 by Nick Jones.
Released as free software without warranties under GNU Affero GPL v3.
Sayfa oluşturulma süresi: 0.12 saniye | 50,114,742 Tekil Ziyaretçi | jQ Blog