Scrollbars

Apr 17, 2005

I have a form, which has a subform on it. Normally, the subform has only one record in it, however, it may have more. What i want to do is that if the number of records on the subform is 2 or more, then i would like to have the vertical scrollbar visible, else i would like to have it hidden. I have tried the following code, but it did not work. Any ideas about it pls ?

Private Sub Form_Current()
If Me.sfrmSongsSingers.Form.RecordsetClone.RecordCoun t > 1 Then
Me.sfrmSongsSingers.Form.ScrollBars = True
Else
Me.sfrmSongsSingers.Form.ScrollBars = False
End If
End Sub

Thanks

View Replies


ADVERTISEMENT

Scrollbars Propert Problem

Jul 16, 2007

I have made it before but I dont know why it doesnt work this time:

I have a main form called:[LeavesEditorMain]
It contains subform called:[LeavesEditorTmp]

I want to programmatically set the [LeavesEditorTmp] scrollbars property to 0 (Neither) or 2 (Vertical) according to the value of number of records ot a tables called LeavesTmp. I wrote the code as follow in the On Load event of the [LeavesEditorMain] form

if dcount("*","[LeavesTmp]")>6 then
[Forms]![LeavesEditorMain]![LeavesEditorTmp].Scrollbars=2
else
[Forms]![LeavesEditorMain]![LeavesEditorTmp].Scrollbars=0
endif

the error I got is: the property or method is not supported by this object!

View 2 Replies View Related

Forms :: Allow Horizontal And Vertical Scrollbars But Remove White Space (AC2007)

May 22, 2014

I have a form which I would like to enable scrollbars both horizontally and vertically (the main reason being, the application is designed for users with large / wide screens but may at some point be required on smaller screens)

Currently I have the scrollbars switched off and the form maximises but everything goes to pot if I resize the window. I'd like to add the scrollbars so if a user wants to resize the window to, say, half the screen, they can still scroll across to the 'hidden' parts of the form.

The problem with this is, if the form is maximised - or at least large enough to show the entire form - the area of the screen where the horizontal scrollbar resides is white (whereas the background colour of the form is a pale green) Which is quite unsightly.

I know I can remove the problem by removing the horizontal scrollbar and the navigation bar (which is already gone!) but then I can't scroll?

Is it possible to have a horizontal scrollbar but not have that white space at the bottom when the scrollbar is not required?

(Doesn't appear to be a problem with the vertical scrollbar?...)

View 8 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved