cancel
Showing results for 
Search instead for 
Did you mean: 

Splitting Strings

0 Kudos

Hi,

I'm writing a report that have strings that I need to split. The only way that I came up with splitting them is by counting the spaces, and then write the remaining character after the specified spaces. My problem is, I'm not sure of the code to write to achieve this. The code below is giving the correct space number, but not sure how to right characters after the space numbers.

= Pos([Student Program Title]; " ") +Pos(Right([Student Program Title];Length([Student Program Title])-Pos([Student Program Title];" "));" ") + Pos(Right([Student Program Title];Length([Student Program Title])+Pos([Student Program Title];" "));" ")+ Pos(Right([Student Program Title];Length([Student Program Title])-Pos([Student Program Title];" "));" ")-1

I want to characters after the 4th space. For example, Bachelor of Science in Biology; I want to display: Biology. Bachelor of Business Administration in Marketing; I want to display: Marketing. So basically, I want display all charters to the right of the "in" in the list below.

Thanks,

Richard

Accepted Solutions (0)

Answers (1)

Answers (1)

ayman_salem
Active Contributor
0 Kudos

just do as follow:

Pos_In =Pos([Student Program Title]; " in ")

M =Right([Student Program Title]; Length([Student Program Title])-[Pos_In]-3)