Forum Discussion
JonathanGlaser
Nov 08, 2022Copper Contributor
Creating a customized column to show the four predecessor task types
I would like to insert a column that shows which of the four (4) possible predecessor task types (FS, SS, FF, SF) all the tasks have. Can anyone tell me if this is even possible, and if so, how can ...
- Nov 10, 2022Jonathan,
Okay, then this formula should do it. Note, after posting my first response I realized it was not the Mid function but the Instr function that is needed.
Text1=IIf([Predecessors]<>"",Switch(instr(1,[Predecessors],"S")=0 And instr(1,[Predecessors],"F")=0,"FS",InStr(1,[Predecessors],"SS")>0,"SS",instr(1,[Predecessors],"FF")>0,"FF",instr(1,[Predecessors],"SF")>0,"SF",instr(1,[Predecessors],"FS")>0,"FS"),"")
John
JonathanGlaser
Copper Contributor
John-project Thank you, John! This is so helpful.
Please would you help with the formula I need to enter to customize the text field so that I use the Mid function to parse out this information I need (sorry to be a pain)?
Thanks in advance!
Jonathan
John-project
Nov 10, 2022Silver Contributor
Jonathan,
Well, before we proceed I need to clarify something. Does your file have ONLY a single predecessor for each task? As I noted in my initial response, if any task has more than one predecessor then a custom field formula will not work.
John
Well, before we proceed I need to clarify something. Does your file have ONLY a single predecessor for each task? As I noted in my initial response, if any task has more than one predecessor then a custom field formula will not work.
John
- JonathanGlaserNov 10, 2022Copper ContributorHi John
Yup - confirming only a single predecessor for each task.
Thanks
Jonathan- John-projectNov 10, 2022Silver ContributorJonathan,
Okay, then this formula should do it. Note, after posting my first response I realized it was not the Mid function but the Instr function that is needed.
Text1=IIf([Predecessors]<>"",Switch(instr(1,[Predecessors],"S")=0 And instr(1,[Predecessors],"F")=0,"FS",InStr(1,[Predecessors],"SS")>0,"SS",instr(1,[Predecessors],"FF")>0,"FF",instr(1,[Predecessors],"SF")>0,"SF",instr(1,[Predecessors],"FS")>0,"FS"),"")
John- JonathanGlaserNov 11, 2022Copper ContributorHi John
Thank you so much!
While I have some basic understanding of formula functionality, this one you provided introduced me to a function I'm unfamiliar with. It's been a valuable learning experience.
Could you perhaps point me to any helpful resource(s) where I can acquire further understanding specifically of formulae?
Kind regards
Jonathan