Is this possible!!?!?!?!?
I\'m trying to make a set of classes that model a number of different types of things. Properties of these things change over time, and I want
I know, I know, old post.
but I found a solution...
public static List Packets = new List();
public class Packet
{
public Packet()
{
Packets.Add(this);
}
public string packetName;
}
public Packet myPacket = new Packet();
myPacket.packetName = "myPacket";
public void SomeMethod()
{
int x = 0;
foreach (Packet p in Packets)
{
if (p.packetName = "myPacket")
{
Packet myPacket = Packets[x];
break;
}
x++;
}
}