The exception that is thrown when an arithmetic, casting, or conversion operation in a checked context results in an overflow.
Questions tagged [overflowexception]
78 questions
0
votes
0 answers
OverFlowException Terminates the program. Should It?
In our windows service, an OverFlowException occurs (by a third party dll). However, there is a nice try/catch block available and as I know, this should NOT terminate the program and it is handle-able exception as compared to StackOverFlowException…

Sameers Javed
- 342
- 2
- 5
- 16
0
votes
1 answer
Unable to migrate old project on new computer
I am getting an error when I try to migrate a old project on my new computer. On the old computer the database worked fine. The content of the database is of little importance, thats why I didnt bring the old database to the new computer as a .bak…

AllramEst
- 1,319
- 4
- 23
- 47
0
votes
0 answers
System Overflow Exception in System.Windows.Forms.DataVisualization.dll
I've got problem that makes me crazy - I think that's so easy that I can't even think about what is causing my problems.
I'm sending data (fft of generated acustic wave - frequencies and magnitude) generated by my uC to PC by serialport.
Everything…

Jejh
- 85
- 2
- 12
0
votes
0 answers
OverflowException with Delimon Directory.Exists
I have a really strange error, with Delimon.Io library, I got an OverflowException when I call a Directory.Exists for an existing directory, ie.
Delimon.Win32.IO.Directory.Exists(@"c:\temp")
The error occours only if I issue the call in a specific…

Alkampfer
- 1,359
- 12
- 27
0
votes
1 answer
Get max value on arithmethic overflow
Is there a built-in way to get max value on arithmetic overflow?
Here's what I need:
var val = byte.MaxValue + 1;
//should be rounded down to byte.MaxValue
MyByteProperty = val;
P.S. I know I can do that by wrapping it as a checked expression as…

Shimmy Weitzhandler
- 101,809
- 122
- 424
- 632
0
votes
0 answers
VB.NET Convert.toDouble return a System.OverflowException
I have a problem with a convert.ToDouble and I don't find the answer on the net, stackOverFlow, etc...
I try to convert this string value "7,8" (same pb with another : "4,84232") to double.
Here is my code :
Dim result As Double
Dim Line as…

Jeff
- 59
- 2
- 10
0
votes
2 answers
How can I determine which element is causing an overflow?
I've got this code:
String testData = File.ReadAllText("siteQueryTest.txt");
XDocument xmlDoc = XDocument.Parse(testData);
List sitequeries =
(from sitequery in xmlDoc.Descendants("SiteQuery")
select new SiteQuery
{
Id =…

B. Clay Shannon-B. Crow Raven
- 8,547
- 144
- 472
- 862
0
votes
1 answer
inf not convertible to a float
For some reason after a while my code raises,
OverflowError: cannot convert float infinity to integer.
I can't see any reason why it would do this, there is little use of floats and no use of the inf,
def bugsInCode(begin):
bugs = begin
…

tox123
- 318
- 9
- 21
0
votes
2 answers
Allow Addition Overflow in vb.net
I'm working on a vb.net app that needs to add multiple integers together. The integers are to be unsigned, and 32 bits in length.
It is expected that the integers will be so large that they will overflow when addition takes place. If any…

stormCloud
- 983
- 1
- 9
- 24
0
votes
1 answer
Contract.Ensures for an OverFlowException
I have a simple Method that returns the exponential value from a given number:
public int Exp(int num)
{
return Convert.ToInt32(System.Math.Exp(num));
}
When running Pex I get an OverFlowException in the Summary/Exception field…
0
votes
1 answer
error ";overflow6" when running a VB6 application on Windows 2003 Server
I am running a VB6 application on Windows 2003 Server.
When I am running it, it is giving ;overflow6 error.
Can any one tell me why is so?

hrishi
- 1,531
- 8
- 28
- 43
0
votes
1 answer
Arithmetic operation resulted in an overflow error c#
Hello i'm using c# to build an application to connect to remote mysql server.
Here is the code:
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using…

Ajay
- 61
- 3
- 13
-1
votes
1 answer
Overflow errors converting Python program to VB .NET
How are you?
In order to make the program I am working on more user-friendly and easier to deploy on Windows machines, I am in the process of converting an algorithm from Python (which works wonders) to VB .NET.
In this order:
-> Fetching decimal…

user7831458
- 83
- 1
- 8
-1
votes
3 answers
Should I be able to bit-shift >> a byte array?
I am trying to understand why BigInteger is throwing an overflow exception. I tried to visualize this by converting the BigInteger to a byte[] and iteratively incrementing the shift until I see where the exception occurs.
Should I be able to…

makerofthings7
- 60,103
- 53
- 215
- 448
-2
votes
1 answer
Overflow exception during sum of all the values of integer array in C#
Hi I was solving a very basic problem on Hackerrank about determining Mini-Max Sum of all the values in an integer array. Basically given an array of 5 values like [1, 2, 3, 4, 5], the minimum sum will be 1+2+3+4 = 10 and maximum sum will be 2+3+4+5…

Naphstor
- 2,356
- 7
- 35
- 53