Results 1 to 5 of 5
  1. #1
    rgrstvr is offline Novice
    Windows XP Access 2007
    Join Date
    Jan 2010
    Posts
    25

    How to easily and quickly change width of columns?


    I have a file with 45 columns and I need to be able to make 40 columns quickly dis-appear and re-appear. When I search for responses to similar questions I get references to "Horizontal scroll bar and List Box control" which I do not know how to find and/or use.

  2. #2
    Bob Fitz's Avatar
    Bob Fitz is offline Access Developer
    Windows 7 32bit Access 2003
    Join Date
    May 2011
    Location
    Essex UK
    Posts
    3,614
    I have a file with 45 columns and I need to be able to make 40 columns quickly dis-appear and re-appear.
    W
    Are these columns being shown in datasheet form.
    If this helped, please click the star at the bottom left of this posting and add to my reputation . Many thanks.
    Bob Fitzpatrick

  3. #3
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,770
    Code behind form can hide controls. This is fairly simple. Can use a Toggle control click event.

    Me.textboxname.Visible = Me.togglecontrolname


    In Datasheet view, column widths can be changed. http://msdn.microsoft.com/en-us/libr...ffice.11).aspx

    Me.textboxname.ColumnWidth = -2
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  4. #4
    rgrstvr is offline Novice
    Windows XP Access 2007
    Join Date
    Jan 2010
    Posts
    25
    I am in Datasheet view. I followed the instructions in http://msdn.microsoft.com/en-us/libr...ffice.11).aspx. The only format menu I can find is under the Fields tab and nothing responds to my clicks on the various items in that format menu.

  5. #5
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,770
    The link was for Access 2003. Access 2007 has ribbon, not menu bar. I see nothing on ribbon to change column display width or hide columns.

    However, the VBA code is the same. Not sure how you want to execute the code. Buttons do not show on forms in datasheet view.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

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

Similar Threads

  1. Replies: 5
    Last Post: 10-28-2013, 10:04 PM
  2. Change width of subform in code
    By GraeagleBill in forum Programming
    Replies: 2
    Last Post: 12-02-2012, 04:57 PM
  3. Replies: 3
    Last Post: 06-24-2012, 02:19 PM
  4. Combo Box dropdown to size width of columns
    By noweyout in forum Forms
    Replies: 1
    Last Post: 02-18-2011, 05:56 AM
  5. The section width is greater than the page width?
    By Gary_Marshall in forum Reports
    Replies: 2
    Last Post: 11-13-2009, 01:54 PM

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