Interface And Graphics :: Point Containing Decimal Values

Jul 12, 2011

I'm drawing polygons,lines,etc. and I have to have the points of each precise - up to 12 decimals. Since a Point only takes integer values, I'm not sure how to handle scaling. I have a working user control, but rounding the decimals so I can put them into points is causing incorrect calculations (area, ect.).

View 4 Replies


ADVERTISEMENT

Interface And Graphics :: Drawing A Point On A Particular Picbox

Feb 2, 2012

I have several picture boxes on a form (frmMain).My question is, how do I paint a point on a particular picture box at the location specified by the coordinates of the current mouse position? The snippet below shows defining some canvases and pens. But I'm not sure how to capture the mouse position when the mouse is over a particular picture box and how to paint the actual point at that location.[code]

View 3 Replies

Interface And Graphics :: Point Translation Between Polygons?

Sep 7, 2009

i have 2 polygons: 1 - A rectangle with a certain size defined with 4, 6 points or more (what ever becomes easier). 2 - A non-rectangular polygon (a quadrangular) what i need is that when given a certain point with inside the rectangle, i can translate that same point in the other polygon in the right position.

View 3 Replies

Interface And Graphics :: Drawing A Rectangle Or A Point On A Form?

Jun 8, 2010

I'm just getting started, and it's as simple as that: I need guidance to draw a rectangle or place a dot or a point on Form1, in VB 2008 Express. I knew how in VB6 -- let's build on that.

View 3 Replies

Interface And Graphics :: Rotate A Graphic At A Specific Point?

Dec 9, 2010

I want to rotate a graphic at a point and I used the centerX and centerY to define the center of rotation.
Here is what I wrote:

Dim rotate_mirror as new RotateTransform(CSng(txtbx_rotate_by.text))
rotate_mirror.centerX = 5
rotate_mirror.centery = 55
blk_mirror.RenderTransform = rotate_mirror

blk_mirror is the graphic I want to rotate. Unfortunately, It does not work.

View 6 Replies

Interface And Graphics :: Drawing Objects To Picturebox With Floating Point Numbers?

Jul 17, 2009

If I try to draw a circle by using e.g.

Code:
e.Graphics.DrawEllipse(Pens.Red, 50.133, 100.321, 0.1, 0.1)

I will get an error message. I tried something like

Code:
Public ObjectPoint As PointF
Dim cpoint As New PointF()
cpoint.ObjectPoint = New PointF(startX, startY)
e.Graphics.DrawEllipse(Pens.Blue, cpoint.ObjectPoint, 0.4, 0.4)

but it didn't work for the location and the circle size. How to draw a circle(and rectangle) by using floating point numbers?

View 6 Replies

Point Type (pair Of Values) Using Decimal Or Double?

Apr 24, 2010

Is there such a thing as a type similar to a point, but contains a pair of decimals, or a pair of doubles, rather than integers? I searched the forums and google with no luck. I can't believe this has never come up before, I must have been using the wrong search terms.

View 4 Replies

Interface And Graphics :: How To Obtain Rgb Values For Each Pixel And Converting Them To HSL Value

Nov 1, 2009

I am developing a software that would scan the image in a picturebox and obtain the rgb values of each pixel in the image and convert each rgb values to HSL values. I am using vb 2008 express edition. I am still a student. All I have done is to obtain the image in a file and paste it in the picturebox. Below is my code. I dont really know how to start with the process of obtaining the rgb values of each pixel and converting them to HSL values and averaging the HSL value.[code..]

View 1 Replies

Interface And Graphics :: Handle Varying Currency Values In Maskedtextbox

Mar 4, 2009

I am working on a Windows application written in VB with Visual Studio 2005. I have a number of fields where the user needs to enter currency amounts. I am using a MaskedTextBox with the following currency mask. msktxtAssessedVal.Mask = "$ #######.99"

The problem that I am having is that when the users type in the value, the cursor always starts at the leftmost position and appears to force as many digits as the mask. The typical data values can vary anywhere between 9,999,999.99 and 20,000.00. If the users do NOT have a value that has 7 digits left of the decimal point, they need to move the cursor to the correct position before they start typing in the value. These users are used to quickly typing in their data, then tabbing to the next field so the current behavior is not acceptable. We previously used a ComponentOne MaskedTextbox, however, their controls now are no longer free and the boss will not pay!!!

Does anyone know if there is a way for the maskedtextbox or any text control to detect where the user types the decimal and format the data accordningly?

View 2 Replies

Interface And Graphics :: [VB2010] - Convert Colors Values To Integer?

Mar 31, 2012

can i convert colors values to integer?

View 6 Replies

Interface And Graphics :: E.Graphics.Drawstring Length Overflow Page?

Nov 19, 2010

Im working on a project that needs to print a report of one client.Everything went smooth untill i came across my multiline input text data.When i display it in the PrintPagePreview the text go's outside my page. Even when im printing it only the halve of my text is displayed. I googled and looked everywhere but i can't get a clear fix for it.

[Code]...

View 3 Replies

Interface And Graphics :: Passing Bitmaps & Graphics To Subroutines As Arguments

Jan 22, 2011

I used to program with Visual Basic 6, so I have alot of old programs that I'm updating, plus I'm learning the new VB2008 methods. I'm writing a program that replaces the old "BitBlit" function which is no longer supported by Visual Basic 2008. It involves three picture boxes, one holds the sprite bitmap, a second holds the mask (silhouette) of the sprite bitmap, and a third has a background image.

[Code]...

View 3 Replies

Interface And Graphics :: System.Drawing.Graphics.DrawString On Other Window?

Aug 14, 2009

drawing text on a window which is not the current form's window.I remember doing this in Win32 api with getwindowdc(handle) to obtain a DC for the Window, then textout() on the DC.

View 2 Replies

Interface And Graphics :: Create A User Interface In A Game Such As The Application XFire Using VB?

Jan 12, 2010

how to create a user interface in a game such as the application XFire using Visual Basic?

View 3 Replies

Interface And Graphics :: Use A Graphical User Interface That Contains A Drag And Drop Form?

Oct 19, 2008

I'm working on a design project where I have to use a Graphical User Interface that contains a drag and drop form. It consists of having a window dropped on a wall. Both of them are images to scale. I would like to know what kind of code I would have to use to show the x and y coordinates of one of the points of my window when dragged so when I drop it, I'm dropping in it on the desired coordinate of the wall.

View 2 Replies

Interface And Graphics :: Creating A Class Holding Some Graphics?

Jan 12, 2011

Ok, I want to create a class that will handle a special rectangle graphic.In my form, I want to have two of these special rectangles. So, basically, I need two instances of that class in my form, right?I manage to initialize two, alright. But, how exactly am I supposed tomanage drawing/graphics etc in a class, and the results to be displayed in my form?

View 13 Replies

Interface And Graphics :: Error - Graphics Paths For Designing

Oct 29, 2008

Using graphics paths for designing...but am getting an error when trying to add a shape to : _shapelist.add(createshape())

It says : Value of type 'system.drawing.drawing2d.graphicspath' cannot be converted to '1-dimensional array of system.drawing.drawing2d.graphicspath'

View 2 Replies

Interface And Graphics :: How To Procede With An Interface Design Approach

May 18, 2012

I was wondering if I could elicit some tips on how to procede with an interface design approach.That is. What is a good way to go about establishing a "work area" where one can have multiple "floating forms" in this area.Can you have a form which occupies the entire windows desk top and the other forms "float" in this space? the "floating" forms would need to interact with each other where pressing buttons etc on them would affect other forms on the "workspace") Or what would be a good way to start accomplishing that? Or is there a better way to get the same effect?

View 4 Replies

Interface And Graphics :: Link A Class / Object To An Interface?

Apr 21, 2010

I'm trying to make a .dll that contains a lot of basic functionality that a program can use. Currently i am trying to use interfaces to make a lot of this functionallity independend of the program using it but i hit a snag. The Basic idea is that a programmer will create his own object using the interface discribed in my .DLL file. Then implements those functions as he likes. He can then instanciate a controller (found in the same DLL) and sends his custom object implementing the interface to that Controller. The controller can then be started and will take over all the work. I do not know what type of object is send to the controller and idealy i want to program it in such a fashion that i shouldn't care as long as the object send implements that interface.In code I am trying to achieve the following: (quite simplyfied)

.Dll:
Code:
Public Interface MyInterface '<----Decleration of the interfaceFunction GetData() As Integer
Function SetData(Data As Integer)
end interface

[code]....

this propperly. I know that the second i set the interface adaptor in the Controller VS comes nagging that it can not be converted to a "MyInterface" Class. Obviously i am doing something wrong. I can change the datatype that the controller expects to the "MyController" type but that would completely ruin the whole idea of flexibillity. I am hoping someone sees what i am trying to do and can point out where i made the thinking error.

View 6 Replies

Interface And Graphics :: Picture Of Interface And Get Feedback On Changes For Easier Use?

May 21, 2012

Is this where i would post a picture of my interface and get feedback on changes for easier use? If not is there someplace on this forum or any other forum to do this?

View 1 Replies

Interface And Graphics :: Draw On Tabpage's Graphics?

Jan 19, 2011

So I decided to make my famous tile selector project, but instead of drawing in a form's graphics, do it inside a tabpage.Well, I managed to get it working, but it seems to... flicker.Normally, setting the form's DoubleBuffered property to True would help a lot there, but apparently, the tabpage has no such property.

When I invalidate the tabpage, I draw two images and fill one rectangle.Following past advice, those two images were created before, just once, and are stored in a variable so I don't create them every time I invalidate the tabpage.

View 1 Replies

Interface And Graphics :: Save Graphics As Png With Transparency?

Aug 1, 2010

Ok I have this: This makes a sub called 'graphicspaint' then writes "demo version" to a picturebox1

Code:
Imports System.Drawing
Imports System.Windows.Forms

[code]......

View 8 Replies

Interface And Graphics :: [VB2010] - Some Graphics Effects?

Dec 5, 2011

i whant do my own shadow effect. i can do the shandow. but how can i plus 2 bitmap images(1 above the other)?

View 15 Replies

Get The Second Decimal Point?

Mar 23, 2011

How to get the second decimal point?

View 7 Replies

Add A Decimal Point In Front Of A Value?

Mar 12, 2010

I have a value that shows a integer value between 0-100. For a little math, I need to be able to add a decimal in front of the value. So if the value was 50%, I need it really to be .50%.

View 4 Replies

Allow Only One Decimal Point In A Textbox?

Mar 5, 2009

Here is the code in C# to allow only one decimal point in a textbox:

if textbox5.text.contains(".") && e.keychar="."
{
e.handled=true
}

I have to use it in VB.NET 2003 version, but I can't use the contains property. How can I do this?

View 1 Replies

Decimal Point In Vb Calculator?

Dec 11, 2009

what is the code for decimal point in vb calculator?

View 2 Replies

Disregard A Decimal Point?

Sep 24, 2009

I am trying to move some data from an Excell sheet to an AS/400 file.

I have my app working, in that, the data is getting to the correct table, but the problem I'm having is that one of the columns in the spreadsheet contains numbers ie; 1234.55

I need to get that to the AS/400 as 123455 in a text field.

Currently I am moving the data from one dataset to another as follows.

Dest_DS.Tables(0).Rows(i).Item(0) = Data_DS.Tables(0).Rows(i).Item(0)

I think what I need to do is seperate the whole number from the decimal and then concatenate the values. ?Not sure how to.

Also, some of the values in the spreadsheet may end in a zero such as 1234.50 but only show the 1234.5 so even fnding the decimal and then taking the next two characters won't always be correct.

View 3 Replies

VS 2008 Get Up To Second Decimal Point

Jul 5, 2009

I was wondering how i can get as far as the second point in a Double. I have a double that will contain a number such as 12.98 but when i try to show it in a textbox it shows as 12.98000000000000000 I know this is because its double but im unsure about to to retrive only as far as the .98 and get rid of all the 00000000000000

View 2 Replies

Include Decimal Point To String ?

Jan 17, 2012

How to add decimal point (with two decimal places) to string, without converting string to decimal? For example (Dim str1 as String), regardless str1 has value: 100 , 100.0 , 100.00, or 100.5 , 100.50..I'd like to get the output: 100.00 or 100.50, with two decimal places.

View 3 Replies







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