P
pberent
I am trying to run a c# program which loads very large arrays (total
of about 1.2GB). I have 2GB of RAM on my machine and looking at task
manager it doesnt look like it has all been used. I have set virtual
memory (ie disk space to be used as RAM) to 3070MB. I have tested my
RAM using a RAM testing utility and it seems fine. I am getting an out
of memory error.
I started by using visual c# 2002 but someone told me that it was
buggy so I swithced to visual c# express...but no help. I cut the
program down to a very simple test version...which follows. Are ther
any setting I can change on my PC or within c# to get this to work?
here is the code:
using System;
namespace test1
{
/// <summary>
/// Summary description for Class1.
/// </summary>
class testmain
{
/// <summary>
/// The main entry point for the application.
/// </summary>
[STAThread]
static void Main(string[] args)
{
try {
testclass testclass1 = new testclass();
}
catch {
int yyy=4;
}
}
}
class testclass {
double [] frogarray;
double [] frogarray1;
public testclass() {
frogarray = new double[150100000];
frogarray1 = new double[50000];
int aaa=3;
}
}
}
of about 1.2GB). I have 2GB of RAM on my machine and looking at task
manager it doesnt look like it has all been used. I have set virtual
memory (ie disk space to be used as RAM) to 3070MB. I have tested my
RAM using a RAM testing utility and it seems fine. I am getting an out
of memory error.
I started by using visual c# 2002 but someone told me that it was
buggy so I swithced to visual c# express...but no help. I cut the
program down to a very simple test version...which follows. Are ther
any setting I can change on my PC or within c# to get this to work?
here is the code:
using System;
namespace test1
{
/// <summary>
/// Summary description for Class1.
/// </summary>
class testmain
{
/// <summary>
/// The main entry point for the application.
/// </summary>
[STAThread]
static void Main(string[] args)
{
try {
testclass testclass1 = new testclass();
}
catch {
int yyy=4;
}
}
}
class testclass {
double [] frogarray;
double [] frogarray1;
public testclass() {
frogarray = new double[150100000];
frogarray1 = new double[50000];
int aaa=3;
}
}
}