Igos,
No, this works correctly, as far as I can tell. I've used techniques like this for years without problems.
To verify this, I created a form with an Edit box and a button. I named the edit box fldValue and then added the following code to the button's pushButton() event:
Code:
method pushButton(var eventInfo Event)
var
strAValue String
endVar
strAValue = fldValue.Value
strAValue.view( "Before Calling Proc 1" )
proc1( strAValue )
strAValue.view( "After Calling Proc 1" )
endMethod
Next, I created two procedures on the button, called proc1 and proc2, respectively. Here's the code:
Code:
method proc1( const strAValue String )
strAValue.view( "Before Calling Proc 2" )
proc2( strAValue )
strAValue.view( "After Calling Proc 2" )
endMethod
method proc2( const strAValue String )
strAValue.view( "Inside Proc 2" )
endMethod
Finally, I placed a breakpoint on the line of code in proc2() and ran the form. I typed "Fred" into the edit box and clicked the button. As expected, the value moved correctly into the procedures and I was able to inspect it with the debugger when it hit the breakpoint.
Now, there are some things to remember when you're passing constant values into procedures (or methods), but I expect you already understand those. For example, you can't modify a constant parameter (because it's a constant parameter) and you can't pass constant parameters as variable parameters, for the same reason (e.g. constants can't be changed and the ObjectPAL parser enforces this).
This looks like a sample created due to a larger issue. Is it? If so, can you try to explain that? Perhaps we'll see see something in that.
Hope this helps...
-- Lance
P.S. There were issues with the debugger in older versions of Paradox, but most of those were ironed out by Paradox 5.0.1. If you're using an older version, try to upgrade to at least 5.0.1.