move next

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • solar

    move next

    Is there a command in VB with which to move to the next row in the
    table of Access database ?
    For example my table TblCrates consists of :

    CrateId City

    1. Berlin

    I need a command in VB with which to go to the next row,
    in the case the CrateId will be 2

    Can somebody help me ?

  • Allen Browne

    #2
    Re: move next

    There's not a nice way to do this in a table.

    Forms are designed to be the interface.
    Create a form (datasheet view if you wish) bound to your table.
    You can now do stuff such as:
    RunCommand acCmdRecordsGoT oNext

    --
    Allen Browne - Microsoft MVP. Perth, Western Australia.
    Tips for Access users - http://allenbrowne.com/tips.html
    Reply to group, rather than allenbrowne at mvps dot org.

    "solar" <sprimerov@gmai l.com> wrote in message
    news:1134578404 .935909.216770@ g43g2000cwa.goo glegroups.com.. .[color=blue]
    > Is there a command in VB with which to move to the next row in the
    > table of Access database ?
    > For example my table TblCrates consists of :
    >
    > CrateId City
    >
    > 1. Berlin
    >
    > I need a command in VB with which to go to the next row,
    > in the case the CrateId will be 2
    >
    > Can somebody help me ?[/color]


    Comment

    • Larry Linson

      #3
      Re: move next

      If you are using VBA code to processing a Recordset in DAO, there is a
      MoveNext method for the Recordset object that will do exactly what you want.
      As Allen explained, you can't do that in datasheet view, but you can, in a
      Form, using either the approach he explained or by using the Form's
      RecordsetClone and Bookmarks (The way Allen described is easier, but it is
      sometimes useful to know there is an alternative.)

      Larry Linson
      Microsoft Access MVP

      "solar" <sprimerov@gmai l.com> wrote in message
      news:1134578404 .935909.216770@ g43g2000cwa.goo glegroups.com.. .[color=blue]
      > Is there a command in VB with which to move to the next row in the
      > table of Access database ?
      > For example my table TblCrates consists of :
      >
      > CrateId City
      >
      > 1. Berlin
      >
      > I need a command in VB with which to go to the next row,
      > in the case the CrateId will be 2
      >
      > Can somebody help me ?
      >[/color]


      Comment

      Working...