Changing Colors Using Tab Key?
Sep 13, 2010
i just want to know about programming in vb.net. it is based on traffic light first i have 3 text boxes. now when i hit the tab key it is supposed to change in green, yellow and then red. i got the change of color but i do not know how to assign the tab key in it.
View 2 Replies
ADVERTISEMENT
Sep 18, 2010
Individually the Draw red and draw white work. The delays work.When in series the only color seen is the last color. Why? [code]
View 5 Replies
Sep 2, 2009
I'm using VS 2005 and I've created an Excel spreadsheet and written a lot of data. I've also modified some of the cell interior colors via commands like this:
objWorksheet.Cells._Default(Bline + 2 + i, 1).Interior.Color = System.Drawing.ColorTranslator.ToOle(System.Drawing.Color.White)
But what I am finding is that the borders are getting wiped out.
[code].....
View 1 Replies
Dec 21, 2009
It's purpose is as follows:It basically is a "check list" for installed program's, and files. I image machines on a daily basis, and me making this application will save me hours, and hours of time.The basics:My program basically has 2 forms. 1st form, will be tabbed with "clients" or, different model of PC's. Each tab will have it's own checklist. I know how to pull external files already, though, that's not my issue.Basically, when I click "check list" button, it searches for an "adobe", and "Labtech" Directory. If it exists, it will throw the result into form2.richtextbox as Adobe is installed, or Adobe is not installed. Also, Checks if the second program directory is there, and then imports the info into form2.richtextbox on a seperate line. My question is, how do I change the color of the text per line?I.e. make Adobe is installed turn GREEN, and Adobe is not installed turn RED ect.
Form2.Show()
Form2.Show()
If Directory.Exists("C:\Program Files\ATI") Then
[code]......
View 3 Replies
Nov 3, 2009
How do you make the word you typed in the Rich Text Box change only the words color? Example:
Example Text
* Hello World
Bye World *
Some more Example text I tried this:
If RichTextBox1.Text = "Hello World" Then
RichTextBox1.ForeColor = Color.Blue
End If
But it changed the WHOLE textbox forecolor to blue. I don't want that, just for the word.
View 14 Replies
Sep 6, 2011
I have a datagridview and there are several columns in it whose datatype is in date format. I want it to where if a person changes the date in a cell which is ALREADY colored, I want that color to change to white as soon as they click off of the cell. [Code]
View 11 Replies
Sep 21, 2010
I'm searching for a way to change the font size of selected text in a RichTextBox (rtf) having different font families (e.g. Arial and MS SansSerif) and font styles (underline, bold...) using the FontDialog, but without changing the families and styles. The following code resets all the font attributes, which is not what I want:
[Code]...
View 5 Replies
Aug 21, 2009
I have another form which shows the colors from the sql server table when i click a button called show . I have arranged 15 buttons as you show me previously When i click a button called show color , the colos in the sql server tables will be shown This is my aim. for example the itm in the combobox is TATA SUMO the colors are totally 7 in the table of database , how all the colors will shown
Private Sub showcolor_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles showcolor.Click
Dim selectsq As String
[code].....
View 1 Replies
Mar 5, 2012
I am trying to check two colors against each other with this Test but it does not appear to work. Can anyone suggest what I am doing wrong. :-
Do While (ptColor = Panel1.BackColor)
lft.X += 1
secPt = PointToScreen(lft)
ptColor = GetColor()
cnt += 1
Loop
When I look at the ARGB values at a breakpoint ,then numerical values of the three component colors are the same but the loop does not get executed. ?
View 3 Replies
Nov 26, 2009
I got hold of this code to give RGB components of a pixel in a
PictureBox(picPic): Code:Dim pnt As Point = New Point(txtXpos.Text, txtYpos.Text) Dim RGBstring As String = ((TryCast(picPic.Image, Bitmap)).GetPixel(pnt.X,
[code]....
View 6 Replies
Oct 2, 2009
Am I just limited to the VB pen colors, e.g color.orange, color.black etc or can I define my own rgb colors? If so, how do I do that?
View 4 Replies
Apr 27, 2009
I'm creating a little program to help my students to understand colour-mixing in Hex for their Web Design course. What I've got so far, is as follows: The user is presented with 3 sliders (one each for R, G and B) and a button. The 3 sliders each go from 0 to 15 - and when the user hits the "Show me!" button, Select Case jobbies translate the 0 to 15 values as seen here:
[Code]...
View 7 Replies
Feb 28, 2010
this is what i need to do: In the right-hand label, invert the colors of the image. Hint: the inverting white should give black and inverting black should give white. Inverting red (255,0,0) gives cyan (0,255,255). visual basic express 2008 this is what i have, what do i need to make changes to in order to accomplish this?
[Code]...
View 1 Replies
May 12, 2010
I have a code like this Dim p as new pen(color.blue)
and i need the pen to have two colors so its like ty dye. It is a drawing program so the pen needs to have two colors.
View 8 Replies
Feb 9, 2011
I am working on a program to generate 50 circles starting with the smallest in the center of the form. The circles do not over lap and the appear to grow outward. Each circle has to be a random color. I have the code that generates what I need but all the circles are the same color. I was thinking about either using an array to hold each circle and color as to not assign the same color to all of them but not sure about putting a graphic in an array. I also think maybe a nested loop of some sort but was unable to figure one out.
Private Sub mainForm_click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Click
Dim penColor As New Pen(Color.FromArgb(Rnd() * 255, Rnd() * 255, Rnd() * 255, Rnd() * 255), 2)
[Code]......
This works to do what I need to get done, I just need each circle to have a random color as it is drawn.
View 2 Replies
Jan 28, 2011
Is there a way to change the border color for buttons created using vb.net?
View 13 Replies
Jun 14, 2011
Beginner question of the day: I have a .txt file that is a series of color names like this-
[Code]...
View 4 Replies
Sep 5, 2011
Is it possible for VB.net to click colors on a screen? and if so, how?
View 10 Replies
Apr 6, 2012
I'm trying to change some colors on a website. The css look like this:
HTML
TD.RED {
font-family: Tahoma,Verdana,Arial,Helvetica;
font-size: 10pt;
[Code].....
View 1 Replies
Jun 6, 2011
Essentially I am searching an array for colors. If there is no input, on button click you get an error. If the color does not exist you get an error. If it exists then it tells you. The latter two events are not happening.
Public Class Form1
Dim count As Integer
Dim Crayola() As String
Private Sub Form1_Load(ByVal sender As System.Object, ByValue As System.EventArgs)
[CODE]...
View 3 Replies
Dec 5, 2011
A while ago I wrote something that was incredibly simple, however it was 3 years ago and I can't for the life of me find where I saved it(upgraded computers twice since then and a few things managed to disapear in the process) I tried for the last few days trying to figure out how I did it and realized that someone may be able to see what I cannot.
[Code]...
View 4 Replies
Aug 20, 2009
I have 15 checkboxes in my vb.net form during runtime some of the checkboxes in control array are set backcolor by the colordialog using the following code
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Dim a As Integer
For a = 1 To 15
[code]....
My question is i want to send the colors filled in the check boxes into the sql server table throug insertsql statement my trial code is as follows but it is wrong
insertsql = "insert into colordetails(model,color)values('" & ComboBox1.Text & "','" & checkarray(a).BackColor & "')"
colordetails in tablename in sql server and model and color are field names in that table?
View 2 Replies
Jan 5, 2010
I'm not sure whether this post should be in the System.Drawing topic, but here goes... I need to create an array of colors to be applied into a Dundas Chart. The chart code is not the issue, but I can't seem to create an array of colours. Here's what I need to be able to do.
[Code]...
View 6 Replies
Oct 25, 2009
I am trying to create an array of colors. approach 2 doesn't work and I do not know why
Code:
'approach 1: works
Dim list As Color() = New Color() {Color.FromArgb(255, 0, 0), Color.FromArgb(0, 255, 0), Color.FromArgb(0, 0, 255)}
Code:
'approach 2: fails.. why?
Dim list() As Color = New Color() {Color.FromArgb(255, 0, 0), Color.FromArgb(0, 255, 0), Color.FromArgb(0, 0, 255)}
If instead I wish to create an array of strings, both approach works, that's weird.
View 2 Replies
Apr 25, 2009
I have an image like this [URL]...So its possible whether the user able to change color of each block ie:A,B,C,D 7 etc.. he has able to fill the color of the box at runtime.. and it has been saved.
View 13 Replies
Feb 16, 2009
Not for pictures, but for text and backgrounds also in the form. Is this possible?
View 1 Replies
Mar 13, 2009
I'm creating a program to generate PDF files in VB.Net.Everything is working fine except that the image is being displayed with a blue background while the image provided doesn't have any.Following are the lines of code being used:
sColor = IIf(mvarEncodeASCII85, ToASCII85(ImgColor),
(System.Text.Encoding.GetEncoding(1252).GetS
[code].....
View 1 Replies
Mar 12, 2010
I'm working on a playlist and would like to have 2 different highlight colors. I'm using the DrawItem Event with the following code..
Private Sub PlaylistBox1_DrawItem(ByVal sender As System.Object, ByVal e As System.Windows.Forms.DrawItemEventArgs) Handles PlaylistBox1.DrawItem
e.DrawBackground()
[Code]....
I want the item above the selected item to be highlighted in red. Basically what I'm looking for is the select item is green"next cue" and the previous item is red meaning it is currently playing.
View 7 Replies
Nov 19, 2011
I know how to have alternate row colors with ListView. But how about with ListBox? I've run a search. I read in some web sites where they say you can't. Is that true? Meanwhile, I've done something like:
For i As Integer = 0 To ListBox1.Items.Count - 1 Step 1
If i Mod 2 = 0 Then
ListBox1. BackColor = Color.FromArgb(150, 250, 255)
Else
ListBox1. BackColor = Color.White
End If
Next i
with ListBox's DrawItem event. And it doesn't work.
View 8 Replies
Jun 9, 2011
how to have multiple colors in a textbox. Is this possible, or must I use a richtextbox?. I would like to keep it simple if possible by setting it up in a standard textbox.
View 2 Replies