That should be fine as well. I'd test that you can read the property first
before trying to write it:
<nested:nest property="sccDTO">
<nested:write property="taskTitle"/>
Paul
> -----Original Message-----
> From: Daniel, Gillian [mailto:[EMAIL PROTECTED]
> Sent: 25 February 2004 18:07
> To: Struts Users Mailing List
> Subject: RE: Nested nest Tag
>
>
> Sorry to bother you again, but I have another stumbling
> block. Although
> I can get the details from the LocDTO with
>
> <nested:nest property="sccDTO">
> <nested:write property="type"/>
>
> The problem is with this line. taskTitle is an attribute of
> LocDTO but
> not SccDTO. When I submit my form, obviously an object of type SccDTO
> is created, since that is in the nested:nest tag, and the property
> taskTitle does not get set.
>
> <nested:text property="taskTitle" size="55" maxlength="55"
> styleClass="editorlargetextbox"/>
>
> Is there a way I can force the jsp to sometimes submit an
> LocDTO rather
> than the SccDTO??
>
> Thanks again,
> Gillian Daniel
>
> -----Original Message-----
> From: Daniel, Gillian
> Sent: 25 February 2004 16:27
> To: Struts Users Mailing List
> Subject: RE: Nested nest Tag
>
> Thanks very much for the advice, I tried it and it did work. I had
> tried before but it didn't work, but I tried again and it did work, so
> thanks for prompting me to try again.
> Something must have been wrong the first time.
>
> Thanks again,
> Gillian
>
> -----Original Message-----
> From: Paul McCulloch [mailto:[EMAIL PROTECTED]
> Sent: 25 February 2004 16:23
> To: 'Struts Users Mailing List'
> Subject: RE: Nested nest Tag
>
> Have you tried using the LocDTO properties? I think it will
> just work -
> Struts uses bean utils which looks at the object you are trying to
> operate
> on, rather than the type it is declared as.
>
> Paul
>
> > -----Original Message-----
> > From: Daniel, Gillian [mailto:[EMAIL PROTECTED]
> > Sent: 25 February 2004 14:31
> > To: [EMAIL PROTECTED]
> > Subject: Nested nest Tag
> >
> >
> > Hi there, I am using Struts 1.1 and Java SE 1.4.2.02 and Java EE 1.4
> >
> >
> >
> > I have an object called SccDTO.java which is extended by
> many objects,
> > but I will use LocDTO,java as the example here.
> >
> >
> >
> > In my SccBean.java - which extends the ValidatorForm - I have
> > getter and
> > setter methods for a SccDTO object.
> >
> >
> >
> > I am using <nested:nest property="sccDTO">
> >
> > <nested:write property="type"/>
> >
> >
> >
> > This is fine, but I actually sometimes want to access methods in the
> > LocDTO, and sometimes from the other objects which extend
> the SccDTO.
> >
> >
> >
> > Now I realise that the SccDTO has no getter and setter
> methods for the
> > LocDTO methods, so this is not going to work, but is there a
> > way around
> > this?
> >
> >
> >
> > Any help would be much appreciated,
> >
> > Gillian Daniel
> >
> >
>
>
> **************************************
> Axios Email Confidentiality Footer
> Privileged/Confidential Information may be contained in this
> message. If
> you are not the addressee indicated in this message (or
> responsible for
> delivery of the message to such person), you may not copy or deliver
> this message to anyone. In such case, you should destroy this message,
> and notify us immediately. If you or your employer does not consent to
> Internet email messages of this kind, please advise us immediately.
> Opinions, conclusions and other information expressed in this message
> are not given or endorsed by my Company or employer unless otherwise
> indicated by an authorised representative independent of this message.
> WARNING:
> While Axios Systems Ltd takes steps to prevent computer viruses from
> being transmitted via electronic mail attachments we cannot guarantee
> that attachments do not contain computer virus code. You are
> therefore
> strongly advised to undertake anti virus checks prior to accessing the
> attachment to this electronic mail. Axios Systems Ltd grants no
> warranties regarding performance use or quality of any attachment and
> undertakes no liability for loss or damage howsoever caused.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]