xsharp.eu • Immediate window understanding X# syntax
Page 1 of 1

Immediate window understanding X# syntax

Posted: Thu Mar 09, 2023 11:55 am
by ic2
I was looking forward to the immediate window understanding X# syntax from 2.15 onwards.
I just installed 2.15 and tried this:

Code: Select all

Self:oDBEmails:Recno
which gave me the error:

error CS1061: 'IC2DbServer' does not contain a definition for 'Recno' and no accessible extension method 'Recno' accepting a first argument of type 'IC2DbServer' could be found (are you missing a using directive or an assembly reference?)

Is there anything I can do to make this work? Or does this need to be fixed by you?

Dick

Immediate window understanding X# syntax

Posted: Thu Mar 09, 2023 11:56 am
by robert
Dick,
Can you check:
Tools/Options
Debugging / XSharp Debugger
Is "Enable Late Binding" enabled ?

Robert

Immediate window understanding X# syntax

Posted: Thu Mar 09, 2023 1:37 pm
by ic2
Hello Robert,

There's no such option but that is possibly because in the meantime I reinstalled X# 2.14.

See my other message.

Dick

Immediate window understanding X# syntax

Posted: Thu Mar 09, 2023 1:39 pm
by robert
Dick
This is a new option in 2.15.
I see no other message.

Robert

Immediate window understanding X# syntax

Posted: Thu Mar 09, 2023 3:16 pm
by ic2
Hello Robert,

It is in the subscriber forum, I realized that 2.15 is -yet- Fox only.

https://www.xsharp.eu/forum/private-pro ... lling-2-15

Dick

Immediate window understanding X# syntax

Posted: Mon Mar 13, 2023 1:55 pm
by ic2
Hello Robert,

I've quickly tried with 2.15 if the Immediate Window works with the settings you describe above and found this:

When we set all Option to true except the first (Clipper compatible integer divisions and the last 2 (USe FLOAT/Zero based..) the program already crashes during debugging when the first (ADS) dbServer is opened. So even before accessing any Immediate Window.
This seems solved when we only set the 3 "Immediate..." settings to true.

However, we can still not find values from IW, here's a valid database/field (mydbf/myfield). See what we tried in bold and the errors following it. We tried a VO function in IW and this did work, regardless the capitalization. That's great, but inspecting fields of a dbf should work too.

MyDBF:myfield
error XS1061: 'usual' does not contain a definition for 'myfield' and no accessible extension method 'myfield' accepting a first argument of type 'usual' could be found (are you missing a using directive or an assembly reference?)
MyDBF
Evaluation requires a thread to run temporarily. Use the Watch window to perform the evaluation.
MyDBF:fieldget(#myfield)
error XS1061: 'usual' does not contain a definition for 'fieldget' and no accessible extension method 'fieldget' accepting a first argument of type 'usual' could be found (are you missing a using directive or an assembly reference?)


Dick

Immediate window understanding X# syntax

Posted: Mon Mar 13, 2023 2:54 pm
by robert
Dick,

We are testing a 2.16 internally. This should be fixed in 2.16.
The problem is that MyDbf is not typed, so all code that you have typed is executed late-bound. In your version that has some problems.

I am not sure what you mean with "the program crashes'. Which program crashes? The VS in which you are debugging?
Your program? What is the error message?
Do you have any watch expressions in the watch window? These could be the reason for an error when debugging. That should also be solved in 2.16.


Robert