• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Pass parameters from One HTML to another HTML
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Pass parameters from One HTML to another HTML


  • Subject: Re: Pass parameters from One HTML to another HTML
  • From: miriyala srinivas <email@hidden>
  • Date: Tue, 12 Mar 2013 07:22:57 +0530

Thanks to all for valuable suggestions and I looked around and I modified the html code and then it worked fine.
Modified code
Details.html
<webobject name="test">
Details.wod
test : WOString {
value = username;
}


On Mon, Mar 11, 2013 at 4:17 PM, Jean Pierre Malrieu <email@hidden> wrote:
Your code seems correct to me.
Did you inspect (in debugging mode) the value of the username variable in helloAction() and make sure this value is correctly set before handing it the nextPage? It is quite easy to make a typo when retrieving values from a direct action parameters.
What happens if you call ((Detail)nextPage).setUsername(username) directly?

JPM

Le 11 mars 2013 à 11:27, miriyala srinivas a écrit :

> Hi All,
> I am completely  new to WO.Here I am trying to pass  user entered
> values from one html page to another html.I have retrieved user
> entered values in DirectAction class and I am setting retrieved values
> to another page using takeValueForKey() method and i am returning the
> page,but values are not getting populated to html page.I tried
> printing  WOComponent Page,there its saying subComponents are null
> eventhough I set value to the page,can you guys help me Please.Code is
> below
>
>
> DirectAction.java
> public WOComponent helloAction() {
>
> //retrieving username,password values from request
>
> //get the page and set the value to the key
> WOComponent nextPage = pageWithName("Details");
> nextPage.takeValueForKey(username,"username");
> return nextPage;
>
> }
>
> Details.java
> public class Details extends WOComponent {
>
> private String username;
>
> //getter and setters
>
> }
>
> I am not sure Details.html file is correct
> Details.html
> <wo:str  value="$username"/>
>
> and I am also not sure whether wod file is required for this.Please
> Help in this.
> _______________________________________________
> Do not post admin requests to the list. They will be ignored.
> Webobjects-dev mailing list      (email@hidden)
> Help/Unsubscribe/Update your Subscription:
>
> This email sent to email@hidden


 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Pass parameters from One HTML to another HTML
      • From: email@hidden
References: 
 >Pass parameters from One HTML to another HTML (From: miriyala srinivas <email@hidden>)
 >Re: Pass parameters from One HTML to another HTML (From: Jean Pierre Malrieu <email@hidden>)

  • Prev by Date: Re: More Embedded D2W Questions...
  • Next by Date: Re: More Embedded D2W Questions...
  • Previous by thread: Re: Pass parameters from One HTML to another HTML
  • Next by thread: Re: Pass parameters from One HTML to another HTML
  • Index(es):
    • Date
    • Thread