IT SOLUTIONS
Your full service technology partner! 
-Collapse +Expand
Paradox
Search Paradox Group:

Advanced
-Collapse +Expand Paradox To/From
To/FromCODEGuides
-Collapse +Expand Paradox Store
PRESTWOODSTORE
   ► KBDesktop Data...Paradox & Ob...ObjectPAL Co...OPAL: Langua...     Print This   

Paradox KB: OPAL: Language Basics Topic



30 Articles Found in the OPAL: Language Basics Topic 

  KB Article    

Mike Prestwood
1. A 10 Minute ObjectPAL Quick Start

If you've never programmed in ObjectPAL, spend 10 minutes and see how easy it is to program Paradox for Windows.

6 years ago, and updated 6 years ago

Article
Nothing New Since Your Last Visit
9047
Hits

Corel Paradox / ObjectPAL Coding

Mike Prestwood
2. An ObjectPAL Primer: Part 1

This detailed ObjectPAL primer will get you up and running developing in Paradox/ObjectPAL within a few hours.

11 years ago, and updated 54 months ago
(2 Comments , last by mprestwood )

Article
Nothing New Since Your Last Visit
10250
Hits

Corel Paradox / ObjectPAL Coding

Mike Prestwood
3. An ObjectPAL Primer: Part 2 Part 2.
11 years ago, and updated 6 years ago

Article
Nothing New Since Your Last Visit
7823
Hits

Corel Paradox / ObjectPAL Coding

Mike Prestwood
4. An ObjectPAL Primer: Part 3

Part 3.

11 years ago, and updated 5 years ago
(3 Comments )

Article
Nothing New Since Your Last Visit  
12364
Hits

Corel Paradox / ObjectPAL Coding

Mike Prestwood
5. Before You Code

Before you code in ObjectPAL, ask yourself two questions. Does Paradox already do this? Is there a better and easier way? Remember, simple solutions for simple problems.

7 years ago, and updated 5 years ago

Tip
Nothing New Since Your Last Visit
3139
Hits

Corel Paradox / ObjectPAL Coding

Mike Prestwood
6. Camel Casing Camel Casing capitalizes the first character of each word except the first word, so it frequently looks like a one or two hump camel. Used by many languages including Paradox's ObjectPAL. You can contrast Camel Casing with Pascal Casing which capitalizes the first character of each word (including acronyms over two letters in length) and was popularized by Pascal.
6 years ago, and updated 6 years ago

Definition
Nothing New Since Your Last Visit
4889
Hits

Corel Paradox / ObjectPAL Coding

Mike Prestwood
7. Consolas Font If you're looking for a replacement for Courier when editing ObjectPAL code, consider Consolas. The Microsoft Consolas Font Family is a set of highly legible fonts designed for ClearType. It is intended for use in programming environments and other circumstances where a monospaced font is specified. This installation package will set the default font for Visual Studio to Consolas, but if you don't have Visual Studio installed, it just skips that process without error.
6 years ago

Download
Nothing New Since Your Last Visit
5545
Hits

Corel Paradox / ObjectPAL Coding

Mike Prestwood
8. Don't Leave Experiments In Your Code!

If, in experimentation, you use sleep(), doDefault, or DisableDefault to overcome some odd or misunderstood behavior, do not leave the commands in your code. If using the command didnt seem to make a difference, then take it out. Use commands only when they are called for. One great way to really learn the event model and the power of these and other commands is to experiment with adding them. Remember to take them out, however, if they do not do what you wanted.

7 years ago, and updated 5 years ago

Tip
Nothing New Since Your Last Visit
3152
Hits

Corel Paradox / ObjectPAL Coding

Mike Prestwood
9. Exploring Where To Put Code

Think levels when you code in the Pardox ObjectPAL development environment.

6 years ago
(1 Comments , last by Anonymous )

Article
Nothing New Since Your Last Visit
6369
Hits

Corel Paradox / ObjectPAL Coding

Mike Prestwood
10. Object.Method() Syntax

The syntax of object.method() is consistent throughout ObjectPAL. If an object with the name box has code on its mouseClick event, you can access that code with box.mouseClick() method from any other object. When this code executes, the UIObject method mouseClick() calls the mouseClick event.

How do you know when you can call the code in a built-in method of an object? Easy, if the run-time library has a method equivalent, then you can use itfor example, mouseClick() and pushButton().

7 years ago, and updated 5 years ago

Tip
Nothing New Since Your Last Visit
3467
Hits

Corel Paradox / ObjectPAL Coding

Mike Prestwood
11. ObjectPAL ObjectPAL stands for Object Paradox Application Language.
7 years ago, and updated 6 years ago

Definition
Nothing New Since Your Last Visit
3385
Hits

Corel Paradox / ObjectPAL Coding

Mike Prestwood
12. ObjectPAL Assignment (=)

ObjectPAL uses = for it's assignment operator.

6 years ago, and updated 6 years ago

Code
Nothing New Since Your Last Visit  
3463
Hits

Corel Paradox / ObjectPAL Coding

Mike Prestwood
13. ObjectPAL Case Sensitivity (No)

ObjectPAL is not case sensitive. My preference for ObjectPAL is to follow the camel casing promoted in the examples and help files originally developed by Borland.

6 years ago, and updated 5 years ago

Code
Nothing New Since Your Last Visit  
3996
Hits

Corel Paradox / ObjectPAL Coding

Mike Prestwood
14. ObjectPAL Code Blocks (endXxxx)

ObjectPAL code blocks are surrounded by statement ending keywords that all use End with camel caps such as endMethod, endVar, endIf, endSwitch, and endTry.

6 years ago, and updated 5 years ago

Code
Nothing New Since Your Last Visit
3135
Hits

Corel Paradox / ObjectPAL Coding

Mike Prestwood
15. ObjectPAL Comments (; and { ... })

Commenting Code
ObjectPAL uses ; for a single line comment and { } for a multiple line comment.

6 years ago, and updated 5 years ago

Code
Nothing New Since Your Last Visit  
3632
Hits

Corel Paradox / ObjectPAL Coding

Mike Prestwood
16. ObjectPAL Comparison Operators (=, <>)

Common comparison operators:

= equal
<> not equal
< less than
> greater than
<= less than or equal
>= greater than or equal

5 years ago

Code

KB Post
Nothing New Since Your Last Visit
8947
Hits

Corel Paradox / ObjectPAL Coding

Mike Prestwood
17. ObjectPAL Constants (const..endConst)

In ObjectPAL, you declare one or more constant values within a const..endConst block. Optionally, you can specify the dataType by casting the value as part of the declaration. If you do not specify the data type, the data type is inferred from the value as either a LongInt, a Number, a SmallInt, or a String. As with variables, the const..endConst block can come within a method or procedure as the first bit of code, or in the Const window. Putting it above the method or procedure is allowed but has no significance so don't.

6 years ago, and updated 5 years ago

Code
Nothing New Since Your Last Visit  
3544
Hits

Corel Paradox / ObjectPAL Coding

Mike Prestwood
18. ObjectPAL Development Tools

Corel Paradox for Windows (was Borland Paradox). Also, Borland used to offer a Paradox for DOS tool which support it's Paradox Application Language (PAL) which is not compatible with ObjectPAL. The biggest drawback to Paradox is that Corel does not have anyone at Corel actively developing Paradox for Windows (as opposed to Microsoft Access which does).

6 years ago, and updated 5 years ago

Code
Nothing New Since Your Last Visit
3490
Hits

Corel Paradox / ObjectPAL Coding

Mike Prestwood
19. ObjectPAL Edit Record (insertRecord, postRecord, edit)

In ObjectPAL, you use Cursor.InsertRecord to add a new record, Cursor.postRecord to post the record, and Cursor.deleteRecord() to delete it. To edit a record, you must put the cursor into edit mode, Cursor.Edit(). (A cursor applies to both a TCursor and UIObject.)

ObjectPAL gives you tremendous flexibility with editing data and includes many additional commands such as insertAfterRecord and isEdit. For dBASE tables, you can also use unDeleteRecord() to un-delete a record. See the ObjectPAL help for more commands.

58 months ago

Code
Nothing New Since Your Last Visit
3650
Hits

Corel Paradox / ObjectPAL Coding

Mike Prestwood
20. ObjectPAL Empty String Check (isBlank() or not isAssigned())

In ObjectPAL, an empty variable can be unassigned (essentially null) or blank (equivalent to ""). You have to use both isBlank and isAssigned to check for an empty string.

5 years ago, and updated 58 months ago

Code

KB Post
Nothing New Since Your Last Visit
4488
Hits

Corel Paradox / ObjectPAL Coding

Mike Prestwood
21. ObjectPAL End of Statement (whitespace)

Languages Focus: End of Statement

In coding languages, common End of statement specifiers include a semicolon and return (others exist too). Also of concern when studying a language is can you put two statements on a single code line and can you break a single statement into two or more code lines.

ObjectPAL End of Statement

ObjectPAL is a bit unique in that it doesn't use a semicolon nor a return to mark the end of a line, it uses whitespace which can be a return, space, or tab. This is a bit unusual but does allow for some nice formatting of code.

6 years ago, and updated 5 years ago
(4 Comments , last by mprestwood )

Code
Nothing New Since Your Last Visit  
4273
Hits

Corel Paradox / ObjectPAL Coding

Mike Prestwood
22. ObjectPAL If Statement (If..Else..EndIf, or switch)

ObjectPAL supports a simple If...Else...EndIf statement.

Notice ObjectPAL does not support an ElseIf feature as part of an if statement. Instead use a switch statement

6 years ago, and updated 5 years ago

Code
Nothing New Since Your Last Visit  
5580
Hits

Corel Paradox / ObjectPAL Coding

Mike Prestwood
23. ObjectPAL Level Beginner or Advanced? Whether your ObjectPAL level is set to Beginner or Advanced, you can use all the ObjectPAL methods, procedures, properties, constants, keywords, and so on. The level panel is a help filter used just for learning purposes. However, because you could in effect "hide" code from yourself, I recommend setting this to Advanced (never use beginner).
7 years ago, and updated 6 years ago

Tip
Nothing New Since Your Last Visit
2505
Hits

Corel Paradox / ObjectPAL Coding

Mike Prestwood
24. ObjectPAL Literals (quote)

Literals are quoted as in "Prestwood".  If you need to embed a quote use a slash in front of the quote as in \"

In ObjectPAL, string literals are limited to 255 characters but there's nothing preventing you from using multiple string literals together as in:

msgInfo("", "Hi Mike: " + "You can add literals together in ObjectPAL")
6 years ago, and updated 5 years ago

Code
Nothing New Since Your Last Visit  
4420
Hits

Corel Paradox / ObjectPAL Coding

Mike Prestwood
25. ObjectPAL Logical Operators

ObjectPAL logical operators:

and and, as in this and that
or or, as in this or that
Not Not, as in Not This

5 years ago, and updated 5 years ago

Code

Article
Nothing New Since Your Last Visit  
4513
Hits

Corel Paradox / ObjectPAL Coding

Mike Prestwood
26. ObjectPAL String Concatenation (+)

String literals s are limited to 255 characters but you can simply add two strings together as in:

s = "A long string." + "Another long string."
6 years ago, and updated 5 years ago

Code
Nothing New Since Your Last Visit
3555
Hits

Corel Paradox / ObjectPAL Coding

Mike Prestwood
27. ObjectPAL Unary Operators

The ObjectPAL unary operators are:

+
-
Not

5 years ago

Code
Nothing New Since Your Last Visit
3276
Hits

Corel Paradox / ObjectPAL Coding

Mike Prestwood
28. ObjectPAL Variables (var x SmallInt endVar)

Declaring variables is optional unless you click Program | Compiler Warnings while in the ObjectPAL editor for every form, script, and library you create. Using Compiler Warnings is strongly recommended to avoid incorrectly typing an existing variable and to avoid any confusion about variable scope. Also recommended is turning on Compile with Debug for every form, script, and library too for tighter, cleaner code.

Undeclared variables are AnyType variables. Common data types include Currency, Date, Datetime, Logical, LongInt, Number, SmallInt, String, and Time.

Declare local variables within a method. If you want a local static variable (retains it's value because it is not destroyed), declare the varialbes above the method. Variables declared in an object's Var window are visible to all methods attached to that object, and objects that it contains.

6 years ago, and updated 57 months ago
(1 Comments , last by marianchovan )

Code
Nothing New Since Your Last Visit  
5503
Hits

Corel Paradox / ObjectPAL Coding

Mike Prestwood
29. Study The Experts

Paradox provides experts that generate code at the field level, in the form open, etc. It is a good idea to study the ObjectPAL generated by these experts.

7 years ago, and updated 5 years ago

Tip
Nothing New Since Your Last Visit
3038
Hits

Corel Paradox / ObjectPAL Coding

Mike Prestwood
30. Where to Put Code - Short Overview Techniques for thinking about where to put code in Paradox's object-based event model.
7 years ago, and updated 6 years ago
(1 Comments , last by Anonymous )

Article
Nothing New Since Your Last Visit
5212
Hits

Corel Paradox / ObjectPAL Coding

Icon Legend:
Since your last logged visit:
- New to you or updated since your last visit (sign in now to activate).
- NOT new to you since your last visit (sign in now to activate).

New Corel Paradox / ObjectPAL Coding Knowledge Base Post...

Share your knowledge with the WORLD! In addition to adding comments to existing posts, you can post knowledge you've acquired. We welcome full articles (intro with screen shots), general posts (shorter), and tidbits (tips, FAQs, definitions, etc.).

Post New...

Tidbit Post: Short Flashcard FAQ Definition Quick Tip Code Snippet
Longer Post: Full Article General Post File Link Error News
Other: Blog Topic
Or, if YOU have a question...
  Corel Paradox / ObjectPAL Coding Message Board
-
  Load Time=less than 1 second.
 
Print This
-
 
Have a question? Need our services? Contact us now.
--Mike Prestwood

Call: 916-726-5675

email: info@prestwood.com


-
 
Connect With Us...
PrestwoodBoards
Join Us!
Facebook
Like our page!!!
Twitter
Follow us!
LinkedIn
Join Group
YouTube
View channel.
Go ahead!   Use Us! Call: 916-726-5675 


©1995-2014 Prestwood IT Solutions.   [Security & Privacy]   Made in the U.S.A..   No H1-B.   No offshoring.