Submitted by Tom on 2010/06/11 06:01
[How To] append a piece of text to multiple items ?
 
I want to add the same piece of text to multiple items, is this possible ?
 
Example, say I want to add the text "in progress" to 50 items, I would want the 50 items' text to remain the same, just that "in progress" would be added at the end of the item-field text
 

Comments

Yes, it's very easy :
 
Your best bet is probably to create a new Y/N field called "InProgress", and in the equation auto assign section field you'd put.
 
A:Item=AddKeyword(Item, "-- in progress")
 
 
You could also have the option to remove the "-- in progress" tag by adding :

E:Item=RemoveKeyword(item, "-- in progress")
 
Note that you can write the "-- in progress" part however you want... I added the "-- as a separator", but you can remove it . It you do so, both equations (the E: and A: one) need to have the exact same string "in progress")
 
 
 
 

Armando

2010/06/11 12:10

In reply to by Armando

You could also put the equations in the %Done task%complete field so that as soon as the %Done task%complete increases, it show : "-- in progress"
 
AM:Item=AddKeyword(Item, "-- in progress") | E:Item=RemoveKeyword(item, "-- in progress")

Tom

2010/06/12 16:52

In reply to by Armando

[quote=Armando]
You could also put the equations in the %Done task%complete field so that as soon as the %Done task%complete increases, it show : "-- in progress"
 
AM:Item=AddKeyword(Item, "-- in progress") | E:Item=RemoveKeyword(item, "-- in progress")
[/quote]
 
you're getting into a world that's very foreign to me there Armando (lol)
I think I'm one of the most disorganised people I know - I dont use the IQ Calander - or any other, nor do I use any of the prioritising and/or todo type features in IQ.*
 
I had intended to start a thread asking about something along those lines (how people go about "that sort of thing", so - if you were considering it - dont respond in any detail about it here)
 
 
* On the other hand, I have gotten quite organised within the main job I've been doing over the last couple of years - but it's been all related to work done on files (the product) and their status, in terms of what stage they're at
 

Tom

2010/06/12 14:55

In reply to by Armando

[quote=Armando]
Yes, it's very easy :
 
Your best bet is probably to create a new Y/N field called "InProgress", and in the equation auto assign section field you'd put
[...][/quote]
 
great, I suspect I'll be making a few of that type of field
 

Tom

2010/06/14 11:55

In reply to by Armando

[quote=Armando]Your best bet is probably to create a new Y/N field called "InProgress", and in the equation auto assign section field you'd put.
 
A:Item=AddKeyword(Item, "-- in progress")
 
 
You could also have the option to remove the "-- in progress" tag by adding :

E:Item=RemoveKeyword(item, "-- in progress")
[/quote]
 
this works great 
 
__________________________
 
I had the idea to use it for something else - I still have a lot of linked files from when a single-click-link was not automatically created.
If I add <a href=[FileFullName]>Link</a> to the item field, I have a link that I can click once (instead of three times) to launch the file. This could also be convenient for creating a link from the URL field
so
I tried:
A:Item=AddKeyword(Item, "<a href=[FileFullName]>Link</a>")
 
strangely, if the FileFullName field has content, then the text in the item field it is deleted and replaced with nothing (i.e. left blank)
If there is no text in the FileFullName field, just this is added to the field:
<a href=">Link</a>
_____________________________
 
I'll try one with the url field -
A:Item=AddKeyword(Item, "<a href=[URL]>Link</a>")
exactly the same results.
 
I guess it cant handle something with the link text, maybe the square brackets
 
 
Do you think this 'should' work ? I could see the URL version being used by others if it worked but dont know if it's worth following up on...
 

Pierre_Admin

2010/06/14 13:52

In reply to by Tom

> A:Item=AddKeyword(Item, "<a href=[FileFullName]>Link</a>")
What is happening is that the equation parser sees [FileFullName] and does the substitution . This is by design.
 
You could try this...
  1. Rename FileFullName to something else
  2. Repeat your steps
  3. Restore the FileFullName field name
HTH
 

Armando

2010/06/14 19:19

In reply to by Pierre_Admin

I think there's maybe an easier solution :
 
A:item=item & " (<a href=[" & "FileFullName" & "]>Link</a>)" 
 
I'm not sure where Tom wants the link exactly, and how he wants it, but that adds the word
link
at the end of the item field.
 
[edit : I created a shorter version. First one was uselessly long. The best place to put it would probably be the "fileref" field to put the autoassign rule - the filefullname is a "virtual concatenation", so it doesn't trigger the "add" (A:) switch.]

Tom

2010/06/15 03:41

In reply to by Armando

that works a treat Armando
 
I made an AddLink field with this auto-assign rule:
A:item=item & " <a href=[" & "FileFullName" & "]>Link</a>"
which adds a link to the current item text thus: link
 
 
[quote=Armando]
[...]  The best place to put it would probably be the "fileref" field to put the autoassign rule - the filefullname is a "virtual concatenation", so it doesn't trigger the "add" (A:) switch.
[/quote]
 
I only wanted this for some (older) file-linked-items so didnt want to use fileref field - I dont need this link on newer linked-to-file-items as they have hyperlink already.
I dont understand  'the filefullname is a "virtual concatenation", so it doesn't trigger the "add" (A:) switch' - but I think maybe I dont have to (?)
 

Tom

2010/06/15 03:58

In reply to by Tom

> I dont need this link on newer linked-to-file-items as they have hyperlink already
 
OTOH, using this method (adding link at end of item text) could be a good way to get around the sorting problems with linked & non-linked items:
Currently (in general) linked items sort before non-linked items
 
So I might try using the FileRef field...
 
 
[edit] I'm unable to edit the previous post - I actually do understand what you were saying about using the FileRef field as opposed to the FileFullName field - it just took a while to sink in  ;-)
 

Armando

2010/06/15 12:53

In reply to by Tom

Nice. I'm happy it works well for you.
 
You're right that this could help solving the sorting problem. I might add the "link" to the end of my items too....

Tom

2010/06/17 05:48

In reply to by Tom

[quote=Tom]
that works a treat Armando
 
I made an AddLink field with this auto-assign rule:
A:item=item & " <a href=[" & "FileFullName" & "]>Link</a>"
which adds a link to the current item text thus: link
[/quote]
 
this works well as said
A danger is: if I untick this and retick it, all the text in the item field is deleted...
 
Thought I should warn anyone trying it out - presumably this could be avoided by having a reverse version of 
A:item=item & " <a href=[" & "FileFullName" & "]>Link</a>"
 
i.e. the equivalent of
E:Item=RemoveKeyword(item, " & "FileFullName" & ")
or could that work ? - I'll experiment later anyways
 

Armando

2010/06/17 09:54

In reply to by Tom

Normally, unchecking and rechecking shouldn't do anything if you don't have and E: equation.  There might be some problems because of the nature of the filefullname field... Or maybe because of the parsing problem Pierre mentioned before. Not sure.
 
Normally, in that case, unchecking and rechecking should just add an extra  "(Link)" at the end of the item field.
 
====
 
And by the way, you could have used the addkeyword() function to add the item, it's just that I didn't think it was necessary in that case :
 
A:item=addkeyword(item, "<a href=[" & "FileFullName" & "]>Link</a>")
 
And then use
 
E:item=removekeyword(item, "<a href=[" & "FileFullName" & "]>Link</a>")
 
...to remove the "Link" part.
 

Tom

2010/12/07 04:36

In reply to by Armando

[quote=Armando]
And by the way, you could have used the addkeyword() function to add the item, it's just that I didn't think it was necessary in that case :
 
A:item=addkeyword(item, "<a href=[" & "FileFullName" & "]>Link</a>")
 
And then use
 
E:item=removekeyword(item, "<a href=[" & "FileFullName" & "]>Link</a>")
 
...to remove the "Link" part.
[/quote]
 
no,
that deletes *all* the item field content when I simply untick the AddLink field.
 
And if I just use the first half it works but I get an error message
---------------------------
A field rule [AddLink]  references field  but this field does not exist. The rule cannot be executed. Continuing processing rules...
---------------------------
 
I will leave it at that as it seems too unstable...
 
I'll revert it back to -
A:item=item & " <a href=[" & "FileFullName" & "]>Link</a>"
which worked okay
 
and I would say:
if you're going to use this idea  !!! USE WITH CAUTION !!!
 

Tom

2010/06/17 18:19

In reply to by Armando

[quote=Armando]
Your best bet is probably to create a new Y/N field called "InProgress", and in the equation auto assign section field you'd put.
 
A:Item=AddKeyword(Item, "-- in progress")
 
 
You could also have the option to remove the "-- in progress" tag by adding :

E:Item=RemoveKeyword(item, "-- in progress")
 
Note that you can write the "-- in progress" part however you want... I added the "-- as a separator", but you can remove it . It you do so, both equations (the E: and A: one) need to have the exact same string "in progress")
[/quote]
 
I just wanted to let you know that this one is working very well
 

Armando

2010/06/17 19:26

In reply to by Tom

Nice to hear.
 
I wonder why the other one doesn't work. If I have the time, I'll look at it later. My guess is that it's because of the fullfilename's nature.