"Grow" on a Form: is this possible?

Discussion in 'Microsoft Access Form Coding' started by Chris, Jul 18, 2003.

  1. Chris

    Chris Guest

    I have a detail table with a memo field. This table's
    records are presented to the user via a "continuous
    record" subform. I would love it if for each record I
    could automatically "grow" the height of the memo field's
    text box to show all the data within the field (within a
    certain limit just to keep things manageable). Ideally,
    I'd do this for all rows within view but I don't think
    that is possible, so at least I'd "grow" the text box
    based on the record that has focus. Any ideas? I'm sure
    there's some kind of equation to do this (length of string
    factored into width of text box, etc.) but math just isn't
    my strong suit. Any ideas?
     
    Chris, Jul 18, 2003
    #1
    1. Advertisements

  2. Chris wrote:

    >I have a detail table with a memo field. This table's
    >records are presented to the user via a "continuous
    >record" subform. I would love it if for each record I
    >could automatically "grow" the height of the memo field's
    >text box to show all the data within the field (within a
    >certain limit just to keep things manageable). Ideally,
    >I'd do this for all rows within view but I don't think
    >that is possible, so at least I'd "grow" the text box
    >based on the record that has focus. Any ideas? I'm sure
    >there's some kind of equation to do this (length of string
    >factored into width of text box, etc.) but math just isn't
    >my strong suit.


    You can not make different rows on a continuous form display
    different heights.

    I suggest that you use a separate text box in the form's
    header or footer section to display the memo field.
    Alternatively, make the continuous form a subform on an
    (unbound?) main form and use a synchronized text box on the
    main form to display the memo field.

    A quick and dirty technique to display the entire memo field
    is to just tell your users to click in the memo field and
    hit Shift + F2 to pop up the Zoom Box.

    --
    Marsh
    MVP [MS Access]
     
    Marshall Barton, Jul 19, 2003
    #2
    1. Advertisements

  3. Thanks, Marshall. I know that it's a pipe dream to vary the height of a
    text box differently for each record, but as I mentioned, I'd be willing to
    limit this functionality to the record which has focus (upon form_current).
    What would be the equation to factor the length of the string and the width
    of the text box in order to set the minimum text box height that would show
    the entire contents of the text box? I'd resize the control and detail
    section of the form as the user moved into each record. Your other ideas
    are good, but 1) real estate is limited for placing other text boxes/labels
    on the form, and 2) the field zoom key (Shift-F2) is known, but a) the
    pop-up it opens isn't resizeable, and b) all text is selected (and thus
    vulnerable for deletion in edit mode) via this method.

    Chris

    "Marshall Barton" <> wrote in message
    news:...
    > Chris wrote:
    >
    > >I have a detail table with a memo field. This table's
    > >records are presented to the user via a "continuous
    > >record" subform. I would love it if for each record I
    > >could automatically "grow" the height of the memo field's
    > >text box to show all the data within the field (within a
    > >certain limit just to keep things manageable). Ideally,
    > >I'd do this for all rows within view but I don't think
    > >that is possible, so at least I'd "grow" the text box
    > >based on the record that has focus. Any ideas? I'm sure
    > >there's some kind of equation to do this (length of string
    > >factored into width of text box, etc.) but math just isn't
    > >my strong suit.

    >
    > You can not make different rows on a continuous form display
    > different heights.
    >
    > I suggest that you use a separate text box in the form's
    > header or footer section to display the memo field.
    > Alternatively, make the continuous form a subform on an
    > (unbound?) main form and use a synchronized text box on the
    > main form to display the memo field.
    >
    > A quick and dirty technique to display the entire memo field
    > is to just tell your users to click in the memo field and
    > hit Shift + F2 to pop up the Zoom Box.
    >
    > --
    > Marsh
    > MVP [MS Access]
     
    Christopher Caswell, Jul 21, 2003
    #3
  4. Christopher Caswell wrote:

    >Thanks, Marshall. I know that it's a pipe dream to vary the height of a
    >text box differently for each record, but as I mentioned, I'd be willing to
    >limit this functionality to the record which has focus (upon form_current).
    >What would be the equation to factor the length of the string and the width
    >of the text box in order to set the minimum text box height that would show
    >the entire contents of the text box? I'd resize the control and detail
    >section of the form as the user moved into each record. Your other ideas
    >are good, but 1) real estate is limited for placing other text boxes/labels
    >on the form, and 2) the field zoom key (Shift-F2) is known, but a) the
    >pop-up it opens isn't resizeable, and b) all text is selected (and thus
    >vulnerable for deletion in edit mode) via this method.


    Like I said, no can do on a continuous form.

    If you're willing to limit youself to single form style,
    then you can use Stephen Lebans' TextHeightWidth
    function to determine the size that the text box needs to
    be. I believe that he even has an example of a can grow
    text box on a form at www.lebans.com

    --
    Marsh
    MVP [MS Access]
     
    Marshall Barton, Jul 21, 2003
    #4
    1. Advertisements

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Max Smart

    Text Box Can Grow Property?

    Max Smart, Oct 26, 2003, in forum: Microsoft Access Form Coding
    Replies:
    6
    Views:
    1,537
    Adrian Jansen
    Oct 26, 2003
  2. Don

    Can a Text Box Grow From the Bottom-Up Instead of Top Down?

    Don, Oct 28, 2003, in forum: Microsoft Access Form Coding
    Replies:
    2
    Views:
    343
  3. Keith G Hicks

    height of can grow text box

    Keith G Hicks, Aug 20, 2004, in forum: Microsoft Access Form Coding
    Replies:
    2
    Views:
    1,532
    Keith G Hicks
    Aug 20, 2004
  4. Guest

    Can Grow setting on a subform

    Guest, Jan 28, 2005, in forum: Microsoft Access Form Coding
    Replies:
    5
    Views:
    314
    John Vinson
    Jan 29, 2005
  5. Simon Shaw

    Can controls grow with form?

    Simon Shaw, Oct 17, 2005, in forum: Microsoft Access Form Coding
    Replies:
    3
    Views:
    157
    Simon Shaw
    Oct 17, 2005
Loading...

Share This Page