Solved Hide / Show column in datasheet view of subform with button (1 Viewer)

BJF

Registered User.
Local time
Today, 16:09
Joined
Feb 19, 2010
Messages
126
Hello,

I want to hide or show a column on a subform thats in datasheet view by pressing a button on the main form.

Here is the code that I tried so far on the button but neither of the code below are not working.



Forms(frmOpenOrdersByCustomer!fsubOpenOrdersByCustomer).Form.Controls("ShipToCustomer").ColumnHidden = False



Me.fsubOpenOrdersByCustomer.Form!ShipToCustomer.Visible = True
Me.Refresh


Thanks,
BJF
 

arnelgp

..forever waiting... waiting for jellybean!
Local time
Tomorrow, 04:09
Joined
May 7, 2009
Messages
16,881
To Show:

Me!fsubOpenOrdersByCustomer.Form!ShipToCustomer.ColumnHidden = False

To hide:

Me!fsubOpenOrdersByCustomer.Form!ShipToCustomer.ColumnHidden =True
 
  • Like
Reactions: BJF

BJF

Registered User.
Local time
Today, 16:09
Joined
Feb 19, 2010
Messages
126
To Show:

Me!fsubOpenOrdersByCustomer.Form!ShipToCustomer.ColumnHidden = False

To hide:

Me!fsubOpenOrdersByCustomer.Form!ShipToCustomer.ColumnHidden =True
Thank you!
 

Users who are viewing this thread

Top Bottom