Working With Form Tansparancy And BackColor Properties?

May 22, 2009

I am in thinking about building a small app. Its indended to be a screen grabber with a difference.The window form is see through by setting the Transparancy and BG properties to equivalant values. The TopMost property of the form is set to true.The concept is that the form is placed over the area of the screen that you would like to capture. As the form is see-through you can adjust the form around the area you would like to capture.Once you have done that, its just a matter of click a toolbar button eigther save it to file or copy to the clipbaord and placed in an image array.

Tipicaly it should have some of the functioning of a digital camera which at your lesure allows to view images seperatly in the array and deside wether to keep them or delete them.What would be the best control to use as the capture control? ie. The form itself or an Picturebox that is also seethrough?If the image carn't be crabbed that way, then it should be possible to read the coordinates of the PictureBox (top,left,width and heigh) relative to the underlying image on the underlying app. Than once the coordinates are known it should be possible to copy that rectangle of the screen?

View 9 Replies


ADVERTISEMENT

Label And From Its Properties For Backcolor Choose Transparent

Oct 30, 2009

i have a label and from its properties for Backcolor i choose Transparent... However is always the control color why is that? I have a background and i need the label to have the background`s color..

View 6 Replies

Button BackColor Not Working As Expected

Aug 21, 2009

I have a form with a split panel. In the one split are a group of buttons which I want to programmatically change the color of the last pressed button.The following loop seems to run correctly and set the colors correctly but the form doesn't represent that. Once the loop is completed and I recheck the button colors, they revert to previous state.[code]I can get the desired effect by doing the below code but seems less elegant and would obviously require updates as buttons would be added or removed.[code]

View 2 Replies

Treeview Node Backcolor To Black - Hiding Text Not Working

May 31, 2010

In Treeview control, I have made particular node backcolor as black to hide text. But it does not work properly. On click of that particular node, it displays text eventhough when I set BackColor as Black. Is there anyway to hide the text in Scenario also. I don't want to actually remove the text from that node as I have done lot of coding by checking node text.

View 5 Replies

Random Backcolor Of Form?

Oct 10, 2009

Ex : i type in textbox and ma form background always change color i want to know how to write it?

View 2 Replies

Working With Properties In Custom Controls?

Feb 1, 2011

I am trying to learn how to create Windows Forms custom controls in VB.Net by creating a .Net version of an old control I created in VB6. On this control, I have a UserControl with a Label (lblCaption), and several of the properties I add to the control should be passed to the label.This is the code I tried for the ForeColor property:

Code:
Protected mcolForeColor As Color = Color.FromKnownColor(KnownColor.ButtonHighlight)
Public Overrides Property ForeColor() As Color
Get

[code]....

When I change the ForeColor on the control in my test project, lblCaption does change to the color I selected; however, when I run the application, the label changes back to the default (button highlight) color, and the value of the property is also reverted back when I return to the form designer.What would be the proper way to implement the ForeColor property on a custom control?

View 4 Replies

Change BackColor For Part Of Form?

Apr 2, 2011

So im makeing class, where i need to change BackColor for part of form..What i meen is, i need to change forms BackColor, but not for all form, but for, example 20px from top..

View 5 Replies

Change The BackColor For A Form, And Then Add New Buttons?

Feb 17, 2012

When I change the BackColor for a Form, and then add new buttons, they have by default the same BackColor as the Form itself. That does not show on my Windows 7 development computer, but when I use the program on an XP machine, all buttons appear the same color as the form.

I correct this by changing the button's BackColor property to ButtonFace, but it is a pain to do it all the time and some times it gets past me and a wrong color button goes into the application.

Is there a way to change how this works so all buttons are placed with ButtonFace BackColor by default?

View 2 Replies

Clear Or Reset Form BackColor?

Oct 19, 2010

How do I clear/reset the BackColor of a windows application form? For instance, I have a set of radio buttons, each one changes the color of the background form color, when i reset the radio buttons i would also like to reset the color of the form back to it's original state?

View 2 Replies

How To Change Form BackColor To Gradient One

Jan 5, 2009

How can I change a form's backcolor to gradient one. The code (VB.Net) -
e.Graphics.FillRectangle(New Drawing.Drawing2D.LinearGradientBrush(New PointF(Me.Width, 0),
New PointF(Me.Width, Me.Height), Color.FromArgb(0, 58, 140),
Color.FromArgb(0, 215, 255)), New RectangleF(0, 0, Me.Width, Me.Height))
'fade from left to right

This code changes the form's background to a gradient one. It works fine. Now I want this to take place in an MDI form which will be a container for other forms. If I turn option IsContainer = False then it works but otherwise it does now. How can I change backcolor of MDI Form to a gradient one ?

View 4 Replies

Set The Backcolor Of The Form To A Rgb Color Via Script?

May 29, 2009

How do i set the backcolor of the form to a rgb color via script, im making a theme tab, which changes the color, but i want the default color, and i have a custom color that is really close to it, but I dont know how to set to an rgb sadly. or i could use an alternitive by setting the background to the system color control, but I also dont know how to do that.This is what i have so far:

Private
Sub NormalToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles NormalToolStripMenuItem.Click

[code]....

View 2 Replies

VS 2008 - Panels And Their BackColor On Form

Jan 23, 2010

I've created a Form with 1600 Panels. Which are all called Panel (1-1600).
E.g. Panel1, Panel2, Panel500, Panel1000, Panel1600
I want a code so that if you click one of the Panels, the BackColor of the panel you clicked on, turns from Control to Red

I think there is an easier code than just adding this:
Private Sub Panel1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Panel1.Click
If Panel1.BackColor = "Control" Then
Panel1.BackColor = "Red"
Else
Panel1.BackColor = "Control"
End If
End Sub
To every single panel.

View 4 Replies

.net - A Null Refrence Exception While Working With Properties

Feb 15, 2011

Code will run from frmFacility and will shift into UserControl:

Public Class frmFacility
Private primaryBaseDay As Date
Private isClassPrimaryView As Boolean = False

[Code].....

At the line If facilityForm.IsOnPrimaryView Then, I get a NullReferenceException. Do you know the reason?

Also, I cannot create a new instance of the facilityForm, since I need to work with its singleton, although when I add a new instance of frmFacility, the IsOnPrimaryMode is set to false while it should be set to true in the gotoday sub from frmFacility.

View 3 Replies

Settting Up Control Properties In Between Postbacks Is Not Working

Apr 16, 2010

I am settting up control propertis on page load. Like visiblilty of control depending on loaded data. And very simple setting up images to button controls. For page load it works fine but on postback these values are not set back. This is my code. When it's a postback btnSecurityQA image is missing and visibility of all following controls is not set accordingly.

If Not IsPostBack Then
ButtonImage.SetPath(btnSecurityQA, GetLocalResourceObject(btnSecurityQA.ID & "BaseName").ToString())

[Code]....

View 1 Replies

Transparent Form Background Using Me.TransparencyKey = Me.BackColor?

Apr 6, 2012

I can make the background color of the form transparent by using: "Me.TransparencyKey = Me.BackColor"

"Me.BackColor" is set to default "Control", which I think uses 240;240;240 as the color.But using that color as the transparent mask color leaves gaps in controls who are also using that color.By changing the Me.BackColor to a "rare" color this problem is fixed.What problem really is, is that using the "Control" color I get the ability to ALSO interact with whatever is behind my form, which any other custom color does NOT.

Question: Why is this?

Request: I would like to use a custom color as the transparent color but KEEP the ability to interact with whatever is behind the form, how can I make it do that?

View 1 Replies

Custom Control - Combined Properties Partially Working

Aug 15, 2011

Asking for little guidance again... For my custom control, I grouped some properties in some class. Then in the main control code, I use:

[Code]...

View 7 Replies

BackColor Or ForeColor Change - Added A Button On Every Form

Sep 30, 2009

I created 3 Forms (Form1, Form2 and Form3) and I added a button on every form. This is code for Button1 on Form1:

Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Form2.BackColor = Color.Red
Form3.BackColor = Color.Red
Me.Hide()
Form2.Show()
End Sub

Code for Button1 on Form2:

Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Me.Close()
Form3.Show()
End Sub

Code for Button1 on Form3:

Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Me.Close()
Form2.Show()
End Sub

Now, the problem is that when I click on Button1 on Form3 it shows Form2 but the Form2 BackColor is not red, it is default color, A.K.A Control Color. But I specified in Button1 on Form1 that Form2.BackColor is Red. And also if I click on Button1 on Form2 when Form3 shows it, the Form3 BackColor is also default, it is not red.

I know one way to solve it but it is so not-professional. It is that you add on Button1 on Form2 this:

Form3.BackColor = Color.Red

and on Button1 on Form3 this:

Form2.BackColor = Color.Red

It is ok in this situation but what if I have more stuff, for example if I have an option for changing theme so it has to change all labels and buttons ForeColor, what then, is there any other way?

View 8 Replies

Changing Datagrid Rows BackColor On Form Load?

Jun 4, 2011

Well i just tried to turn Rows cells that contain the word Yes into green on form load when i put that code into a button it worked but on a form load i didn't work !

Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Dim j As Integer = 0

[Code]......

View 4 Replies

Change All Properties Of A Form To Properties Of Other But Don't Change Important Properties?

Feb 26, 2011

How to change all properties of a form to properties of other but don't change important properties like Owner,Handle, OwnedForms, Parent,HasChildren,Controls and ... .I have a child form that i want it to provide controls of Form.The background form provides Aero frame and child form is a transparent form in it.I want it because I want to draw buttons with system style in Aero in Windows Forms.This is my own code but it does not work good (ForeForm is child form):

For Each Propertry In ForeForm.GetType.GetProperties()
Select Case Propertry.Name
Case "AeroBackgroundEnabled", "FormBorderStyle", "TransparencyKey", "Parent", "Owner", "ShowInTaskbar", "Handle", "HasChildren", "OwnedFo[code].....

Additionaly:I wrote a great Aero Form.I don't publish current version (1.2) that supports Aero Blur,RealTime Aero Color change,extend Basic theme?

View 13 Replies

VS 2008 Change To Form Backcolor From One Colour To Another With A Time Delay Of 1 Second

Oct 22, 2010

I am trying to change to form backcolor from one colour to another with a time delay of 1 second. I have tried various things without success and this is the best I can come up with:[code]The problem I am getting is the colour is not changing until the loop has finished.

View 3 Replies

Form In A Form - Manipulate The App's Properties Place Inside Child Form?

Dec 23, 2008

The following code does create a form within a form and does place NotePad inside the child form. You have to manually start NotePad prior to execution (I work on that later) but the code does workŠ My problem is now I want to manipulate the properties of notepad i.e. focus, size, location, etc. but I cannot figure out how to reference notepad and its properties.

[Code]...

View 8 Replies

Inheriting Windows Form And Editing The Properties - Customizing The Default Form

Jul 2, 2009

So I was wondering if anyone has done their own Forms (inheriting windows form and editing the properties) and if so, what your finished result was. And, if you are willing to post a screenshot of your finished result, that would be sweet! Trying to get some ideas of what can be accomplished with customizing the default form.

View 1 Replies

VB Form Not Recognized As A Form In Properties - Application Page

May 13, 2011

I want to enable application framework using Form2 as the startup form. The Startup form: combo box lists Form2 when enable application framework is unchecked, but when checked, I get the message that the startup object must be a form, the project then compiles and shows another form as startup. Declarations for Form2 are as follows:

[Code]...

View 6 Replies

Transparent Controls Over Form With Background Image Shows Backcolor Not Image?

Sep 18, 2009

I can't remember exactly if this is possible or not but what I am attempting I would think should theoretically be possible. I know it is possible in WPF but the company I am working for doesn't want to make the transition just yet. Basically what I want is to use a background image on a form for the background and I have a docked control on the right and left. I have set the background on both of these docked controls to transparent however it is showing the back color rather than the background image. I tried, rather than setting the background image property, to override the onpaintbackground and onpaint events and use e.graphics.draw(picture, me.clientrectangle) but it still seems to just pick up the backcolor as the true transparent background so I'm wondering if it's possible to get it to show the background image through the control rather than the backcolor of the form?

View 3 Replies

"SORT" Properties .NET Not Working?

Sep 29, 2009

As new to VB.Net, I am having an issue related to combo box searching functionality. In VB.NET, the multiple character typing searching is not happening in ComboBox when its style is "DropdownList" type. But in VB 6.0 it is working fine if we set "SORT" properties is "True"

I need full typing option activate for the combo box. say for I type India then it shoud select India..not the item starts with a as its the last character.

View 1 Replies

Set Form Properties Before Showing Form?

Jul 27, 2010

I'm trying to figure out how to set the form's location/size before calling the .show method. I figured out the location part, but still can't figure out the size part. No matter what size I set the form to in the designer, it never uses that, so I figured I would set it with code right after setting the location.

'set location before .show
Form2.StartPosition = FormStartPosition.Manual
Form2.Location = New Point(103, 449)

[code].....

View 4 Replies

Forms :: Making Inactive One Form While Working On Another Form

Feb 12, 2010

suppose i have two forms form1 and form2

and i clicked on button which lead me to the form2

i want i shouldn't be able click on form1 untill and unless i close the existing form window(i.e form2)

View 2 Replies

Create Properties Like Form

Dec 3, 2011

I'm new in development in vb.net IDE, and I need your advises on how to create multi form in one screen like a project properties screen in VB2008 IDE, thus when you you go to Menu Project -> Project Properties... you can see that screen is divided into two panes the left one for options to choose and the right one for configuration and preferences.I need to know how to achive this and how to create similar to that thus if you choose any button from left the form content changes at right (ok is this single form and all controls were set to invisible /visible or is it muliform programming. how can I change the Left pane with Treeview control and choose my option from there.

View 10 Replies

Possible To Customize The Properties Of A Form?

Sep 28, 2009

is it possible to customize the properties of a form? for instance, i would like to start a new project, and have my form load center screen, not windows default location from the startup location, among many other options.if this is a possibility, from within vb.net, which i was not able to find and customize, do advise on how to do so.if i have to hack vb.net, i would not know where to start to do so, but how would i begin? what file do i need to modify in the program files folder of vb.net? this, by any means, i would not find it as a hack to destroy someone's work, but to better the software for the user.if a moderator reads this post , do consider my concern for customizing vb.net as vb.net customizes for the users..what i mean, is that, if this option is not available, mods, look into providing an update for vb.net to allow the customizing of the properties for forms/toolbox items and do reply to this thread w/a link.

unless vb 2o10 provides this option, which i doubt, and if it does and there are skins for vb.net 2o1o to change the tab look to the 2oo8 vb.net look, do not advise to look toward the 2o1o version.. personally, the 2o1o tabs are ridiculous, the font in the code window could have been the same as vb.net 2oo8 also.

View 16 Replies

Properties Of Controls On A Form?

Jun 18, 2011

I'm trying to write a routine which will produce a list of the values of some of the properties for every control that I've placed on a form. I can do this manually by looking up the names of each of the controls, but I'd rather use a construct like this -for each formname as string in xxxx

for each ctrlname as string in yyyy(formname)
....
next

next

However, I'm having problems with the various examples of this code that I found in the library. I'm not sure whether it's because I don't know how to set up the syntax correctly or this sort of construct isn't possible in this context.

View 16 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved