Connecting Tech Pros Worldwide Help | Site Map

Datasheets - resizing/reordering cloumns by hand, does not stick

  #1  
Old November 21st, 2008, 05:45 PM
comcraft1966@googlemail.com
Guest
 
Posts: n/a
I have several data sheet sub forms in my application. If I resize or
reorder columns by clicking and dragging, in some forms my actions are
remembered the next time the form is opened, in other forms the form
returns to the defaults.

How can I get the datasheet sub forms to remember the way I sized and
ordered my columns? Is is a form property, or can I code it?

i.e.

Private Sub Form_Unload(Cancel As Integer)
Me.RememberColumnWidthsAndOrder ':O)
End Sub

Paul


  #2  
Old November 21st, 2008, 06:45 PM
Rich P
Guest
 
Posts: n/a

re: Datasheets - resizing/reordering cloumns by hand, does not stick


I don't think there is a column width property in Access for table
columns. But if you click the Save Icon after changing a column width
in your datasheet (subform) - Access should remember that setting. What
you don't have is a way to dynamically change the size of the subform -
via dragging (unless you write a ton of code - not easy). But you could
have a button, for example, where you can change the width of your
subform to accommodate when you need to widen your columns.

dim subFrmWidth as long
'--set the value of subFrmWidth
Private Sub Command1_Click()
Me.frmAsub.Width = subFrmWidth
End Sub


Rich

*** Sent via Developersdex http://www.developersdex.com ***
Closed Thread