Outline View - Exclude data item from delete

Hello,

I am working with a “outline view” that uses a data source. Does anyone know if there is a way to exclude a specific data item from deletion. I have three data items at the top of the list that I want to keep as headers that can’t be deleted. I have no problem deleting them, I just can’t exclude them

Thanks
Dallas

I use the following code to delete items


	if name of theObject is "Remove" then
		
		set Selected_Row to selected data items of outline view "outlineview1" of scroll view "scroll1" of window "main"
		repeat with the_row from 1 to length of Selected_Row 
			set delete_row to item the_row of Selected_Row 
			delete delete_row
		end repeat
		
	end if

Just had to eat, then I got it.


if name of theObject is "Remove" then
		set Selected_Row to selected data items of outline view "outlineview1" of scroll view "scroll1" of window "main"
		repeat with the_row from 1 to length of Selected_Row
			set delete_row to item the_row of Selected_Row

			tell data source of outline view "outlineview1" of scroll view "scroll1" of window "main"
				set d to contents of data cell "File Title" of delete_row
			end tell
			if d is not "Generic Text" then
				delete delete_row
			end if
		end repeat
	end if