set parent_name [db_string parent_name "select project_name from im_projects where project_id = :parent_id" -default "undefined"]
if {$ns_write_p}{ ns_write "<li><font color=red>Error: The current user is not allowed to create activities below the (top-level) project '$parent_name' with parent_nrs='$parent_nrs'.</font>"}