 				,#collection_object_id#)
 	</cfquery>
 	<cfif len(#coll_object_remarks#) gt 0>
-			<!---- new remark --->
-			<cfquery name="newCollRem" datasource="user_login" username="#session.dbuser#" password="#decrypt(session.epw,session.sessionKey)#">
-				INSERT INTO coll_object_remark (collection_object_id, coll_object_remarks)
-				VALUES (sq_collection_object_id.currval, '#coll_object_remarks#')
-			</cfquery>
+		<!---- new remark --->
+		<cfquery name="newCollRem" datasource="user_login" username="#session.dbuser#" password="#decrypt(session.epw,session.sessionKey)#">
+			INSERT INTO coll_object_remark (collection_object_id, coll_object_remarks)
+			VALUES (sq_collection_object_id.currval, '#escapeQuotes(coll_object_remarks)#')
+		</cfquery>
 	</cfif>
 	</cftransaction>
 	<cflocation url="editParts.cfm?collection_object_id=#collection_object_id#" addtoken="false">

		VALUES (
			sq_collection_object_id.nextval,
			'SP',
			#enteredbyid#,
			sysdate,
			#enteredbyid#,
			'#COLL_OBJ_DISPOSITION#',
			#lot_count#,
			'#condition#',

	</cfoutput>
</cfif>
<!----------------------------------------------------------------------------------->
<cfif action is "deletePart">
	<cfoutput>
		<cftransaction>
			<cfquery name="delePart" datasource="user_login" username="#session.dbuser#" password="#decrypt(session.epw,session.sessionKey)#">
				DELETE FROM specimen_part WHERE collection_object_id = #partID#
			</cfquery>
		</cftransaction>
		<cflocation url="editParts.cfm?collection_object_id=#collection_object_id#" addtoken="false">
	</cfoutput>
</cfif>
<!----------------------------------------------------------------------------------->
<cfif action is "saveEdits">
<cfoutput>
	<cftransaction>
		<cfloop from="1" to="#numberOfParts#" index="n">
			<cfset thisPartId = #evaluate("partID" & n)#>
			<cfset thisPartName = #evaluate("Part_name" & n)#>
			<cfset thisDisposition = #evaluate("coll_obj_disposition" & n)#>
			<cfset thisCondition = #evaluate("condition" & n)#>
			<cfset thisLotCount = #evaluate("lot_count" & n)#>
			<cfset thiscoll_object_remarks = #evaluate("coll_object_remarks" & n)#>
			<cfset thisnewCode = #evaluate("newCode" & n)#>
			<cfset thislabel = #evaluate("label" & n)#>
			<cfset thisparentContainerId = #evaluate("parentContainerId" & n)#>
			<cfset thispartContainerId = #evaluate("partContainerId" & n)#>
			<cfquery name="upPart" datasource="user_login" username="#session.dbuser#" password="#decrypt(session.epw,session.sessionKey)#">
				UPDATE specimen_part SET
					Part_name = '#thisPartName#'
				WHERE collection_object_id = #thisPartId#
			</cfquery>
			<cfquery name="upPartCollObj" datasource="user_login" username="#session.dbuser#" password="#decrypt(session.epw,session.sessionKey)#">
				UPDATE coll_object SET
					coll_obj_disposition = '#thisDisposition#'
					,condition = '#thisCondition#',
					lot_count = #thisLotCount#
				WHERE collection_object_id = #thisPartId#
			</cfquery>
			<cfif len(thiscoll_object_remarks) gt 0>
				<cfquery name="ispartRem" datasource="user_login" username="#session.dbuser#" password="#decrypt(session.epw,session.sessionKey)#">
					select coll_object_remarks from coll_object_remark where
					collection_object_id = #thisPartId#
				</cfquery>
				<cfif ispartRem.recordcount is 0>
					<cfquery name="newCollRem" datasource="user_login" username="#session.dbuser#" password="#decrypt(session.epw,session.sessionKey)#">
						INSERT INTO coll_object_remark (collection_object_id, coll_object_remarks)
						VALUES (#thisPartId#, '#thiscoll_object_remarks#')
					</cfquery>
				<cfelse>
					<cfquery name="updateCollRem" datasource="user_login" username="#session.dbuser#" password="#decrypt(session.epw,session.sessionKey)#">
						UPDATE coll_object_remark SET
						coll_object_remarks = '#thiscoll_object_remarks#'
						 WHERE collection_object_id = #thisPartId#
					</cfquery>
				</cfif>
			<cfelse>
				<cfquery name="killRem" datasource="user_login" username="#session.dbuser#" password="#decrypt(session.epw,session.sessionKey)#">
					UPDATE coll_object_remark SET
					coll_object_remarks = null
					 WHERE collection_object_id = #thisPartId#
				</cfquery>
			</cfif>
			<cfif len(thisnewCode) gt 0>
				<cfstoredproc procedure="movePartToContainer" datasource="user_login" username="#session.dbuser#" password="#decrypt(session.epw,session.sessionKey)#">
					<cfprocparam cfsqltype="CF_SQL_FLOAT" value="#thisPartId#"><!---- v_collection_object_id ---->
					<cfprocparam cfsqltype="cf_sql_varchar" value="#thisnewCode#"><!---- v_barcode ---->
					<cfprocparam cfsqltype="cf_sql_varchar" value=""><!---- v_container_id ---->
					<cfprocparam cfsqltype="cf_sql_varchar" value=""><!---- v_parent_container_type ---->
				</cfstoredproc>
			</cfif>
		</cfloop>
	</cftransaction>
	<cflocation url="editParts.cfm?collection_object_id=#collection_object_id#" addtoken="false">
</cfoutput>
</cfif>
<!----------------------------------------------------------------------------------->
<cfif action is "newpart">
	<cfquery name= "getEntBy" datasource="user_login" username="#session.dbuser#" password="#decrypt(session.epw,session.sessionKey)#">
		SELECT agent_id FROM agent_name WHERE agent_name = '#session.username#'  group by agent_id
	</cfquery>
	<cftransaction>
	<cfquery name="updateColl" datasource="user_login" username="#session.dbuser#" password="#decrypt(session.epw,session.sessionKey)#">
		INSERT INTO coll_object (
