Results 1 to 11 of 11

Thread: Show all records in a "continuous Form" form in Access 2000

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Jun 2003
    Posts
    114

    Show all records in a "continuous Form" form in Access 2000

    Hi all.

    I know how to goto the 1st, last, blah blah record ... What I'm looking for now is a setting that forces the form to display all records (that will fit on the screen) in the form. Currently, I populate a table and bind the form to that table ... Only the 1st record is displayed ... When I pull the form (resize it) down the other records show ... Any thoughts? Some size parameter related to the # of records? Hmmm ....

    Let me clarify ... All the records are there and displayed. The SIZE of the window is what I'm trying to adjust ... (when I hover over the bottom of the window/dialog and drag down ...)

    Thanks!

    - Mike

  2. #2
    Hyperactive Member
    Join Date
    Mar 2002
    Posts
    424
    go into the forms design view and change if from single form to continuous form...

  3. #3

    Thread Starter
    Lively Member
    Join Date
    Jun 2003
    Posts
    114
    Ephesians,

    Sorry. I should have explained it better ... It is already a "Continuous Forms" form ... Currently it has to do with my not binding the form to a table until run-time ... If I turn off "autosize" and size the design window to display a couple rows and save it, that at least gets me some display ...

  4. #4
    Hyperactive Member
    Join Date
    Mar 2002
    Posts
    424
    Well once it's bound at run time..I'm assuming you've got some bound controls at least.. just to a me.requery.

  5. #5

    Thread Starter
    Lively Member
    Join Date
    Jun 2003
    Posts
    114
    Ephesians,

    Ok. I already do that ... I guess I'm not communicating effectively. What I want to do I guess is to programmatically resize the widow to show all the records ... Right now, because of my binding to a table in code and the subsequent ReQuery, all that is displayed in the window is the 1st record. When I manually resize the window (i.e. what I said before - drag the bottom of the window down ) the records are already there and a RePaint occurs ...

  6. #6
    Hyperactive Member
    Join Date
    Mar 2002
    Posts
    424
    What about something like docmd.maximize? Or are you looking to resize the form to a specific size?

  7. #7

    Thread Starter
    Lively Member
    Join Date
    Jun 2003
    Posts
    114
    I think I found it ... Me.WindowHeight I'll just have to finagle the adjustment height relative to the # of records ...

  8. #8
    Hyperactive Member
    Join Date
    Mar 2002
    Posts
    424
    Why are you binding the table at runtime through code rather than the form recordsource? It would be so much easier to have your continuous form is you just put the source in the record source before runtime.

  9. #9

    Thread Starter
    Lively Member
    Join Date
    Jun 2003
    Posts
    114
    Because I create and name the table during runtime ... Unfortunately the WindowHeight is a poperty that I cannot change at runtime ...

  10. #10
    Hyperactive Member
    Join Date
    Mar 2002
    Posts
    424
    sure you can.. just use the SetWindowPos api..

  11. #11
    Lively Member
    Join Date
    Jun 2003
    Location
    france
    Posts
    71
    i used this for displaying a defined number of command button on excel, maybe it can help

    ------------------------------------------------------------------------
    Private Sub UserForm_Initialize()
    Dim lin As Variant

    Windows("new quotation.xls").Activate
    Sheets("temp").Select
    lin = 4
    uphere:
    If Range("A" & lin) <> "" Then
    lin = lin + 1
    GoTo uphere
    End If

    CommandButton1.Caption = Range("A2").Value
    CommandButton1.Left = 42
    CommandButton2.Caption = Range("A3").Value
    CommandButton2.Left = 42
    CommandButton3.Caption = Range("A4").Value
    CommandButton4.Caption = Range("A5").Value
    CommandButton5.Caption = Range("A6").Value
    CommandButton6.Caption = Range("A7").Value
    CommandButton7.Caption = Range("A8").Value
    CommandButton8.Caption = Range("A9").Value
    CommandButton9.Caption = Range("A10").Value
    CommandButton10.Caption = Range("A11").Value
    CommandButton3.Left = 420
    CommandButton4.Left = 420
    CommandButton5.Left = 420
    CommandButton6.Left = 420
    CommandButton7.Left = 420
    CommandButton8.Left = 420
    CommandButton9.Left = 420
    CommandButton10.Left = 420
    whichproduct.Height = 100

    If lin >= 5 Then
    CommandButton3.Left = 42
    whichproduct.Height = 130
    End If
    If lin >= 6 Then
    CommandButton4.Left = 42
    whichproduct.Height = 160
    End If
    If lin >= 7 Then
    CommandButton5.Left = 42
    whichproduct.Height = 190
    End If
    If lin >= 8 Then
    CommandButton6.Left = 42
    whichproduct.Height = 220
    End If
    If lin >= 9 Then
    CommandButton7.Left = 42
    whichproduct.Height = 250
    End If
    If lin >= 10 Then
    CommandButton8.Left = 42
    whichproduct.Height = 280
    End If
    If lin >= 11 Then
    CommandButton9.Left = 42
    whichproduct.Height = 310
    End If
    If lin >= 12 Then
    CommandButton10.Left = 42
    whichproduct.Height = 340
    End If
    End Sub
    -----------------------------------------------------------------------

Posting Permissions

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



Click Here to Expand Forum to Full Width