Results 1 to 3 of 3
  1. #1
    Join Date
    Feb 2003
    Location
    Los Angeles
    Posts
    18

    Question Unanswered: UltraLite and AppForge

    Greeting all,

    I'm trying to develop an app' with AppForge and UltraLite,
    when I query the DB I get no result for known giving result attribute,
    this is my code :

    Dim MyTable As ULTable
    Set MyTable = Conn.GetTable("TableName")
    MyTable.Open "primary"
    MyTable.FindBegin
    MyTable.Column("ID1").LongValue = 10027
    If MyTable.FindFirst Then
    While MyTable.MoveNext
    frmRes.lstRes.AddItem CStr(MyTable.Column("ID2").LongValue)
    Wend
    Else
    frmRes.lstRes.AddItem "Sorry, No Result . . ."
    End If

    any one know I don't get any result ?

    P.S

    if I change the else to :
    MyTable.MoveBeforeFirst
    While MyTable.MoveNext
    frmRes.lstRes.AddItem CStr(MyTable.Column("ID2").LongValue)
    Wend
    I get all the result from MyTable so I know that the table is not empty . . .
    Eddie.

  2. #2
    Join Date
    Feb 2003
    Posts
    1

    RE: UltraLite and Appforge

    Is "primary" an index on ID1 column ?
    Your find will not work if it is not.

    Also, after calling FindFirst you are on the first row that was found. To get to subsequent rows, use FindNext not MoveNext.

    I think you will get many more responses in Usenet Newsgroup sybase.public.sqlanywhere.ultralite
    Not sure if that can be accessed from dbforums but there is a webinterface at http://www.ianywhere.com/support/ultralite_ng.html

    data

  3. #3
    Join Date
    Feb 2003
    Location
    Los Angeles
    Posts
    18
    hade some problem with the indexes,
    everything working fine now.
    Eddie.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •