object reference problem

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • James Dean

    object reference problem

    i have a base class shape with 5 sub class shapes line,polygon,re ctangle
    etc. each of these have common attributes so what i have done is made a
    class for these common attributes. i want to pass into my method the
    type of shape i need for these common attributes but am having
    trouble.These all have the same properties so i don't need to override
    them i just want to be able to access the properties common to all of
    them.......

    public void retrievecommona ttributes(Shape Type shape)
    {
    shape.fill
    }

    the only way i ccan access these attributes is through their classes
    LineType,Polygo nType etc.......



    *** Sent via Developersdex http://www.developersdex.com ***
    Don't just participate in USENET...get rewarded for it!
Working...