LinearGradientBrush With Degree Direction?
Jun 1, 2012I want to paint the background of a form with gradient using the LinearGradientBrush; but I have troubles using degrees.Basically, I want using linear gradient in diagonal.
View 1 RepliesI want to paint the background of a form with gradient using the LinearGradientBrush; but I have troubles using degrees.Basically, I want using linear gradient in diagonal.
View 1 Repliesknow that the LinearGradientBrush in system.drawing supports two color gradient,but can I put 3 or 4 color gradient in a single brush?can I do that:dim b as newlineargradientbrush(newtangle(0,0,100,100),color.black,color.white)b.InterpolationColors.Colors = New Color() {Color.AliceBlue, Color.AntiqueWhite, Color.Aqua, Color.Aquamarine, Color.Azure}
View 1 RepliesAnyone played with LinearGradientBrush? I'm using it to plot some chunky text with a gradient fill on a picturebox . Say I want the text to be full yellow at the top (255,255,0) and full red at the bottom (255,0,0). What I get is a light orange shade at the top of the letters and a dark orange at the bottom. I never get the full range of shades. I would prefer to have say 10% at the top of each letter plotted with the full starting colour, then the gradient, followed by the bottom 10% plotted with the ending colour. I hope that makes sense. Obviously I'm using MeasureString to get the height of the text and I've played with making that value larger and smaller but it didn't seem to help.I have seen references to SetBlend Triangular Shape and WrapMode which look interesting, but no examples of how these would produce the effect I'm looking for.
View 7 RepliesCan anyone explain why the effect of a LinearGradientBrush does not always seem symmetrical?To see what I mean with the following code where point1 is halfway down the left side of the form,point2 is halfway down the right hand side.Using the colors Blue and Green the transition appears mainly nearer 3 quarters of the way across the FORM for the BLUE changing to GREEN.
View 9 Replies- how to convert degree to radian
-how to use a function sqrt
-how to use a funtion pow
-how to use a function sinus
how to rotate a label 45 degree's ? The label is in a group box.I'm using vb.net 2005
View 10 RepliesI am capturing images from a webcam and I have to compare the degree of similarity between two or more images. that is... which two images are the closest match.
I know I cannot compare the pixels...so how do i go about it?
I am using Visual basic 2010 on Win7
This comparison need to be sufficiently fast. Within 2-3 seconds.
I was looking into pixel by pixel comparison. but webcam pictures as I understand do have slight changes between frames(disturbances).
I am working on recognizing hand gestures...which would in turn control a small mechanical crane...
for example a thumbs-up sign would mean a signal for crane to be switched on...and a full palm shown would mean a stop your work sign.
I plan wearing a white glove against a black background.
I also have ideas like dividing the screen into a 10x10 matrix.
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
[Code]...
Just curious ... for those whose main occupation is as a software developer what percentage of you had computer science degree vs. self taught?
View 2 RepliesIs anybody good with math?
CODE:
I'm not sure if this is the right thread for this.
i have a decimal number like 35,23456834 the rapresent a latitude or longitude (in degree but with decimal form for the decimal )
My need is to transform that number in xx° - xx' - xx'' in a variabli of string
I dont even know if you can do this in vb.net but, how do you change the pictureboxes x2 y2 to tilt some degrees other than 90 degree angles?
View 2 Repliesim searching for code examps on how to search multi-websites from user input within a desktop apps textbox and return active links into a webbrowser within the app...this even possible?
View 4 RepliesIs that possible to change the RowHeaders in DGV from right to left. not by change the Direction of DGV from right to left means start from the last column not from the first colum.
View 2 RepliesAnyway this is my code right now so I am not blank.Code removed.Not sure if it is very hard to understand but I am currently working on a project and what this code does is finds a blue ball on thewhole screen then moves the cursor position on the blue ball it just found.If it doesn't find it, will show a msgbox Quite simple.
View 12 RepliesI'm using SelectionMode as Extended (multi select) with WPF DataGrid.The SelectedIndex value always returns the first row that was selected, irrespective of the selection direction. For example, if I start at index 0 and end at 4, I can work with it fine. But if I start from 4 and go to 0, SelectedIndex returns 4 and I don't have a clue to add the number of selected cells or subtract.Is there a way to find the selection direction?
View 1 Repliesi've found this code on the web that allow me to draw a rectangle and keep the Image inside this. But there is a way to make draw this rectangle in all the direction and not only from left to right and top to bottom?
Public Class frmSS
Private Declare Auto Function BitBlt Lib "gdi32.dll" ( _
ByVal hdcDest As IntPtr, _
[code]......
of a tcp server/client project example so that I can make my won tcp chat or something.
View 2 RepliesI have a project that needs to open a CSV file that is 3.7gb in size. It is data that was exported from a database (why on earth anyone would export it to ONE file, is beyond me)
Excel/Access can't open the file because it is more than 256 columns and greater than 65000+ rows. I was able to split the file into seperate files with 50,000 rows in each. I wan't to automate this and export only data by a specific state, and perhaps add it to a database or excel file, should the rows stay below the limit.
I found a project that splits the CSV file... perhaps I can just parse the data while splitting the file.
Here is what I have: An excel sheet full of Companies, Contacts, and emails.
There are duplicates of all three. Here is what I need to do: Strip out all duplicates based on email.
Is there anyone that can point me in the right direction?
my question is regarding working out the direction of the smallest angle between two vectors in 2D. I am making a game in C++ where one of the obstacles is a heat seeking missile launcher. I have it working by calculating the vector between the target and bullet, normalising the vector and then multiplying it by its speed. However, I am now coming back to this class to make it better. Instead of instantly locking onto the player I want it to only do so only when the bullets vector is within a certain angle (the angle between the bullets vector and the vector bulletloc->target). Otherwise I want it to slowly pan towards the target by a degrees thus giving the player enough space to avoid it. I have done all this (in a vb.net project so i could simplify the problem, work it out then re write in in C++). However the bullet always rotates clockwise towards the target even if the quickest route would be counter clockwise. So the problem is working out the direction to apply the rotation in so the smallest angle is covered. Here is my code so you can try and see what I am describing:
Function Rotate(ByVal a As Double, ByVal tp As Point, ByVal cp As Point, ByVal cv As Point)
'params a = angle, tp = target point, cp = current point, cv = current vector of bullet'
[Code]...
I had was to work out the bearing of the two vectors and if the difference is greater than 180 degrees, rotate clockwise otherwise rotate counter clockwise
I used e.Graphics.DrawString(String,Font, X,Y) The point of the X start from the left
X----------String-------------------end of X[/b]
My question can I make the X Starting point from the Right.
X--------------------String-----------Start of X[/b]
I know how to set sorting direction on each column in datagrid programatically, but I wonder how to do the opposite: obtain the sorting direction for a particular column.
View 1 RepliesI was wondering if there was a way to get the marquee of a progress bar to change direction when the marquee gets to the end of the progress bar and vice versahere is a small diagram to show you what i mean[---][*--][-*-][--*][-*-][*--][---] = progress bar* = marquee
View 1 Replieswas wondering if you could give me a hand and point me in right direction with the project i am creating. It is a toolkit They are 2 problems that i am having wondering if anybody knew the issues
1. The textbox is not having them 1 by 1 for example
service pack 2
service pack 3
2. The other problem is a bit more tricky, I have software on the hard-drive c:directorysp2
it has to be implemented into the toolkit anybody have any ideas how without a database if possible. I thought this could be done in the load form, pre-loads the software and then checks when comes to installing the software in the list.
[Code]...
My character moves with the keyboard arrows but he keeps facing the screen, my question is:How can i make the character change direction (by using different sprite positions), like when I press the right keyboard arrow my character faces right and when I walk right my character's legs move?
View 1 RepliesHow do I achieve the below rounding?
0.012608376 > 0.015
2.1 > 2.5
2.4 > 2.5
[code].....
I draw button vertically now i wanna set button text direction in vertically but there is no option.Is that possible ?
View 3 RepliesTotal noobie when it comes to VB, but I'm jumping in. I have about 15 years with Business Basic and see many similar things between VB and BBx so hopefully the learning curve will not be to steep.
Anyway the project I wish to complete is: Use portable computers running Windows CE 5.0 to scan bar coded labels to capture data collected during a physical inventory. The labels have 2 fields - bin location and item. My form will have a textbox for 3 items - bin location, item and quantity. Also, the form will have 2 radio buttons to accept or reject entry. I plan on writing the records to a simple text file to import in to the current application I am running.
I downloaded Microsoft Visual Basic Express 2008 and have done a little prodding around so far. I know the Express version does not support mobile device application development so that needs to be upgraded. My question is, can someone recommend a good book that would cover the areas I need to be concerned with?
Also, any good online resources?
Trying to create a custom button to reside on the desktop at:
Me.Height = PictureBox1.Height
Me.Width = PictureBox1.Width
Me.Top = My.Computer.Screen.WorkingArea.Height - Me.Height
Me.Left = My.Computer.Screen.WorkingArea.Width - Me.Width
The trouble is all the arrows point to right, and the menus open variably depending on size.
Is there anyway to make the arrows point left and make all menus open to left in same direction?
Also, Is it possible to make the width of my form autoresize to the size of a label and the image box, while keeping the imagebox at the bottom right of the screen showing the populated label to the left?