473,395 Members | 1,679 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.

Panel with a Raised BorderStyle

Hi,

I was looking for a way to get a Panel with a Raised border style ...
I found the simplest way to do it, so I share it with you :
public class StpPanel:Panel
{
const int WS_EX_DLGMODALFRAME = 0x00000001;

// Provide window style constants to enable control border
protected override CreateParams CreateParams
{
get
{
// Take the default params from the base class
CreateParams p = base.CreateParams;
// Add the extended "3d sunken border" style
p.ExStyle = p.ExStyle | WS_EX_DLGMODALFRAME;
return p;
}//EndGet
}//EndProc CreateParams
}//EndClass StpPanel

A+

Steph.

Nov 17 '05 #1
0 1631

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

Similar topics

1
by: Luc Benninger | last post by:
Hi, I want a panel control on a form appear as raised. But the BorderStyle property just let me choose Fixed3D which adds a sunken 3D border around the panel. How can I get a raised one? Many...
1
by: Kristof Nachtergaele | last post by:
Hi, I'm looking for something, which acts as a container, that I can drop onto my form and which has a size that is bigger than the visible part, the invisible pazrt being scrollable to with...
5
by: Wilfried Mestdagh | last post by:
Hi, I seems not to find how to change borderstyle of a panel so that it is not sunken, but raised. I only find a 3d setting in obejct inspector... Someone knows this ? -- rgds, Wilfried...
3
by: M O J O | last post by:
Hi, I have a panel on my form. I want to detect when the user enters my panel with his mouse and when he leaves my panel. If the user hovers a control inside my panel, I get the mouseleave,...
3
by: Lasse Eskildsen | last post by:
Hi, I have a panel on my form, and I would like to add a shadow around that panel, just like Xp as around the menus etc. I tried drawing it with the lineargradientbrush, but it doesn't look very...
4
by: Aaron Smith | last post by:
I have a panel that I have in the paint event to draw a Raised 3d border around it.. The problem is, if a msgbox is popped up or a tooltip is displayed, it leaves lines on the panel. I've tried...
5
by: Rob T | last post by:
To keep my example simple, let's say I have a windows application form with a panel in it. For this example, I want to draw a single line in the panel, which is larger than the size of the panel. ...
3
by: ShadowLocke | last post by:
This is a weird one. I have a page that has two Panels on it with BorderStyle set to double. In design mode everything looks as it should. When I start the page up or move it to a production server,...
2
by: priyamtheone | last post by:
How can I draw a frame or groupbox or panel whose style effect is 'Raised' (See attachment). In most of the cases when we set the Frame or Panel borderstyle to 3D, the style effect is 'Sunken'....
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?
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
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
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...

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.