farrukh nadeem wrote:I have a Date class and Time class. Is it possible to pass Time object inside Date constructor so that toString function gives output as 12/05/2013 06:31:30 ?
Well, first off, you're confusing two different things: the contents of your object, and
how it's displayed.
But in answer to your question, the answer is: Yes. It's
your class, so you can do anything you like with it.
The next question though is: Do you
want to? And I'm afraid that without seeing the code for your classes, or knowing how you want them to behave, we simply can't answer that.
Winston