• 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: binding trouble
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: binding trouble


  • Subject: Re: binding trouble
  • From: David LeBer <email@hidden>
  • Date: Fri, 24 Jun 2005 11:47:52 -0400

On 24-Jun-05, at 11:24 AM, Amedeo Mantica wrote:

thanks David, but this works fine If i have only an image in my item object, but i have more images, so i need to pass to the function the image name...

for example, following your example:

public String imgSrc(String aFileName) {
        return "myPath" + aFileName;
}

and bind the WOImage to imgSrc(listItem.theFileName())

The bottom line is that there is no way to pass the parameter to the method via a binding (without using WOOgnl from ProjectWONDER that is).


You have a couple of options:

One would be to add a fileNameToPath cover method for each image.

However, I would probably fix this by creating a reusable component that wraps WOImage (MYImage), has a filePath and fileName binding that accepts the fileName appends the filePath and hands it off to the WOImage src. This would eliminate any additional logic on your main component, you could just bind it up.

;david

--
David LeBer
Codebase Software Systems
site:   http://www.codebase.ca
blog: http://david.codebase.ca


Attachment: smime.p7s
Description: S/MIME cryptographic signature

 _______________________________________________
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: binding trouble
      • From: Mark Morris <email@hidden>
References: 
 >binding trouble (From: Amedeo Mantica <email@hidden>)
 >Re: binding trouble (From: David LeBer <email@hidden>)
 >Re: binding trouble (From: Amedeo Mantica <email@hidden>)

  • Prev by Date: File upload problem
  • Next by Date: Re: Multiple submit in one Form
  • Previous by thread: Re: binding trouble
  • Next by thread: Re: binding trouble
  • Index(es):
    • Date
    • Thread