BLS wrote:
On 06/09/2010 22:36, BLS wrote:point3D = = new point3D(10,20,30) // Njet //etcshould be point3D p3 = new point3D(10,20,30) // Njet sorry
Struct is value type, not reference type like class. You don't need 'new' to create it, just uncomment your constructor ('this') and remove 'new':
point3D p3 = point3D(10,20,30);If you really need to allocate a point on the heap, then you'd have to use pointers:
point3D* p3 = new point3D(10,20,30); Though you probably wouldn't need that much.