Hi
I'm new to C#, and have just started to make a aspx-program.
The program runs fine until i try to include a two-dimensional array:
int[,] myArray = new int[,] {{1,2}, {3,4}, {5,6}, {7,8}};
The code compiles with no problems, but the program crashes immediately with
the error message:
"An unhandled exception of type 'System.Executi onEngineExcepti on' occurred
in mscorlib.dll"
Can someone tell me what the problem is?
Thanks
Einar Værnes 2 8331
Einar Værnes <ei**********@s intef.no> wrote: I'm new to C#, and have just started to make a aspx-program. The program runs fine until i try to include a two-dimensional array: int[,] myArray = new int[,] {{1,2}, {3,4}, {5,6}, {7,8}}; The code compiles with no problems, but the program crashes immediately with the error message: "An unhandled exception of type 'System.Executi onEngineExcepti on' occurred in mscorlib.dll"
That sounds very odd. Does this happen with a tiny program such as:
using System;
class Test
{
static void Main()
{
int[,] myArray = new int[,] {{1,2}, {3,4}, {5,6}, {7,8}};
foreach (int i in myArray)
{
Console.WriteLi ne (i);
}
}
}
(The above works on my box.)
--
Jon Skeet - <sk***@pobox.co m> http://www.pobox.com/~skeet
If replying to the group, please do not mail me too
Thanks for your answer.
The problem disappeared when I rebuilt the whole solution.
Regards
Einar
"Jon Skeet [C# MVP]" <sk***@pobox.co m> wrote in message
news:MP******** *************** *@msnews.micros oft.com...
Einar Værnes <ei**********@s intef.no> wrote: I'm new to C#, and have just started to make a aspx-program.
The program runs fine until i try to include a two-dimensional array: int[,] myArray = new int[,] {{1,2}, {3,4}, {5,6}, {7,8}}; The code compiles with no problems, but the program crashes immediately
with the error message:
"An unhandled exception of type 'System.Executi onEngineExcepti on' occurred in mscorlib.dll"
That sounds very odd. Does this happen with a tiny program such as:
using System;
class Test
{
static void Main()
{
int[,] myArray = new int[,] {{1,2}, {3,4}, {5,6}, {7,8}};
foreach (int i in myArray)
{
Console.WriteLi ne (i);
}
}
}
(The above works on my box.)
--
Jon Skeet - <sk***@pobox.co m> http://www.pobox.com/~skeet
If replying to the group, please do not mail me too This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Rafael |
last post by:
Hi, I hope I can find some help for this problem
IDE: Visual Studio.NET 2003 Developer Editio
Language: C#
Problem: "An unhandled exception of type 'System.NullReferenceException' occurred in system.windows.forms.dll. Additional information: Object reference not set to an instance of an object.
Visual Studio's IDE is not allowing me to develop projects in C#... I've trying to create a simple Windows Forms project using Visual Studio.NET...
|
by: Professor Frink |
last post by:
First off, I apologize if this gets long. I'm simply trying to give you all
enough information to help me out. I'm writing (almost finished, actually),
my first VB.Net application. It's a forms application that is going to be
used to extract data from a legacy system (VSAM based mainframe file
structure), and output data in pipe-delimited record layouts, multiple record
types per file, one file per chosen client. I have been working on...
|
by: Ray5531 |
last post by:
I have .netframework 1.1 and IIS 5.1 installed on my Windows xp.When I try
to run my applicatin either from Internet Explorer or from VS 2003,A
just-in-time debugger instance pops up and says that :
"An unhandled exception ('System.ExecutionEngineException') occured in
aspnet_wp.exe.I unistalled IIS
and Frameworka nd installed IIS and ?Framework respectively and also
registered ASp.NET using aspnet_tegiis ,but still get this error.
...
|
by: Craig831 |
last post by:
First off, I apologize if this gets long. I'm simply trying to give you all
enough information to help me out. I'm writing (almost finished, actually),
my first VB.Net application. It's a forms application that is going to be
used to extract data from a legacy system (VSAM based mainframe file
structure), and output data in pipe-delimited record layouts, multiple record
types per file, one file per chosen client. I have been working on...
|
by: Lucvdv |
last post by:
Can someone explain why this code pops up a messagebox saying the
ThreadAbortException wasn't handled?
The first exception is reported only in the debug pane, as expected.
The second (caused by thread.Abort()) is reported twice: once in the debug
window, and once through the message box.
Is it because the thread was sleeping when the exception occurred?
| |
by: Samuel R. Neff |
last post by:
When you have an unhandled exception in vb.net how do you view the
exception information in the debugger?
In C# the debugger creates a local variable that points to the
exception and you can view it in one of the windows (autos or locals,
don't remember which). That doesn't appear to be the case with
vb.net.
I also tried using the command window to inspect "Err" but that gave
nothing useful (always empty).
|
by: Colmeister |
last post by:
I recently read Jason Clark's excellent article on Unhandled Exceptions
(http://msdn.microsoft.com/msdnmag/issues/04/06/NET/default.aspx) and have
attempted to incorporate the features he talks about in a new application I'm
writing. However, when I try to use ThreadStart to do some work in a separate
thread from my GUI, the methods Jason described don't seem to catch the
exception. Take the following source code:
Public Class...
|
by: NormD |
last post by:
An exception 'System.ExecutionEngineException' has occurred in servername
I have deployed a windows application on a server; I'm running the same on
my pc using http://servername/myApps/myApp.exe. myApp.exe contains some third
party controls used to display data in a grid and to print a preview of the
data. I am getting the above listed error when I attempt to preview/print a
DevExpress GridControl using the DevExpress printing control. A...
|
by: Stephen Flynn |
last post by:
If I run my program on another machine I get the following error
An unhandled exception of type 'System.ExecutionEngineException' occurred in
System.Data.dll
This happens with I try to open an OleDb.OleDbConnection
What is causing this?
Also the normal Try Catch block doesn't catch this error, I had to use the
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
| |
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
| |
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
| |