here is my current code, everything is working correctly except the else if line which checks to see if someone is on hiatus:
Code: Select all
repeat for each line listLine in field "buffalonew"
add 1 to field "bufStart"
if "@" is not in item 1 of listLine then
add 1 to field "bufBlank"
else if item 1 of listLine is among the lines of field "buffalo" on card "data" then
add 1 to field "bufDup"
else
put item 1 of listLine & return after field "buffalo" on card "data"
if item 1 of listLine is among the lines of field "optouts" on card "data" then
add 1 to field "bufOptout"
else if item 1 of listLine is among the lines of field "hiatus" on card "data" then
add 1 to field "bufHiatus"
else
put listLine & return after the field "buffaloout"
add 1 to field "bufSend"
end if
end if
end repeat
Code: Select all
repeat for each line listLine in field "buffalonew"
add 1 to field "bufStart"
if item 1 of listLine contains "@" then
put listLine & return after the field "buffaloout"
else
add 1 to field "bufBlank"
end if
end repeat
put field "buffaloout" into field "buffalonew"
put empty into field "buffaloout"
repeat for each line listLine in field "buffalonew"
if item 1 of listLine is not among the lines of field "buffalo" on card "data" then
put item 1 of listLine & return after field "buffalo" on card "data"
put listLine & return after the field "buffaloout"
else
add 1 to field "bufDup"
end if
end repeat
put field "buffaloout" into field "buffalonew"
put empty into field "buffaloout"
repeat for each line listLine in field "buffalonew"
if item 1 of listLine is not among the lines of field "optouts" on card "data" then
put listLine & return after the field "buffaloout"
else
add 1 to field "bufOptout"
end if
end Repeat
put field "buffaloout" into field "buffalonew"
put empty into field "buffaloout"
repeat for each line listLine in field "buffalonew"
if item 1 of listLine is not among the lines of field "hiatus" on card "data" then
put listLine & return after the field "buffaloout"
put item 1 of listLine & return after field "buffalo" on card "data"
add 1 to field "bufSend"
else
add 1 to field "bufHiatus"
end if
end Repeat