473,461 Members | 1,500 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Dialogs/Forms in C# .NET Compact framework

Hello all,

In a program I'm writing for my PocketPC, I have this form to which
I add a variable number of special UserControl-based controls before
displaying it based on the number of items in the file the user has
chosen. The idea is that if the chosen file has more items than can
be show, the form will just scroll up and down.

If my UserControl is less than the client width, or even the exact
same width, when I get to the point where thew combined height of my
controls is greater than the height of the form's client area, the
vertical scrollbar never gets displayed. Never, ever, no matter how
many controls I add.

If my UserControl is wider than the form's client area when added
with form.Controls.Add() and I later resize it down to the proper
width, then the vertical scrollbar does appear. Unfortunately, the
horizontal scrollbar also appears for a moment until the newly added
control is resized down to the client width of the form.

That momentary appearance of the horizontal scrollbar is annoying,
but I cannot figure out how to prevent it.

How do I prevent the horizontal scrollbar from appearing but still
make sure my control will scroll when too many controls are added?

Thanks in advance.
Sep 29 '08 #1
1 2254
On Mon, 29 Sep 2008 11:26:40 -0700, Cory Albrecht
<co**********@hotmail.comwrote:
Hello all,

In a program I'm writing for my PocketPC, I have this form to which
I add a variable number of special UserControl-based controls before
displaying it based on the number of items in the file the user has
chosen. The idea is that if the chosen file has more items than can
be show, the form will just scroll up and down.

[...]
How do I prevent the horizontal scrollbar from appearing but still
make sure my control will scroll when too many controls are added?
A concise-but-complete code example would be helpful here. In particular,
a Form sub-class does not generally by itself display _any_ scrollbars,
even when client controls fall outside the ClientRectangle of the Form.
So your description doesn't really make much sense.

Keep in mind also that this newsgroup is not actually specifically for
Forms topics or Compact Framework questions. You can ask questions on
those topics here if you like, but be aware that the expertise in those
areas may be somewhat limited as compared to that found in more specific
on-topic newsgroups. This is especially true with respect to CF stuff
(for example, if in CF a Form does by default include scrollbars based on
child controls, that's unique to CF and you're unlikely to find here much
in the way of knowledgeable assistance with respect to that behavior).

Pete
Sep 29 '08 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Asad Khan | last post by:
Hi, I have Visual Studio 2002 Enterprise Architecture Edition. I was wondering if anyone has any information on how I can develop applications for .Net Compact Framework using this IDE. I've heard...
4
by: Chuck | last post by:
I have a vs.net compact framework project created in 1.1 The forms are not able to be seen in the designer mode any more. If I go into the .vbdproj project file I see <File RelPath =...
9
by: Andreas | last post by:
Hi! I have two forms, one opening the other. The opener disables itself when it opens the other window, and the other window is suppose to enable the first window again when closed. I tried this...
3
by: Robert W. | last post by:
I'm embarking on a project that will have both a desktop application and a Pocket PC application. It seems logical to have as much code as possible sitting in a shared project, which would be...
4
by: Scott Johnson | last post by:
Hi! Is there a way to "preload" a form using a thread or something else so that my user doesn't have to wait 5 seconds (initializing time) between forms? Some of these forms have tab strips with...
6
by: Brian Henry | last post by:
This is a little off topic, but does anyone know where I can find information on how windows draws forms and dialogs on screen? I know it depends on 2D hardware, and GDI/GDI+. Does anyone know...
5
by: bob | last post by:
Hi Using 2003 - targeting the compact framework (c#), but would like to do most development using the full.net (manually leaving out stuff not in the compact framework). Q. Trying to find a...
1
by: dusiapapa | last post by:
Hi everybody! I've already posted this in the "microsoft.public.dotnet.framework.windowsforms". I have windows forms application containing a lot of MDI (shown with ..Show()) and modal (shown...
1
markmcgookin
by: markmcgookin | last post by:
hi Folks, Just posting this as a solution to be honest (hope this is the right place) I created a form for PPC 2003 using VB.Net compact Framework One of my forms is longer than the screen,...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.