G
Guest
A user is reporting a crash to desktop to me, and I have isolated it to this
instantiation:
PanelColorsArray ourColors = new PanelColorsArray();
of this class:
// PanelColors.cs
using System;
using System.Drawing;
namespace GaugeGlow.Helpers
{
public class PanelColor
{
public PanelColor()
{
r = 0; g = 0; b = 0;
}
public PanelColor(int red, int green, int blue)
{
r = red;
g = green;
b = blue;
}
public int R
{
get { return r; }
set { r = value; }
}
public int G
{
get { return g; }
set { g = value; }
}
public int B
{
get { return b; }
set { b = value; }
}
private int r, g, b;
}
public class PanelColorsArray
{
public PanelColor[] panelColors; // Declare array
public PanelColorsArray()
{
panelColors = new PanelColor[] { cDay, cNight, cLuminous, cTemp };
panelColors.Initialize();
}
public void PanelColorsInit()
{
cDay.R = 255; cDay.G = 255; cDay.B = 255;
cNight.R = 10; cNight.G = 10; cNight.B = 10;
cLuminous.R = 40; cLuminous.G = 220; cLuminous.B = 20;
cTemp.R = 0; cTemp.G = 0; cTemp.B = 0;
}
PanelColor cDay = new PanelColor(255, 255, 255);
PanelColor cNight = new PanelColor(10, 10, 10);
PanelColor cLuminous = new PanelColor(40, 220, 20);
PanelColor cTemp = new PanelColor();
} // class: PanelColorsArray
} // namespace
The users must be on a min of XP Home SP2, which should have GDI+ installed,
so I'm clueless as to why this would result in a crash with the following
typical:
Event Type: Error
Event Source: .NET Runtime 2.0 Error Reporting
Event Category: None
Event ID: 5000
Date: 10/08/2006
Time: 7:49:05 PM
User: N/A
Computer: KYLE
Description:
EventType clr20r3, P1 gaugeglow.exe, P2 1.2.0.0, P3 44d863c7, P4
system.drawing, P5 2.0.0.0, P6 4333aeaf, P7 178, P8 26, P9
system.argumentexception, P10 NIL.
Thanks for any ideas. Patrick
instantiation:
PanelColorsArray ourColors = new PanelColorsArray();
of this class:
// PanelColors.cs
using System;
using System.Drawing;
namespace GaugeGlow.Helpers
{
public class PanelColor
{
public PanelColor()
{
r = 0; g = 0; b = 0;
}
public PanelColor(int red, int green, int blue)
{
r = red;
g = green;
b = blue;
}
public int R
{
get { return r; }
set { r = value; }
}
public int G
{
get { return g; }
set { g = value; }
}
public int B
{
get { return b; }
set { b = value; }
}
private int r, g, b;
}
public class PanelColorsArray
{
public PanelColor[] panelColors; // Declare array
public PanelColorsArray()
{
panelColors = new PanelColor[] { cDay, cNight, cLuminous, cTemp };
panelColors.Initialize();
}
public void PanelColorsInit()
{
cDay.R = 255; cDay.G = 255; cDay.B = 255;
cNight.R = 10; cNight.G = 10; cNight.B = 10;
cLuminous.R = 40; cLuminous.G = 220; cLuminous.B = 20;
cTemp.R = 0; cTemp.G = 0; cTemp.B = 0;
}
PanelColor cDay = new PanelColor(255, 255, 255);
PanelColor cNight = new PanelColor(10, 10, 10);
PanelColor cLuminous = new PanelColor(40, 220, 20);
PanelColor cTemp = new PanelColor();
} // class: PanelColorsArray
} // namespace
The users must be on a min of XP Home SP2, which should have GDI+ installed,
so I'm clueless as to why this would result in a crash with the following
typical:
Event Type: Error
Event Source: .NET Runtime 2.0 Error Reporting
Event Category: None
Event ID: 5000
Date: 10/08/2006
Time: 7:49:05 PM
User: N/A
Computer: KYLE
Description:
EventType clr20r3, P1 gaugeglow.exe, P2 1.2.0.0, P3 44d863c7, P4
system.drawing, P5 2.0.0.0, P6 4333aeaf, P7 178, P8 26, P9
system.argumentexception, P10 NIL.
Thanks for any ideas. Patrick