object type

  • Thread starter Thread starter Mike J
  • Start date Start date
M

Mike J

how to assign a instance of a class to object type
i get error

class thisclass
{
object CallingObject
public thisclass(object o)
{
this.CallingObject=0
}
}
thanks
 
Mike J said:
how to assign a instance of a class to object type
i get error

Well since I don't see a single semicolon in your code, I would think
that you would get several errors.
And,
did you mean to set this.CallingObject=0?

If you post the actual error you are getting, it might help as well
class thisclass
{
object CallingObject
public thisclass(object o)
{
this.CallingObject=0
}
}
thanks

Bill
 
yes typo
o no 0
sorry

Bill Butler said:
Well since I don't see a single semicolon in your code, I would think that
you would get several errors.
And,
did you mean to set this.CallingObject=0?

If you post the actual error you are getting, it might help as well


Bill
 
Mike said:
how to assign a instance of a class to object type
i get error

class thisclass
{
object CallingObject
public thisclass(object o)
{
this.CallingObject=0
}
}
thanks

As Bill pointed out, that code doesn't even compile.

Please post the actual code that you have problems with, and also the
error message. There is nothing complicated with what you are trying to
do, so the error has to be in how you are trying to do it. I don't feel
like looking for an error that doesn't exist in code that isn't even used.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top