Results 1 to 2 of 2
  1. #1
    MatthewGrace is offline Competent Performer
    Windows 8 Access 2010 64bit
    Join Date
    Jan 2013
    Posts
    159

    A report with a textbox that automatically sizes itself to content?

    I'm creating a very simple report in Design view, using only the "Details" section. The height of the entire section is only about 1-2 inches, nice and slender, so I can view many records on a single page easily. There is a textbox small enough to accommodate a single sentence in the aforementioned details view. That size is all that's needed 95% of the time.



    Trouble is, every so often a textbox that houses a full paragraph shows up. Naturally, all but the first sentence gets dropped from the Report, because the textbox control is so small.

    The only way around this problem that I know is to enlarge the "Details" section height and make the textbox much much bigger, eating up tons of screen real estate with blank area.

    Is there a way to make a Textbox control that's small, but increases it's height property automatically if it detects a large chunk of text within it, and more specifically, will that particular row of the report scale automatically to fit these oddball records?

    I imagine this can't be too uncommon of a question, I apologize if it has been answered already. Thank you for any input,
    Matt

  2. #2
    Ruegen's Avatar
    Ruegen is offline VIP
    Windows 8 Access 2010 64bit
    Join Date
    Jul 2013
    Location
    Australia
    Posts
    1,496
    1. You can have it so that when you double click on a text box a fuller box pops (another form with a big text field) in front containing all the text. Have a function that when you close the bigger form it refreshes the other one behind it.

    2. You can also resize the text box - the value inside the text box has characters. If you count the characters you get a length - from this length you could say that anything over >300 make the text box this size. It would have to be a set size because you don't want the size to grow larger than the screen in case there is something like 4000 characters... in the end I wouldn't recommend it.

    to count the characters use the len() function

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 17
    Last Post: 07-15-2014, 06:17 AM
  2. Replies: 2
    Last Post: 05-06-2013, 02:17 AM
  3. TextBox Content
    By myuser in forum Programming
    Replies: 1
    Last Post: 05-16-2012, 03:07 AM
  4. Replies: 5
    Last Post: 01-04-2012, 05:14 PM
  5. Emailing report at the Email content
    By ylivne in forum Reports
    Replies: 0
    Last Post: 07-07-2009, 05:31 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums