• 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: Maybe it's too late
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Maybe it's too late


  • Subject: Re: Maybe it's too late
  • From: "Daniele Corti" <email@hidden>
  • Date: Thu, 8 May 2008 15:39:00 +0200



2008/5/8 Joshua Paul <email@hidden>:
Thanks all...

it was a matter of upper/lowercase.

Well, can you insert a toLowerString() while creating the array? if not, you must iterate over the array and check each element after use toLowerCase().

for exaple:

NSArray first, second

for(int i = 0; i < first.count(); i++)
{
   String elemFirst = (String)first.objectAtIndex(i);
   for(int j = 0 ; j < second.count(); j++)
   {
      String elemSecond = (String)second.objectAtIndex(j);
      if(elemFirst.equalsIgnoreCase(elemSecond))
      {
         //Do what you need to do
      }
   }
}
 

On May 8, 2008, at 6:10 AM, David Avendasora wrote:

That and make sure you aren't using "contains(Object element)" as that is not the same as "containsObject(Object object)". This bit me a couple times before I quit making that mistake - usually in the wee hours of the morning.

Dave

On May 8, 2008, at 8:00 AM, Miguel Arroz wrote:

 Yap. containsObject compares objects using equals(), so it should work for Strings. If you are not finding the string with this, it's because it's not on the array. :) Maybe you need to trim() some white spaces?


--
Josh Paul
email@hidden

twitter: joshpaul
linkedin: joshpaul


NOTICE: This e-mail message and all attachments transmitted with it are intended solely for the use of the addressee and may contain legally privileged and confidential information. If the reader of this message is not the intended recipient, or an employee or agent responsible for delivering this message to the intended recipient, you are hereby notified that any dissemination, distribution, copying, or other use of this message or its attachments is strictly prohibited. If you have received this message in error, please notify the sender immediately by replying to this message and please delete it from your computer.




--
Daniele Corti
AIM: S0CR4TE5
Messenger: email@hidden

--
Computers are like air conditioners -- they stop working properly if you open
WINDOWS

--
What about the four lusers of the apocalypse? I nominate:
"advertising", "can't log in", "power switch" and "what backup?"
--Alistair Young
 _______________________________________________
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: Maybe it's too late
      • From: Don Lindsay <email@hidden>
References: 
 >Maybe it's too late (From: Joshua Paul <email@hidden>)
 >Re: Maybe it's too late (From: "Daniele Corti" <email@hidden>)
 >Re: Maybe it's too late (From: Miguel Arroz <email@hidden>)
 >Re: Maybe it's too late (From: David Avendasora <email@hidden>)
 >Re: Maybe it's too late (From: Joshua Paul <email@hidden>)

  • Prev by Date: Re: WO Tutorials
  • Next by Date: Re: Address System using QAS
  • Previous by thread: Re: Maybe it's too late
  • Next by thread: Re: Maybe it's too late
  • Index(es):
    • Date
    • Thread