By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
464,666 Members | 1,251 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 464,666 IT Pros & Developers. It's quick & easy.

Horizontal Scroll with first field Fixed.

P: n/a
I have created a Search Form that is basically a Popup ContinuousForm
that consists of 15 fields(columns). When the user clicks on a
record(row) the form closes and the selected record displays on my
MainForm.

Because there are 15 fields, they will not all fit on the screen so
the Horizontal Scroll bar is used. the problem is that the first
field ITEMNAME scrolls off the screen and the user loses track of the
record they were focused on.

Is there a way to keep the first field ITEMNAME fixed, and have only
the remaining 14 fields scroll???

Thanks
Greg

May 22 '07 #1
Share this Question
Share on Google+
6 Replies

P: n/a
On 22 May 2007 08:27:41 -0700, "Ap******@gmail.com" <Ap******@gmail.comwrote:
>I have created a Search Form that is basically a Popup ContinuousForm
that consists of 15 fields(columns). When the user clicks on a
record(row) the form closes and the selected record displays on my
MainForm.

Because there are 15 fields, they will not all fit on the screen so
the Horizontal Scroll bar is used. the problem is that the first
field ITEMNAME scrolls off the screen and the user loses track of the
record they were focused on.

Is there a way to keep the first field ITEMNAME fixed, and have only
the remaining 14 fields scroll???

Thanks
Greg
How about having the selected 'record' be two records, ITEMNAME and selected
field

Chuck
May 22 '07 #2

P: n/a
Hi Greg,

You are referring to freezing a pane (Column) like in Excel. That would
require OOP environment, which VBA does not have OOP capabilities. One
workaround would be to use subforms instead of a continuous form. You
could have 2 subforms. The first subform would contain the first field
in your table. The 2nd subform would contain the rest of the fields.
When you scroll the 2nd subform, the first subform remains static. The
only catch would be that the user would have to scroll the first subform
and the 2nd subform to keep them lined up correctly.

In VB.Net(2005) the datagridview (which replaces the subform) has a
Frozen Column property.

If you have conditional formatting, then the subform idea might not work
out. Again, the VB.Net(2005) datagridview supports as much formatting
(conditional and otherwise) as a RichTextBox control

Rich

*** Sent via Developersdex http://www.developersdex.com ***
May 22 '07 #3

P: n/a
Thanks

One poster suggested datasheet mode. I'm not sure if I will lose my
current functionality. I'll have to give it a go.

Greg

May 23 '07 #4

P: n/a
My appologies. I forgot that you can freeze panes/columns in Access
just as well as Excel. Use a subform and select datasheet view in the
properties of the Subform. This will display your data in a table
format within the main form. You can then freeze your desired columns
using the Format Menu/Freeze column selection. You will be prompted if
you want to save that setting so it will persist. There is probably a
way to automate the freezing of the column(s) so you can freeze and
unfreeze columns without going to the Format menu - I believe using the
DoCmd Object.

Again, the only catch would be if you had conditional formatting. I am
pretty sure that the datasheet view does not support formatting.
Rich

*** Sent via Developersdex http://www.developersdex.com ***
May 23 '07 #5

P: n/a
Thanks Rich

As a matter of fact I am using Conditional Formatting to set
background colors
as highlights. Just my luck. I'll experiment!

Greg

May 25 '07 #6

P: n/a
Hey Greg,

For whatever this is worth, I have found/experienced that VB2005
(VB.Net) greatly simplifies complex operations that would otherwise be
considerably more difficult to perform in Access (requiring a lot of API
code or external com objects created in something other than Access -
C++, .Net...) or flat out just not supported in Access. I mention this
to let you know that there are other viable solutions to your problem.

The VB2005 Datagridview control offers considerably more flexibility
than the Acces Subform - supports all forms of conditional formatting.
Or, if you want to stay with the continuous form option - VB2005 has
another object called a currency manager that you bind with the
underlying dataset(s). You can have multiple datasets and keep them
synched using currency managers. Then VB2005 also has another control
called a panel (which I believe they stole from Java) where you can lay
panels on your form and peform different operations on each panel. One
panel can be static while another panel can have scrolling capabilities,
thus achieving the frozen pane/column feature.

Note: Access is great for small (non-enterprise level) jobs because it
integerates a database system (RDBMS) directly with a programming
environment for which there is no easier way to carry out database
programming. This is quite a feat, but it comes at a price - No one can
package every conceivable programming need into one package. Access
comes fairly close, but it can offer only so much flexibility. Once you
exceed that need, it is time to step up to the non integrated
programming environment.

Rich

*** Sent via Developersdex http://www.developersdex.com ***
May 25 '07 #7

This discussion thread is closed

Replies have been disabled for this discussion.