The Daily Click ::. Forums ::. Klik Coding Help ::. Find string exact list help
 

Post Reply  Post Oekaki 
 

Posted By Message

Sumo148

Super amazing fantastic user

Registered
  26/01/2009
Points
  530

360 OwnerThe Cake is a LieVIP MemberPokemon Ball!I am an April FoolI donated an open source projectSanta Hat
30th May, 2013 at 30/05/2013 19:45:00 -

Can somebody please explain to me what I'm doing wrong? I thought that the "Find String Exact" expression from the List Object allowed for a certain string to be searched throughout the list object, even if the string is not starting from the beginning of a line. I'm trying to search for a string that's located in the middle of a line. If it doesn't match anything it should return -1 for the line index, however I made an example test file and it doesn't seem to be working correctly. Maybe I don't understand this correctly, can somebody take a look at it?

I'll briefly explain the example file. I have a list object. I wrote one line in it: 10,1,4(1,3)5,10

I try to search for the string "1,4(" using the find string exact expression. Shouldn't it return with a line index that's not -1 since it's a part of the string above? However this isn't the case when I test it.

Here's the example file, it's pretty straightforward:
https://dl.dropboxusercontent.com/u/4459105/MMF2/findstringexacttest.mfa

Edited by Sumo148

 
n/a

Avantar1975



Registered
  01/12/2011
Points
  39
30th May, 2013 at 30/05/2013 20:50:27 -

I can not comment on "Find String Exact", but if it is just a simple string you need to find, the Rich Edit Object serves me well.

Here is my quick example for what it is worth:

http://depositfiles.com/files/11oaz6ugr


Ps:
If it has to be a list you working with with a simple search function and you have Developer - the List View object works great too.

Edited by Avantar1975

 
n/a

lembi2001



Registered
  01/04/2005
Points
  608

VIP MemberIt's-a me, Mario!Wii OwnerI like Aliens!Has Donated, Thank You!PS3 OwnerI am an April Fool
30th May, 2013 at 30/05/2013 22:27:17 -

Ok, I have had a look at this for you and as far as I can understand the Find String Exact function doesn't work the way you want it to.

It is used to differentiate between similar lines that's all.

E.G.

You have a list object with the following lines:

This text is a test
This is also a test
This text is not a test
This is definitely not a test

Now applying the Find functions to the list object:

FindString "This" will return the first line of the list object as all of them contain the word list at the beginning.

FindStringExact "This is also a test" will only return the matching line. The ENTIRE line has to match otherwise it is not an exact string match. Unfortunately there does not appear to be a way to do fuzzy matching in the manner you need (at least using the List objects built in functions)

 
n/a

Sumo148

Super amazing fantastic user

Registered
  26/01/2009
Points
  530

360 OwnerThe Cake is a LieVIP MemberPokemon Ball!I am an April FoolI donated an open source projectSanta Hat
30th May, 2013 at 30/05/2013 22:49:31 -

Oh okay thank you for clearing this up for me Lembi, apparently I've been using this expression incorrectly this entire time. I guess I'll just have to use a fast loop to compare each line of the list for a match using the String Parser object, thanks.

 
n/a

Sumo148

Super amazing fantastic user

Registered
  26/01/2009
Points
  530

360 OwnerThe Cake is a LieVIP MemberPokemon Ball!I am an April FoolI donated an open source projectSanta Hat
30th May, 2013 at 30/05/2013 22:49:33 -

Oh okay thank you for clearing this up for me Lembi, apparently I've been using this expression incorrectly this entire time. I guess I'll just have to use a fast loop to compare each line of the list for a match using the String Parser object, thanks.

 
n/a
   

Post Reply



 



Advertisement

Worth A Click