473,405 Members | 2,404 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,405 software developers and data experts.

Unable to set Height

Udi
Hi All,
I have a listbox (owner drawn) on a form.
the form is topLevel with no parent.

My problem is that I can't set the Height of neither the from or the
control to the values I want.
after I single step the following lines:

int height = 20;
this.autoCompForm.Height = height + 1;
this.autoCompForm.AutoCompListBox.Height = height;
int i = this.autoCompForm.Height;

** at this point 'i' gets a strange value, not 20 as expected.

I tried docking, it didn't help. the listbox just refuses to fit in
nicely on its form.
(In small heights, ther's always a gap between the listbox and the
form)
Any ideas?

Thanks,
Udi.

Jun 18 '06 #1
2 1671
Udi,

Can you post a project that shows the problem?
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Udi" <Ud**********@gmail.com> wrote in message
news:11*********************@c74g2000cwc.googlegro ups.com...
Hi All,
I have a listbox (owner drawn) on a form.
the form is topLevel with no parent.

My problem is that I can't set the Height of neither the from or the
control to the values I want.
after I single step the following lines:

int height = 20;
this.autoCompForm.Height = height + 1;
this.autoCompForm.AutoCompListBox.Height = height;
int i = this.autoCompForm.Height;

** at this point 'i' gets a strange value, not 20 as expected.

I tried docking, it didn't help. the listbox just refuses to fit in
nicely on its form.
(In small heights, ther's always a gap between the listbox and the
form)
Any ideas?

Thanks,
Udi.

Jun 18 '06 #2
Udi
All,
In my listBox CTOR -

this.IntegralHeight = false;

solved the problem.
Thanks anyway!
Udi.

Jun 18 '06 #3

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

Similar topics

1
by: Arun Nair | last post by:
Hi, I have the following jsp page. I am able to view only a part of it(until the occurence of the first City text box). If i remove the first few fields from the page, I am able to see a few...
6
by: MichaelF | last post by:
I've embedded a RealPlayer window in a page, and am unable to get mouse clicks. The clip plays, but clicks are ignored. I'm running IE5.5 on Win2k, with the following code: <embed...
10
by: soup_or_power | last post by:
The pop up window has several checkboxes. I'm unable to access the checkboxes using the handle from window.open. Any way to do this? var display; function showSugg(but_id, sugg1, sugg2, sugg3,...
1
by: Udi | last post by:
All, I have a list box that imitates the intelisence behavior. Since I need it to be top most, I have put it on a TopMost form (The listBox docked to Fill). The form has no parent, no caption and...
3
by: bhanubalaji | last post by:
hi, I am unable to disable the text(label) in javascript..it's working fine with IE,but i am using MOZILLA.. can any one help regarding this.. What's the wrong with my code? I am...
6
Markus
by: Markus | last post by:
I'm adding to my script a section that allows a thumbnail to be created and saved. I get this error: Warning: imagejpeg() : Unable to open '../uploads/thumb/' for writing: Is a directory in...
0
by: ruchitrivedi19 | last post by:
Hi, I am new to wpf. I am trying to see some animation on browser. browser is IE7. Below is my code, nothing in .cs file <Grid Height="500" Width="500"> <Canvas Height="230" Width="230"...
2
by: =?Utf-8?B?SmR1YW4=?= | last post by:
objImage.Height.Value
1
by: kailashchandra | last post by:
Below is my code.i want the first division should be load when window is loading. <HTML> <HEAD> <script> function tabFunc(getthis) { var getIn=getthis.innerHTML; var...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
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,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
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
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...

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.