473,397 Members | 2,068 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,397 software developers and data experts.

Transparent Form And Visible Line Drawn.

Hi All,

I am trying to obtain some sort of a "Model" based on horizontal &
vertical lines (like a frame) drawn on a form or on a PictureBox. For
frames configuration purposes, I created a white background image; and
that works fine. But the "Model" will be used to cut off pieces of a
given image with MS Office. I would therefore like that the lines be
appearent on the image to be cut; but the the underlying control be
transparent (so as not to hide the image!).

I looked for a Transparent property on the form but found nothing; and
visible=False makes the lines disappear as well.

Any idea is welcome!

Cheers.

Jun 14 '06 #1
1 1584
Hi, Lucile,

Have you looked at the "SetStyle" method?

I have used the following within the constructor for setting up a
transparent control.

Me.SetStyle(ControlStyles.AllPaintingInWmPaint Or _
ControlStyles.DoubleBuffer Or _
ControlStyles.SupportsTransparentBackColor Or _
ControlStyles.UserPaint, True)
Me.UpdateStyles()
Me.BackColor = Color.Transparent

Hope that helps a bit.

Cheers,
Randy
Lucile wrote:
Hi All,

I am trying to obtain some sort of a "Model" based on horizontal &
vertical lines (like a frame) drawn on a form or on a PictureBox. For
frames configuration purposes, I created a white background image; and
that works fine. But the "Model" will be used to cut off pieces of a
given image with MS Office. I would therefore like that the lines be
appearent on the image to be cut; but the the underlying control be
transparent (so as not to hide the image!).

I looked for a Transparent property on the form but found nothing; and
visible=False makes the lines disappear as well.

Any idea is welcome!

Cheers.

Jun 14 '06 #2

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

Similar topics

4
by: Benny | last post by:
Hello experts, How can i set windows form controls (i.e. button, label, ...etc) to transparent? I tried set the control back colour property to transparent, but it still appear non-transparent....
3
by: Steve Koon | last post by:
Any thoughts on getting this project to work or suggesting another method would be appreciated. Steve ========================================== Project: A Windows Form which acts as a...
4
by: Adam Maltby | last post by:
Hi, I need to do a transparent label but with a difference. I have drawn on my form a custom background using CreateGraphics as I needed an ellipse looking fill in a rectangle - so the actual...
7
by: Martin | last post by:
I'm using the code show below (in VB.Net 2003) to create an image. I want to save this image to a .PNG file such that when I subsequently display it as part of a web page, the background of the...
4
by: tommaso.gastaldi | last post by:
I found useful to use transparent controls like: '---------------------------------------------------------------------------------- Public Class UserControlTransp Inherits...
4
by: Adam Clauss | last post by:
I have a completely user-drawn user control in which I enabled transparency (follownig suggestions at...
3
by: NickP | last post by:
Hi there, I have a usercontrol that inherits from Windows.Forms.Button. In the OnCreateControl method I set the style of the control so that it supports transparent backcolor and set the...
8
by: Brian Ward | last post by:
I am looking for a simple way to set the image transparency in a PictureBox. I have a moving PictureBox containing a graphic image .. moving by incrementing its Left property. The background...
1
by: Kevinst | last post by:
Hello there, I have got a problem and several approaches but none is really staisfying: Lets assume we have a form. On its surface we have got several animations (like a blinking light). This...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
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...
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
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
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,...

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.