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
ADVERTISEMENT
Nov 22, 2009
how to get 1.83333333333... to 1.83?
Dim temp_1 As String
temp_1 = 5.50 / 3
Label1.Text = String.Format(temp_1, "{0.00}")
View 4 Replies
Mar 14, 2012
I'm having some trouble converting a double to a string.I have a double value, like 43.64 and I need a string like this: "43.64"If I try to convert the double to a string I always get "43,64" what doesn't work for me..
View 5 Replies
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
Jan 1, 2012
here is a very important matter to be corrected as soon as possible. generally,type double can display an answer correct to more than 20 decimal places. yes,it works fine until here except for exponential system. whenever i try to find a decimal raised to the power of a proper fraction, i get a correct answer but only upto 13 decimal places. that is not fair at all! it is important to get as high precision as possible. consider this example:-
[code...]
i want that number of correct decimal places or approximation,which a windows 7 calculator has. i believe that this is someway easy to get rid of. please support.it is important for programs like calculator,worksheets,databases,etc.
View 12 Replies
Jul 2, 2009
In the discussion in this thread: [URL] it was reveiled to me that vb.net, using double, could only calculate values up to 18 digits after decimal.... so I started thinking and came up with this class
Public Class LargeNumber
Private pNumber As String
Public Sub New()
[CODE].............
I want to split the string into a series of doubles.... and than combine them into a large number.... The size of each double component should be 18 digits on a 32 bit computer... so that I will have room to add the last carrier...
View 3 Replies
Aug 11, 2009
how to add multiple text to a point pair list in Zedgraph. Add text to one point pair can be done like this:
Dim myPane As GraphPane = zg1.GraphPane
Dim TextObj As New ZedGraph.TextObj("High", 10, 10, CoordType.AxisXYScale, AlignH.Center, AlignV.Center)
[Code]....
Theres a problem with the code above when the graph scrolls the text is following as it should, but it's also visible in the pane background.
View 2 Replies
Mar 16, 2010
Whenever I store values to a double-type variable, and ask to display it on the screen, there seems to always be a discrepancy, for example, I entered 7.416 to a textbox and assigned it to a double. When i ask for it to be displayed, it used to be that the 7.416 is returned to me. But just a few days ago, when I debugged my program again, it returns numbers like 7.4159987.......[code]....
View 7 Replies
Aug 15, 2011
For greater accuracy I should use a Decimal instead of a Double ( so I've been told ). Why then have Microsoft chosen to use DOUBLE for most of the functions that return a floating point value in the Math Class?
[Code]....
View 9 Replies
Mar 30, 2011
If I have the code:Dim x as Decimal = 100.0m
Is it casting from a double to a decimal implicitly. How would I do this explicitly in vb.net?
View 2 Replies
Apr 11, 2010
How to find a matching pair of values in two different arrays? Here's the scenario:
Index Array1 Array2
0 1 3
1 2 5
[code].....
View 2 Replies
Mar 23, 2011
How to get the second decimal point?
View 7 Replies
Sep 4, 2009
I have an Excel application, that is converting values of type "double" from one to another. I have the same data as Excel in SQL 2005.I have procedure, that is making all calculation apart rounding. In Excel I have specific format result of this calculation - "_-* # ##0,00_-;-* # ##0,00_-;_-* "-"??_-;_-@_-".How to implement it in VB.NET or C#?
View 2 Replies
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
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
Dec 11, 2009
what is the code for decimal point in vb calculator?
View 2 Replies
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
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
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
Sep 18, 2009
validation for , allow only 2 digit after decimal point in TextBox in vb.net eg 150.25
View 3 Replies
Jan 11, 2012
Basically in my in my aspx page I have a gridview which displays the value from my database as an image. So if a value in my database table is 5, it will be displayed as 5 images in the gridview. ie.(star.jpg star.jpg star.jpg star.jpg star.jpg)The code:
Protected Function getrating(ByVal rate As Integer)
Dim getrating As String
getrating = ""
[code].....
View 3 Replies
May 18, 2012
Way to find out the numbers after the decimal point of the double?All i need to do is to find out if the number ends in 0 like 1.0 or 10.0 or 323.0 ?
View 6 Replies
Aug 11, 2009
For some time I try to get the comma instead of the decimal point, but the labels I use won't display a comma. For some reason I don't understand, the msgbox() does the trick, but is useless in my application. This is my last desperate piece of code I tried but it also failed.
Expresserprijs = EuropluscolNL(ArrayCol, 2) - EuropluscolNL(ArrayCol, 1)
' All above are "Doubles" and are fed with data like 21,45 (with comma's that is)
Decimaalteken = Expresserprijs
' Decimaalteken is a string
MsgBox(Decimaalteken)
[Code] .....
View 2 Replies
Aug 1, 2009
I'm making a sciene program so I want to draw the graphic with decimal size and location. But the parameters are always integer, not decimal or double. Can I do that?What is big but light?
View 3 Replies
Feb 23, 2012
I am trying to think of a possible way to insert a colon and decimal point to a part of a number. I am making a Rubik's Cube timer, and I converted the times to milliseconds so I can calculate the average of 5 with that. I averaged the milliseconds, but now I need to convert that into minutes, seconds, and milliseconds. Does anyone have any idea on how I would go about this?
View 2 Replies
Jun 17, 2011
I have a problem which is that Class Big integer Doing a miscalculation
For example: -
5 / 2 = 2.5
With Class
5 / 2 = 2
I want to do to show the numbers after the decimal point (.5)
View 8 Replies
Aug 20, 2010
I have read about Round() and MidpointRounding.ToEven but I still could not figure how to use it to achieve what I want. I have numbers (usually from 5 digit decimal) such 125.36 , 125.10, 125.99. I want to make the 2 decimal point rounded to the nearest 20. Means, the 2 decimal point should be either .00 or .20 or 0.40 or .60 or 0.80 only.
125.36 should be 125.40 : 125.10 should be 125.00, 125.99 should be 126.00
125.54 should be 125.60 and so on
Is there math function to make or I should parse the number as text and test the last 2 digit?
View 2 Replies
Feb 20, 2012
I got this class from another vb help forum and I'm using it for fields that accepts monetary values. Is there a way to incorporate a '1-decimal' point only rule?ATM, I can enter values like this: 1.2.2.20000..I need to limit the number of decimal points used. (1.0000)[code]
View 7 Replies
Dec 15, 2010
This is my code: I need to display the decimal point correctly when the counter gets above ten pence and when it gets to a pound.
[Code]...
View 2 Replies
Jun 28, 2009
I want to specify the user to enter only the numbers and decimal point in the text box.[code]values something like that which contain only numbers and dot.This is the code to enter the numbers only.[code]How to make the code to accept dot also?
View 5 Replies