[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4688: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3823)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4690: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3823)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4691: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3823)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4692: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3823)
Poco Forums • View topic - Reading Custom field

Reading Custom field

Scripting questions and ideas

Moderators: Eric, Tomas, robin, Michael

Reading Custom field

Postby Larry » Thu Sep 06, 2007 1:48 pm

I'd like to have a script that will read the contents in Custom 1 for any text. If it finds any text then it will Mark As xx.

I have Custom 1 displaying Annotations (Poco-X-Annotations) but am looking for a quick way to mark all that have text in that field.

I'm at a loss as where to start. Anyone have any ideas?

I did try some existing scripts but they were a little too complicated for what I was trying to do.

Thanks,
Larry
Larry
Resident Poster
 
Posts: 190
Joined: Fri Sep 10, 2004 2:57 pm
Location: Oregon

Postby Michael » Thu Sep 06, 2007 2:31 pm

Here is a way to do this within a folder without resorting to a script.

1. Click on the custom column heading, that will sort the message index by that column.
2. Since you are interested in marking any message regardless of text select the first message with text and then, while holding the shift key down, select the last message with text.
3. Right click and select "Mark | ...".

To do this via a script would require selecting all the messages before running the script. This could be done but it's on the clumsy side. At the moment PocoScript can only act on selected messages.

If you did want to do this via a script you'd have to read the headers checking for an "X-Poco-Annotation" header. You would then need to add an "X-Mark" header to the message.
Michael
Moderator
 
Posts: 866
Joined: Mon Jul 26, 2004 12:14 pm
Location: Victoria BC, Canada

Postby Larry » Thu Sep 06, 2007 10:59 pm

Thanks Michael. The obvious easiest way seemed to elude me.

Larry
Larry
Resident Poster
 
Posts: 190
Joined: Fri Sep 10, 2004 2:57 pm
Location: Oregon


Return to PocoScript Help and How-To

Who is online

Users browsing this forum: No registered users and 1 guest

cron