AppenDB and RecNo()

This forum is meant for questions and discussions about the X# language and tools
Post Reply
User avatar
Horst
Posts: 327
Joined: Tue Oct 13, 2015 3:27 pm

AppenDB and RecNo()

Post by Horst »

Hello
odbServerNew:AppendDB (odbServer, , {|| _Field->RecNo() < nRecno})
This works on VO but produce a compiler error on X#
error XS0103: The name 'RecNo' does not exist in the current context 2870,49 Auftrag.prg HandAuftragContext:Auftrag_Ein_Change
i tried - FIELD->RecNo() - same like _Field and then _Field->RecNo or FIELD->RecNo or RecNo() - this compiles but doesnt work. The DB has one empty record.

Horst
User avatar
Chris
Posts: 4593
Joined: Thu Oct 08, 2015 7:48 am
Location: Greece

AppenDB and RecNo()

Post by Chris »

Hi Horst,

Indeed, I see VO allows this. But isn't this totally wrong? RecNo() is not a field, it is just a function call..

Please remove the "_field->" part and it should work as expected.
Chris Pyrgas

XSharp Development Team test
chris(at)xsharp.eu
User avatar
Horst
Posts: 327
Joined: Tue Oct 13, 2015 3:27 pm

AppenDB and RecNo()

Post by Horst »

Hi Chris
thanks for your quick answer. i wanna hit myself, i tried several solutions (also RecNo()) but i startet the wrong part of the app.
shame on me.
Horst
User avatar
Chris
Posts: 4593
Joined: Thu Oct 08, 2015 7:48 am
Location: Greece

AppenDB and RecNo()

Post by Chris »

Hehe, it happens to everyone :)
Chris Pyrgas

XSharp Development Team test
chris(at)xsharp.eu
Post Reply