PowerBuilder Forum

Members Login
Username 
 
Password 
    Remember Me  
Post Info TOPIC: Common PowerBuilder Variable Standards


Veteran Member

Status: Offline
Posts: 40
Date:
Common PowerBuilder Variable Standards


Some common standards in the PB world surrounding variable naming...

-The first letter of the variable name is determined by the variable's scope.
-Global -- g
-Instance -- i
-Local -- l
-The second letter of the variable name is determined by the variable's type.  Some of the common types:
-Boolean -- b
-DataStore -- ds
-DataWindow -- dw
-DataWindowChild -- dwc
-Date -- d
-DateTime -- dt
-Decimal -- d
-Integer -- i
-Long -- l
-String -- s
-Window -- w
-Always followed by and underscore, and then the descriptive portion of the name.

Examples:

-Global Level
String gs_filename
Long gl_id_no

-Instance Level
String is_folder
Long il_badge_no

-Local Level
String ls_name
Long ll_count

__________________


Newbie

Status: Offline
Posts: 2
Date:

Hi thekl0wn, many thanks for the information given wink.gif

__________________
Page 1 of 1  sorted by
Quick Reply

Please log in to post quick replies.

Tweet this page Post to Digg Post to Del.icio.us


Create your own FREE Forum
Report Abuse
Powered by ActiveBoard