🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.delphi.database.dotnet
Article #27

Re: Help with ASP translation

#27
From: Robin
Date: Tue, 13 Feb 2007 01:17
35 lines
1793 bytes
Hey there,

As a starting point;

Delphi uses := for assigning.  = is for comparison only.
Delphi uses // for comments (there are other ways too)
Delphi uses single quotes instead of double quotes for strings.
Delphi uses nil instead of nothing.  In some cases, FreeAndNil may be 
better.  (as it frees the memory)


Variables would be declared using the key word var, along with their 
type, separated by a colon.  Like this:

var
   xCon : ADODB.Connection;
   strCon : String;
etc.....


Creating an object (instanciating it) is done by assigning it a created 
object.  Like this:

myVariable := myObjectType.Create;

or in your example:

xCon := ADODB.Connection.Create;


-- 
Robin.

Australian Bridal Accessories := http://www.bridalbuzz.com.au
Turbo for Noobs (a work in progress) := http://turbofornoobs.blogspot.com/
Technical Details
Message-ID: <45d1117e@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news2.google.com!news3.google.com!news4.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail
References: <45cb7078$1@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Thread: 1effe6,9e91202acc2154d3
X-Google-Attributes: gid1effe6,public
X-Google-Language: ENGLISH,ASCII-7-bit
Date: Tue, 13 Feb 2007 12:17:06 +1100
From: Robin <Robin@.com>
User-Agent: Thunderbird 1.5.0.7 (Windows/20060909)
MIME-Version: 1.0
Newsgroups: borland.public.delphi.database.dotnet
Subject: Re: Help with ASP translation
References: <45cb7078$1@newsgroups.borland.com>
In-Reply-To: <45cb7078$1@newsgroups.borland.com>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
NNTP-Posting-Host: 165.228.6.111
Message-ID: <45d1117e@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1171329406 165.228.6.111 (12 Feb 2007 17:16:46 -0800)
Lines: 35
Path: arc1-ca.pugleaf.net!g2news2.google.com!news3.google.com!news4.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail