Hey all, Im new to Programming and trying to learn some neat things about it.
I was wondering how to change the Form shape in Visual Basic 2008 Express Ed. to the shape of an Image. For example, if i have a .BMP or .JPG or if i make one of a shape. How can I make that Shape be the Shape of the Form?
Thanks for the Help.
Form ReShaping
Started by Genny, Jul 18 2008 12:21 AM
11 replies to this topic
#1
Posted 18 July 2008 - 12:21 AM
|
|
|
#2
Posted 19 July 2008 - 08:24 AM
Is that possible? I would actually like to accomplish the same in C++ and/or Java... Are you on Windows? (Well, probably) Perhaps some API could help us out... I'll check it.
Hey! Check out my new Toyota keyboaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
#3
Posted 19 July 2008 - 08:27 AM
OK. I think you/we should take a look at the following Win32 APIs (Example VB code):
And some links you should check out:
Creating Custom Shapes for Forms in Windows Forms
VB
Create Forms in Any Shape!
How to make a Round Shape Form - .Net Articles & Samples
How to use GDI+ regions on forms for customized shapes by using Visual Basic .NET or Visual Basic 2005
Not all of these approaches are suitable for beginners, but check it out.
SetWindowRgn Lib "user32" (ByVal hWnd As Long, ByVal hRgn As Long, ByVal bRedraw As Boolean) As Long CreatePolygonRgn Lib "gdi32" (ByVal lpPoint As Any, ByVal nCount As Long, ByVal nPolyFillMode As Long) As Long CreateRoundRectRgn Lib "gdi32" (ByVal X1 As Long, ByVal Y1 As Long, ByVal X2 As Long, ByVal Y2 As Long, ByVal X3 As Long, ByVal Y3 As Long) As Long CreateEllipticRgn Lib "gdi32" (ByVal X1 As Long, ByVal Y1 As Long, ByVal X2 As Long, ByVal Y2 As Long) As Long CreateRectRgn Lib "gdi32" (ByVal X1 As Long, ByVal Y1 As Long, ByVal X2 As Long, ByVal Y2 As Long) As Long
And some links you should check out:
Creating Custom Shapes for Forms in Windows Forms
VB
Create Forms in Any Shape!
How to make a Round Shape Form - .Net Articles & Samples
How to use GDI+ regions on forms for customized shapes by using Visual Basic .NET or Visual Basic 2005
Not all of these approaches are suitable for beginners, but check it out.
Edited by marwex89, 19 July 2008 - 08:37 AM.
Hey! Check out my new Toyota keyboaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
#4
Posted 19 July 2008 - 09:14 AM
great , I will use that
#6
Posted 19 July 2008 - 12:23 PM
thanks for all your replyes, i found a tutorial on how to do it and now wen i insert an image the form takes the shape of it. thanks again to all and great links btw!!
- genny
- genny
#7
Posted 19 July 2008 - 02:03 PM
Google's a programmer's best friend... :D
Hey! Check out my new Toyota keyboaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
#8
Posted 22 July 2008 - 03:06 PM
A cheap way of doing it is to make the form transparent and make your image as the background, but not transparent. You can do that all in about 2 minutes with the Properties panel.
#9
Posted 23 July 2008 - 03:51 PM
dargueta said:
A cheap way of doing it is to make the form transparent and make your image as the background, but not transparent. You can do that all in about 2 minutes with the Properties panel.
Ik ^^ I wrote a Tutorial on it heheh
#10
Posted 24 July 2008 - 05:04 AM
#11
Posted 24 July 2008 - 08:09 AM
koduz for me!! :p
#12
Posted 24 July 2008 - 06:52 PM
Goes to show how much I look at the tutorials section.


Sign In
Create Account


Back to top









