473,395 Members | 1,502 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,395 software developers and data experts.

No border style 2

hi,

sorry about the first message; i accidentally clicked post. anyway, i want
to make a modern looking app like quicktime that has not got that bar at the
top with the title in it and the controlbox. i have put a no border style
property on the form and have replace the control box with a menustrip.

i asked a friend how to make my form moveable and he could only make my form
moveable if you click the form, not the menustrip. how do you make the form
move by clickeing the menustrip?

my second question is how do you resize the window ( i dont mean
maximize/minimize)?

can anyone help me?

--
Alvo von Cossel I of Germany
Nov 17 '05 #1
2 5612
Hello,

To move the form by clicking on the menustrip, have the following code in
the mouse-down event of the menu strip:

MenuStrip1.Capture = false;
Message msg = Message.Create(Handle, WM_NCLBUTTONDOWN, (IntPtr)HT_CAPTION,
IntPtr.Zero);
WndProc(msg);

At the class level, have these declarations:

private readonly int WM_NCLBUTTONDOWN = 0xa1;
private readonly int HT_CAPTION = 0x2;

For the second question, check this one:
http://www.c-sharpcorner.com/winform...ffectSB001.asp (I haven't
tried this though).

HTH

"Alvo von Cossel I" <Al************@discussions.microsoft.com> wrote in
message news:34**********************************@microsof t.com...
hi,

sorry about the first message; i accidentally clicked post. anyway, i want
to make a modern looking app like quicktime that has not got that bar at the
top with the title in it and the controlbox. i have put a no border style
property on the form and have replace the control box with a menustrip.

i asked a friend how to make my form moveable and he could only make my form
moveable if you click the form, not the menustrip. how do you make the form
move by clickeing the menustrip?

my second question is how do you resize the window ( i dont mean
maximize/minimize)?

can anyone help me?

--
Alvo von Cossel I of Germany
Nov 17 '05 #2
hi,

thanks for the tip.
--
Alvo von Cossel I of Germany
"Siva M" wrote:
Hello,

To move the form by clicking on the menustrip, have the following code in
the mouse-down event of the menu strip:

MenuStrip1.Capture = false;
Message msg = Message.Create(Handle, WM_NCLBUTTONDOWN, (IntPtr)HT_CAPTION,
IntPtr.Zero);
WndProc(msg);

At the class level, have these declarations:

private readonly int WM_NCLBUTTONDOWN = 0xa1;
private readonly int HT_CAPTION = 0x2;

For the second question, check this one:
http://www.c-sharpcorner.com/winform...ffectSB001.asp (I haven't
tried this though).

HTH

"Alvo von Cossel I" <Al************@discussions.microsoft.com> wrote in
message news:34**********************************@microsof t.com...
hi,

sorry about the first message; i accidentally clicked post. anyway, i want
to make a modern looking app like quicktime that has not got that bar at the
top with the title in it and the controlbox. i have put a no border style
property on the form and have replace the control box with a menustrip.

i asked a friend how to make my form moveable and he could only make my form
moveable if you click the form, not the menustrip. how do you make the form
move by clickeing the menustrip?

my second question is how do you resize the window ( i dont mean
maximize/minimize)?

can anyone help me?

--
Alvo von Cossel I of Germany

Nov 17 '05 #3

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

Similar topics

0
by: yurps | last post by:
Hello here is my html, if you click the missing image in the first column on the left, the div is shown, when clicked again the div disappears...but the bottom border disappears as well...Is there...
3
by: ireneatngs | last post by:
Hi, I have example html below which contains a couple of hidden divs. However, some of the table borders within these hidden divs are actually displayed when they should not be. In my...
0
by: Claude Schneegans | last post by:
Hi, In the following code: <UL STYLE="border: 2px solid #F00000;"> <LI STYLE="border: 1px solid #00F000;">item 1</LI> <LI STYLE="border: 1px solid #00F000;">item 2</LI> <LI STYLE="border: 1px...
2
by: Jon | last post by:
Hi all, I am trying to create a page that contains a number of div elements, with links on the left side of the page allowing the user to select which div to display. Some of the pages contain...
19
by: Eva | last post by:
Hi, I'm really really really new to javascripts and so i couldn't really comprehend thoroughly on the the previous posts regarding this issue. Anyways, I'm setting up a picture album site....
3
by: effendi | last post by:
Hi Can any tell me what is the javascript equivalent of CSS border? I would like to change the border of my cell when it is set on focus. I have tried onFocus="style.border='3px'" but it is not...
8
by: UJ | last post by:
I have a table with multiple cells and I want to draw a box around the entire table but not around the individual cells. How do I do that? TIA - Jeff.
3
by: Alex Maghen | last post by:
I'd like there to be a border around each row of my data-grid but NOT between the columns. I've tried setting BorderColor="Black" BorderStyle="Solid" BorderWidth="1px"...
1
by: Armin Gajda | last post by:
Hi, I have the following problem: An input field get a border assigned by a style class (e.g. 2px solid red). When the field gets the focus, we set the border to green. element.style.border...
8
by: moondaddy | last post by:
I'm posting code for a user control ( FunctionConnectorSelector) below which has 3 content controls in it. each content control uses a style from a resource dictionary merged into the app.xaml...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
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?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
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...

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.