
14/06/2005, 10:53
|
| | Fecha de Ingreso: octubre-2004
Mensajes: 211
Antigüedad: 20 años, 5 meses Puntos: 2 | |
Estructura en C# Tengo una estructura
public struct Section
{
string sName;
double dLenght;
};
y en una funcion la utilizo asi:
Section mySection;
mySection.sName = "miSeccion";
mySection.dLenght = 2.2;
if (condicion)
MiArrayList.Add(mySection); // --> aqui me dice que la variable no esta inicializada.
else
miArrayList[index] = mySection;
el problema es que me dice que la variable no se ha inicializado.
Que estoy haciendo mal? |