APIs - .NET

Ruslan Zasukhin ruslan_zasukhin at valentina-db.com
Thu Oct 18 15:03:02 CDT 2012


On 10/10/12 2:13 PM, "DMW" <consult at excelkb.com> wrote:

Hi Denis,

> Hi all,
> 
> After working a lot with SQL I have decided to explore and learn more about
> Valentinas APIs.
> 
> The samples at the Wiki is quite simplified and do not provide enough
> guidelines enabling me to understand some aspects here.
> 
> Q1: If I want to show a specific record¹s data (not the first, not the last,
> not the next, not the previously).
> I need to make some kind of look up first ­ how do I do that?
> 
> Second,  I want to grab the data for that record and show it in the Form - How
> do I do that?

1) VNET contains a lots of API_way examples.
Have you try learn them?


2) here you can find PDF, which have the same as WIKI,
But really adopted to NET syntax

<http://www.valentina-db.com/docs/dokuwiki/v5/doku.php?id=valentina:products
:adk:vnet:vnet>


3) in short.

API should be used only if you work with local db.

You operate with help of
  VDatabase + VTable + VField +  VSet/VBitSet/VArraySet

Instead of 
   Vdatabase + VCursor + VField



** You need look on Vfield class, it has many search funcs

   Vset res =   Vfield.FindValue()
                               .FindRange


So you get instead of cursor some Set of records.
Can be used BitSet and ArraySet.
In wiki there is description of difference.


>From set you get RecID of a record.
Then use 

 tbl.RecID = foundRecID

And then you read fields like in cursor

Loop by fields
{
        fld = tbl.Field( "name" )
        string s = fld.value

        show in form
}



-- 
Best regards,

Ruslan Zasukhin
VP Engineering and New Technology
Paradigma Software, Inc

Valentina - Joining Worlds of Information
http://www.paradigmasoft.com

[I feel the need: the need for speed]




More information about the Valentina mailing list