Can I retrieve non-contiguous selected lines from ListField?
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller
-
- Posts: 1201
- Joined: Sun Apr 24, 2011 2:17 am
Can I retrieve non-contiguous selected lines from ListField?
Hi all,
I have 2000 vids I want to make a playlist from.
If I drag n drop say 37 files into a a livecode textfield
I than want to select all the .mov or all the .avi with a single button
Or multiselect all the movies I consider action movies.
Then I want to do something with just those selected lines etc.
I'm absolutely sure I've covered this topic before but I can't find my post about retrieving only the select lines from a textfield
And processing them one line at a time.
This project looks huge for such a simple task.
is there an easier way?
i.e. the brilliant way livecode handles text chunks, etc.
21204-shifting-selected-text-to-the-right-or-left
http://lessons.runrev.com/s/lessons/m/2 ... ht-or-left
Also, I can't seem to select non-contiguous lines in a textField. Is this possible?
Many thanks in advance
I have 2000 vids I want to make a playlist from.
If I drag n drop say 37 files into a a livecode textfield
I than want to select all the .mov or all the .avi with a single button
Or multiselect all the movies I consider action movies.
Then I want to do something with just those selected lines etc.
I'm absolutely sure I've covered this topic before but I can't find my post about retrieving only the select lines from a textfield
And processing them one line at a time.
This project looks huge for such a simple task.
is there an easier way?
i.e. the brilliant way livecode handles text chunks, etc.
21204-shifting-selected-text-to-the-right-or-left
http://lessons.runrev.com/s/lessons/m/2 ... ht-or-left
Also, I can't seem to select non-contiguous lines in a textField. Is this possible?
Many thanks in advance
All my best,
Barry G. Sumpter
Deving on WinXP sp3-32 bit. LC 5.5 Professional Build 1477
Android/iOS/Server Add Ons. OmegaBundle 2011 value ROCKS!
2 HTC HD2 Latest DorimanX Roms
Might have to reconsider LiveCode iOS Developer Program.
Barry G. Sumpter
Deving on WinXP sp3-32 bit. LC 5.5 Professional Build 1477
Android/iOS/Server Add Ons. OmegaBundle 2011 value ROCKS!
2 HTC HD2 Latest DorimanX Roms
Might have to reconsider LiveCode iOS Developer Program.
-
- Posts: 1201
- Joined: Sun Apr 24, 2011 2:17 am
Re: Can I retrieve non-contiguous selected lines from ListFi
Code: Select all
repeat with x = 1 to number of items in the hilitedLines of field field0
put return after str1
put item x in the hilitedLines of field field0 into selectedLineNumber
put x & ": " & line selectedLineNumber of field field0 after str1
end repeat
--
set the text of field Field1 to str1
All my best,
Barry G. Sumpter
Deving on WinXP sp3-32 bit. LC 5.5 Professional Build 1477
Android/iOS/Server Add Ons. OmegaBundle 2011 value ROCKS!
2 HTC HD2 Latest DorimanX Roms
Might have to reconsider LiveCode iOS Developer Program.
Barry G. Sumpter
Deving on WinXP sp3-32 bit. LC 5.5 Professional Build 1477
Android/iOS/Server Add Ons. OmegaBundle 2011 value ROCKS!
2 HTC HD2 Latest DorimanX Roms
Might have to reconsider LiveCode iOS Developer Program.
Re: Can I retrieve non-contiguous selected lines from ListFi
Hi Barry,
you can turn on non-contiguous in the properties inspector for the list field. Multiple lines option also has to be checked.
gives you a list of the selectedText, one line for each selected line.
Kind regards
Bernd
you can turn on non-contiguous in the properties inspector for the list field. Multiple lines option also has to be checked.
Code: Select all
put the selectedText of field 1
Kind regards
Bernd
-
- Posts: 1201
- Joined: Sun Apr 24, 2011 2:17 am
Re: Can I retrieve non-contiguous selected lines from ListFi
Blast.
Am I getting my TextFields and ListFields mixed up?
Can't seem to get the Text Field to select non-contiguous lines.
Or is it the drag n drop that I'm not setting up properly?
Or is it MAC OS X Lion?
ListBehaviour ticked on
MultipleHighlights ticked on
non-contiguous ticked on
Am I getting my TextFields and ListFields mixed up?
Can't seem to get the Text Field to select non-contiguous lines.
Or is it the drag n drop that I'm not setting up properly?
Or is it MAC OS X Lion?
ListBehaviour ticked on
MultipleHighlights ticked on
non-contiguous ticked on
All my best,
Barry G. Sumpter
Deving on WinXP sp3-32 bit. LC 5.5 Professional Build 1477
Android/iOS/Server Add Ons. OmegaBundle 2011 value ROCKS!
2 HTC HD2 Latest DorimanX Roms
Might have to reconsider LiveCode iOS Developer Program.
Barry G. Sumpter
Deving on WinXP sp3-32 bit. LC 5.5 Professional Build 1477
Android/iOS/Server Add Ons. OmegaBundle 2011 value ROCKS!
2 HTC HD2 Latest DorimanX Roms
Might have to reconsider LiveCode iOS Developer Program.
Re: Can I retrieve non-contiguous selected lines from ListFi
Hi Barry,
I probably don't quite understand what you want.
if you want to set the hilitedLines by script in a list field with
ListBehaviour ticked on
MultipleHighlights ticked on
non-contiguous ticked on
then you can set them
if that is not it then please explain again what is not working.
Kind regards
Bernd
I probably don't quite understand what you want.
if you want to set the hilitedLines by script in a list field with
ListBehaviour ticked on
MultipleHighlights ticked on
non-contiguous ticked on
then you can set them
Code: Select all
on mouseUp
put "1,4,7" into tToHilite
set the hilitedLines of field 1 to tToHilite
end mouseUp
Kind regards
Bernd
-
- Posts: 1201
- Joined: Sun Apr 24, 2011 2:17 am
Re: Can I retrieve non-contiguous selected lines from ListFi
OK thanks Bernd.
LOL.
It was me.
Surprise, Surprise, Surprise!
MAC OS X is not my native development environment.
Fumbling around on the MAC Book Pro keyboard was driving me crazy.
So using logmein to control my macbookpro,
I found the apple command button to be the Windows Start button on my MS Natural Multimedia keyboard.
It looks like the textbox does NOT have the ListBehaviour ticked on.
And the ListBox is just a textbox which has the ListBehaviour ticked on.
The text chunk works the same way on both I would deduce.
Somethings as simple as that makes me doubt everything.
It doesn't have to be this hard.
I'll be kicking meself for a while.
LOL.
It was me.
Surprise, Surprise, Surprise!
MAC OS X is not my native development environment.
Fumbling around on the MAC Book Pro keyboard was driving me crazy.
So using logmein to control my macbookpro,
I found the apple command button to be the Windows Start button on my MS Natural Multimedia keyboard.

It looks like the textbox does NOT have the ListBehaviour ticked on.
And the ListBox is just a textbox which has the ListBehaviour ticked on.
The text chunk works the same way on both I would deduce.
Somethings as simple as that makes me doubt everything.
It doesn't have to be this hard.
I'll be kicking meself for a while.
All my best,
Barry G. Sumpter
Deving on WinXP sp3-32 bit. LC 5.5 Professional Build 1477
Android/iOS/Server Add Ons. OmegaBundle 2011 value ROCKS!
2 HTC HD2 Latest DorimanX Roms
Might have to reconsider LiveCode iOS Developer Program.
Barry G. Sumpter
Deving on WinXP sp3-32 bit. LC 5.5 Professional Build 1477
Android/iOS/Server Add Ons. OmegaBundle 2011 value ROCKS!
2 HTC HD2 Latest DorimanX Roms
Might have to reconsider LiveCode iOS Developer Program.