	// ===============================================================
	// Global Var
	// ===============================================================
	
	// Edit Handler
	// _______________________________________________________________________
	var EDIT_HANDLER = function(){};	
	EDIT_HANDLER.REF_IS_MODIFIED = false;
	EDIT_HANDLER.HAS_NEWLY_SAVED_DATA = false;
	var PROPERTY_PARENT_ID = 0;
	var PROPERTY_PARENT_DESCRIPTION = "";
	
	
	// Cache
	// _______________________________________________________________________
	var PROPERTY_CAT_PRODUCT_ID = -1;
	var PROPERTY_EDIT_MODE = false;
	var PROPERTY_EDIT_ROW_INDEX = -1;
	var INPUT_INSTANCE = null;
	
	
	// Buttons [Optional]
	// _______________________________________________________________________
	var ADD_BBI = null;
	var SAVE_BBI = null;
	var DELETE_BBI = null;
	var CANCEL_BBI = null;
	var NAVIGATION_BACK_BBI = null;
	
	var SEARCH_CMD = null;
	var PRINT_BBI = null;
	var EXPORT_BBI = null;
	
	
	// Dialog Controls [Optional]
	// _______________________________________________________________________
	var CAT_PRODUCT_BARCODE_TXT = null;
	var CAT_PRODUCT_ITEMCODE_TXT = null;
	var CAT_PRODUCT_DESCRIPTION_TXT = null;
	var CAT_PRODUCT_ALIAS_MAIN_TXT = null;
	var CAT_PRODUCT_ALIAS_SUB_TXT = null;
	var CAT_PRODUCT_CAT_PRODTYPE_ID_LV1_CMB = null;
	var CAT_PRODUCT_CAT_PRODTYPE_ID_LV2_CMB = null;
	var CAT_PRODUCT_CAT_PRODTYPE_ID_LV3_CMB = null;
	var CAT_PRODUCT_CAT_BRAND_ID_CMB = null;
	var CAT_PRODUCT_CAT_UOM_ID_CMB = null;
	var CAT_PRODUCT_CAT_DISCOUNT_ID_CMB = null;
	var CAT_PRODUCT_CAT_TAXMODEL_ID_CMB = null;
	var CAT_PRODUCT_AMOUNT_COST_TXT = null;
	var CAT_PRODUCT_AMOUNT_PRICE_TXT = null;
	var CAT_PRODUCT_AMOUNT_VAT_TXT = null;
	var CAT_PRODUCT_AMOUNT_POINT_TXT = null;
	var CAT_PRODUCT_ALLOW_DISCOUNT_CMB = null;
	var CAT_PRODUCT_ALLOW_SENIOR_CMB = null;
	var CAT_PRODUCT_IS_BASICCOM_CMB = null;
	var CAT_PRODUCT_IS_SERVICE_CMB = null;
	var CAT_PRODUCT_REORDER_POINT_TXT = null;
	var CAT_PRODUCT_REORDER_QUANTITY_TXT = null;
	var CAT_PRODUCT_CAT_PRODUCT_ID_CMB = null;
	var CAT_PRODUCT_PER_PIECE_QTY_TXT = null;
	var CAT_PRODUCT_CAT_SUPPLIER_ID_CMB = null;
	var CAT_PRODUCT_IS_INVENTORY_ONLY_TXT = null;
	var CAT_PRODUCT_IS_SERIALIZED_CMB = null;
	var CAT_PRODUCT_STATUS_CMB = null;
	var PARAM_CAT_PRODUCT_ID_FILE_FP = null;
	
	
	// DGV Controls
	// _______________________________________________________________________
	var PRODUCT_DGV = null;


	// ===============================================================
	// Initialize Controls
	// ===============================================================     
	function FORM_INITIALIZE()
	{
		// Load Cache Parent Data [Add Redirects if this is a required data.]
		// ...........................................
		if(JSVC_COOKIE.VAR_ISSET("PROPERTY_PARENT_ID_PRODUCT"))
		{
			PROPERTY_PARENT_ID = JSVC_COOKIE.VAR_READ("PROPERTY_PARENT_ID_PRODUCT");
		}	
		else
		{
			//window.location = JSCUS_CACHE.AUTH_REDIRECT_URL[JSCUS_CACHE.LOGIN_CLASS];
			//window.close();
		}
		if(JSVC_COOKIE.VAR_ISSET("PROPERTY_PARENT_DESCRIPTION_PRODUCT"))
		{
			PROPERTY_PARENT_DESCRIPTION = JSVC_COOKIE.VAR_READ("PROPERTY_PARENT_DESCRIPTION_PRODUCT");
			if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("PAGE_PARENT_DESCRIPTION_TXT") == true)
			{
				JSOC_ELEMENT.VAR_VALUE("PAGE_PARENT_DESCRIPTION_TXT", PROPERTY_PARENT_DESCRIPTION);			
			}
			if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("PAGE_PARENT_DESCRIPTION_LBL") == true)
			{
				JSOC_ELEMENT.VAR_VALUE("PAGE_PARENT_DESCRIPTION_LBL", PROPERTY_PARENT_DESCRIPTION);			
			}
			if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("PAGE_TITLE_LBL") == true)
			{
				JSOC_ELEMENT.VAR_VALUE("PAGE_TITLE_LBL", JSOC_ELEMENT.VAR_VALUE("PAGE_TITLE_LBL") + " : " + PROPERTY_PARENT_DESCRIPTION);	
			}
		}	
		else
		{
			//window.location = JSCUS_CACHE.AUTH_REDIRECT_URL[JSCUS_CACHE.LOGIN_CLASS];	
		}
	
		// Restore Cache on reload
		// ...........................................	
		if
		(
			JSVC_COOKIE.VAR_ISSET("PROPERTY_PARENT_ID_PRODUCT") || 
			JSVC_COOKIE.VAR_ISSET("PROPERTY_PARENT_DESCRIPTION_PRODUCT")
		)
		{
			  window.onbeforeunload = function(event)
			  {
					// Get Current Root path
					var CURRENT_ROOT_PATH = JSCUS_CACHE.ROOT_PATH + JSVC_STR.VAR_MID(JSVC_STR.VAR_DLEFT(JSCUS_CACHE.AUTH_REDIRECT_URL[JSCUS_CACHE.LOGIN_CLASS], JSCUS_CACHE.SERVER_URL.length), 1, 1);
				
					// Cache Primary Key
					JSVC_COOKIE.VAR_ADD
					(
						'PROPERTY_PARENT_ID_PRODUCT', 
						PROPERTY_PARENT_ID, 
						5, 
						CURRENT_ROOT_PATH
					);
					
					// Cache Description
					JSVC_COOKIE.VAR_ADD
					(
						'PROPERTY_PARENT_DESCRIPTION_PRODUCT', 
						PROPERTY_PARENT_DESCRIPTION, 
						5, 
						CURRENT_ROOT_PATH
					);
			  };
		}
		
 		// Cache Class Properties
		// ...........................................
		if(JSVC_COOKIE.VAR_ISSET("PROPERTY_CAT_PRODUCT_ID"))
		{
			PROPERTY_CAT_PRODUCT_ID = JSVC_COOKIE.VAR_READ("PROPERTY_CAT_PRODUCT_ID");
		}	
		if(JSVC_COOKIE.VAR_ISSET("PROPERTY_EDIT_MODE"))
		{
			PROPERTY_EDIT_MODE = JSVC_COOKIE.VAR_READ("PROPERTY_CAT_PRODUCT_ID");
		}
	
		// Initialize: Modals
		// ...........................................
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("PRODUCT_MODAL") == true)
		{
			// Display Modal
			JSOC_DIALOG.VAR_MODAL("PRODUCT_MODAL", false);
		}
				
		// Initialize: Ribbon Buttons [Add Item]
		// ...........................................
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("ADD_BBI"))
		{
    		ADD_BBI = JSOC_ELEMENT.VAR_GET("ADD_BBI");     	
			
			// Add OnClick event [Show Modal]
			if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("PRODUCT_MODAL"))
			{
				ADD_BBI.onclick = 
					function()
					{		
						// Display Modal
						PROPERTY_CAT_PRODUCT_ID = FLAG_BIGINT_NULL;
						PROPERTY_EDIT_ROW_INDEX = -1;
						
						if(JSVC_VAR.VAR_ISSET(INPUT_INSTANCE))
						{
							JSOC_WINDOW.VAR_INPUT_INSTANCE_RESTORE(INPUT_INSTANCE);
						}
						EDIT_HANDLER.REF_IS_MODIFIED = false;
						JSOC_DIALOG.VAR_MODAL("PRODUCT_MODAL", true);
					}		
			}
			// Add OnClick event [Show Add/Edit Page]
			else
			{
				
			}
		}	
		
		// Initialize: Ribbon Buttons [Save Changes]
		// ...........................................
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("SAVE_BBI"))
		{
    		SAVE_BBI = JSOC_ELEMENT.VAR_GET("SAVE_BBI");     
			if(JSVC_VAR.VAR_ISSET(HTTP_SAVE))
			{
				// Prepare Save callback
				var CALLBACK_HANDLER = 
					function(IS_SUCCESS)
					{
						// Abort on failure
						if(IS_SUCCESS == false)
						{
							return;
						}
					
						// Show record saved messageBox
						JSVC_INFO.VAR_RECORD_SAVED('');
					}
				
				// Add OnClick event
				SAVE_BBI.onclick = 
					function()
					{
						HTTP_SAVE(CALLBACK_HANDLER);
					}
			}
		}
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("CANCEL_BBI"))
		{
    		CANCEL_BBI = JSOC_ELEMENT.VAR_GET("CANCEL_BBI");      		
		}
		
		// Initialize: Ribbon Buttons [Add Back Link (to parent page)]
		// ...........................................
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("NAVIGATION_BACK_BBI"))
		{
    		NAVIGATION_BACK_BBI = JSOC_ELEMENT.VAR_GET("NAVIGATION_BACK_BBI");  
			
			// Add OnClick event
			NAVIGATION_BACK_BBI.onclick = 
				function()
				{
				}		
		}
		
		// Initialize: Ribbon Buttons [Add Forward Link (to child page)]
		// ...........................................
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("NAVIGATION_BACK_BBI"))
		{
    		NAVIGATION_BACK_BBI = JSOC_ELEMENT.VAR_GET("NAVIGATION_BACK_BBI");  
			
			// Add OnClick event
			NAVIGATION_BACK_BBI.onclick = 
				function()
				{
				}		
		}

		// Initialize: Ribbon Buttons [Add Search]
		// ...........................................
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("SEARCH_CMD"))
		{
			SEARCH_CMD = JSOC_ELEMENT.VAR_GET("SEARCH_CMD");
			SEARCH_CMD.onclick = function(){HTTP_SEARCH()};
		}		

		// Initialize: Ribbon Buttons [Add Print]
		// ...........................................
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("PRINT_BBI"))
		{
			PRINT_BBI = JSOC_ELEMENT.VAR_GET("PRINT_BBI");
			PRINT_BBI.onclick = function()
			{
				window.print();
			};
		}		
		
		// Initialize: Ribbon Buttons [Add Search]
		// ...........................................
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("EXPORT_BBI"))
		{
			EXPORT_BBI = JSOC_ELEMENT.VAR_GET("EXPORT_BBI");
			EXPORT_BBI.onclick = function()
			{
				JSRC_EXCEL.REF_EXPORT('PRODUCT_DGV');
			};
		}		

		
		// Prepare onChange event
		// ...........................................
		var ON_CHANGE_EVENT = '';
		
		
		// Initialize: Input Controls
		// ...........................................
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("CAT_PRODUCT_ID_TXT"))
		{
			CAT_PRODUCT_ID_TXT = JSOC_ELEMENT.VAR_GET("CAT_PRODUCT_ID_TXT");      
			CAT_PRODUCT_ID_TXT.onchange = 
				function()
				{
					if(CAT_PRODUCT_ID_TXT.disabled == false)
					{
						EDIT_HANDLER.REF_IS_MODIFIED = true;
					}
				};
			CAT_PRODUCT_ID_TXT.onkeypress = function(){CAT_PRODUCT_ID_TXT.onchange();};
			CAT_PRODUCT_ID_TXT.onpaste = function(){CAT_PRODUCT_ID_TXT.onchange();};
			CAT_PRODUCT_ID_TXT.oninput = function(){CAT_PRODUCT_ID_TXT.onchange();};
		}
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("CAT_PRODUCT_BARCODE_TXT"))
		{
			CAT_PRODUCT_BARCODE_TXT = JSOC_ELEMENT.VAR_GET("CAT_PRODUCT_BARCODE_TXT");      
			CAT_PRODUCT_BARCODE_TXT.onchange = 
				function()
				{
					if(CAT_PRODUCT_BARCODE_TXT.disabled == false)
					{
						EDIT_HANDLER.REF_IS_MODIFIED = true;
					}
				};
			CAT_PRODUCT_BARCODE_TXT.onkeypress = function(){CAT_PRODUCT_BARCODE_TXT.onchange();};
			CAT_PRODUCT_BARCODE_TXT.onpaste = function(){CAT_PRODUCT_BARCODE_TXT.onchange();};
			CAT_PRODUCT_BARCODE_TXT.oninput = function(){CAT_PRODUCT_BARCODE_TXT.onchange();};
		}
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("CAT_PRODUCT_ITEMCODE_TXT"))
		{
			CAT_PRODUCT_ITEMCODE_TXT = JSOC_ELEMENT.VAR_GET("CAT_PRODUCT_ITEMCODE_TXT");      
			CAT_PRODUCT_ITEMCODE_TXT.onchange = 
				function()
				{
					if(CAT_PRODUCT_ITEMCODE_TXT.disabled == false)
					{
						EDIT_HANDLER.REF_IS_MODIFIED = true;
					}
				};
			CAT_PRODUCT_ITEMCODE_TXT.onkeypress = function(){CAT_PRODUCT_ITEMCODE_TXT.onchange();};
			CAT_PRODUCT_ITEMCODE_TXT.onpaste = function(){CAT_PRODUCT_ITEMCODE_TXT.onchange();};
			CAT_PRODUCT_ITEMCODE_TXT.oninput = function(){CAT_PRODUCT_ITEMCODE_TXT.onchange();};
		}
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("CAT_PRODUCT_DESCRIPTION_TXT"))
		{
			CAT_PRODUCT_DESCRIPTION_TXT = JSOC_ELEMENT.VAR_GET("CAT_PRODUCT_DESCRIPTION_TXT");      
			CAT_PRODUCT_DESCRIPTION_TXT.onchange = 
				function()
				{
					if(CAT_PRODUCT_DESCRIPTION_TXT.disabled == false)
					{
						EDIT_HANDLER.REF_IS_MODIFIED = true;
					}
				};
			CAT_PRODUCT_DESCRIPTION_TXT.onkeypress = function(){CAT_PRODUCT_DESCRIPTION_TXT.onchange();};
			CAT_PRODUCT_DESCRIPTION_TXT.onpaste = function(){CAT_PRODUCT_DESCRIPTION_TXT.onchange();};
			CAT_PRODUCT_DESCRIPTION_TXT.oninput = function(){CAT_PRODUCT_DESCRIPTION_TXT.onchange();};
		}
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("CAT_PRODUCT_ALIAS_MAIN_TXT"))
		{
			CAT_PRODUCT_ALIAS_MAIN_TXT = JSOC_ELEMENT.VAR_GET("CAT_PRODUCT_ALIAS_MAIN_TXT");      
			CAT_PRODUCT_ALIAS_MAIN_TXT.onchange = 
				function()
				{
					if(CAT_PRODUCT_ALIAS_MAIN_TXT.disabled == false)
					{
						EDIT_HANDLER.REF_IS_MODIFIED = true;
					}
				};
			CAT_PRODUCT_ALIAS_MAIN_TXT.onkeypress = function(){CAT_PRODUCT_ALIAS_MAIN_TXT.onchange();};
			CAT_PRODUCT_ALIAS_MAIN_TXT.onpaste = function(){CAT_PRODUCT_ALIAS_MAIN_TXT.onchange();};
			CAT_PRODUCT_ALIAS_MAIN_TXT.oninput = function(){CAT_PRODUCT_ALIAS_MAIN_TXT.onchange();};
		}
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("CAT_PRODUCT_ALIAS_SUB_TXT"))
		{
			CAT_PRODUCT_ALIAS_SUB_TXT = JSOC_ELEMENT.VAR_GET("CAT_PRODUCT_ALIAS_SUB_TXT");      
			CAT_PRODUCT_ALIAS_SUB_TXT.onchange = 
				function()
				{
					if(CAT_PRODUCT_ALIAS_SUB_TXT.disabled == false)
					{
						EDIT_HANDLER.REF_IS_MODIFIED = true;
					}
				};
			CAT_PRODUCT_ALIAS_SUB_TXT.onkeypress = function(){CAT_PRODUCT_ALIAS_SUB_TXT.onchange();};
			CAT_PRODUCT_ALIAS_SUB_TXT.onpaste = function(){CAT_PRODUCT_ALIAS_SUB_TXT.onchange();};
			CAT_PRODUCT_ALIAS_SUB_TXT.oninput = function(){CAT_PRODUCT_ALIAS_SUB_TXT.onchange();};
		}
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("CAT_PRODUCT_CAT_PRODTYPE_ID_LV1_CMB"))
		{
			CAT_PRODUCT_CAT_PRODTYPE_ID_LV1_CMB = JSOC_ELEMENT.VAR_GET("CAT_PRODUCT_CAT_PRODTYPE_ID_LV1_CMB");      	
			CAT_PRODUCT_CAT_PRODTYPE_ID_LV1_CMB.onchange = 
				function()
				{
					if(CAT_PRODUCT_CAT_PRODTYPE_ID_LV1_CMB.disabled == false)
					{
						EDIT_HANDLER.REF_IS_MODIFIED = true;
					}
				};
			CAT_PRODUCT_CAT_PRODTYPE_ID_LV1_CMB.onkeypress = function(){CAT_PRODUCT_CAT_PRODTYPE_ID_LV1_CMB.onchange();};
			CAT_PRODUCT_CAT_PRODTYPE_ID_LV1_CMB.onpaste = function(){CAT_PRODUCT_CAT_PRODTYPE_ID_LV1_CMB.onchange();};
			CAT_PRODUCT_CAT_PRODTYPE_ID_LV1_CMB.oninput = function(){CAT_PRODUCT_CAT_PRODTYPE_ID_LV1_CMB.onchange();};							
		}
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("CAT_PRODUCT_CAT_PRODTYPE_ID_LV2_CMB"))
		{
			CAT_PRODUCT_CAT_PRODTYPE_ID_LV2_CMB = JSOC_ELEMENT.VAR_GET("CAT_PRODUCT_CAT_PRODTYPE_ID_LV2_CMB");      	
			CAT_PRODUCT_CAT_PRODTYPE_ID_LV2_CMB.onchange = 
				function()
				{
					if(CAT_PRODUCT_CAT_PRODTYPE_ID_LV2_CMB.disabled == false)
					{
						EDIT_HANDLER.REF_IS_MODIFIED = true;
					}
				};
			CAT_PRODUCT_CAT_PRODTYPE_ID_LV2_CMB.onkeypress = function(){CAT_PRODUCT_CAT_PRODTYPE_ID_LV2_CMB.onchange();};
			CAT_PRODUCT_CAT_PRODTYPE_ID_LV2_CMB.onpaste = function(){CAT_PRODUCT_CAT_PRODTYPE_ID_LV2_CMB.onchange();};
			CAT_PRODUCT_CAT_PRODTYPE_ID_LV2_CMB.oninput = function(){CAT_PRODUCT_CAT_PRODTYPE_ID_LV2_CMB.onchange();};							
		}
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("CAT_PRODUCT_CAT_PRODTYPE_ID_LV3_CMB"))
		{
			CAT_PRODUCT_CAT_PRODTYPE_ID_LV3_CMB = JSOC_ELEMENT.VAR_GET("CAT_PRODUCT_CAT_PRODTYPE_ID_LV3_CMB");      	
			CAT_PRODUCT_CAT_PRODTYPE_ID_LV3_CMB.onchange = 
				function()
				{
					if(CAT_PRODUCT_CAT_PRODTYPE_ID_LV3_CMB.disabled == false)
					{
						EDIT_HANDLER.REF_IS_MODIFIED = true;
					}
				};
			CAT_PRODUCT_CAT_PRODTYPE_ID_LV3_CMB.onkeypress = function(){CAT_PRODUCT_CAT_PRODTYPE_ID_LV3_CMB.onchange();};
			CAT_PRODUCT_CAT_PRODTYPE_ID_LV3_CMB.onpaste = function(){CAT_PRODUCT_CAT_PRODTYPE_ID_LV3_CMB.onchange();};
			CAT_PRODUCT_CAT_PRODTYPE_ID_LV3_CMB.oninput = function(){CAT_PRODUCT_CAT_PRODTYPE_ID_LV3_CMB.onchange();};							
		}
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("CAT_PRODUCT_CAT_BRAND_ID_CMB"))
		{
			CAT_PRODUCT_CAT_BRAND_ID_CMB = JSOC_ELEMENT.VAR_GET("CAT_PRODUCT_CAT_BRAND_ID_CMB");      	
			CAT_PRODUCT_CAT_BRAND_ID_CMB.onchange = 
				function()
				{
					if(CAT_PRODUCT_CAT_BRAND_ID_CMB.disabled == false)
					{
						EDIT_HANDLER.REF_IS_MODIFIED = true;
					}
				};
			CAT_PRODUCT_CAT_BRAND_ID_CMB.onkeypress = function(){CAT_PRODUCT_CAT_BRAND_ID_CMB.onchange();};
			CAT_PRODUCT_CAT_BRAND_ID_CMB.onpaste = function(){CAT_PRODUCT_CAT_BRAND_ID_CMB.onchange();};
			CAT_PRODUCT_CAT_BRAND_ID_CMB.oninput = function(){CAT_PRODUCT_CAT_BRAND_ID_CMB.onchange();};							
		}
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("CAT_PRODUCT_CAT_UOM_ID_CMB"))
		{
			CAT_PRODUCT_CAT_UOM_ID_CMB = JSOC_ELEMENT.VAR_GET("CAT_PRODUCT_CAT_UOM_ID_CMB");      	
			CAT_PRODUCT_CAT_UOM_ID_CMB.onchange = 
				function()
				{
					if(CAT_PRODUCT_CAT_UOM_ID_CMB.disabled == false)
					{
						EDIT_HANDLER.REF_IS_MODIFIED = true;
					}
				};
			CAT_PRODUCT_CAT_UOM_ID_CMB.onkeypress = function(){CAT_PRODUCT_CAT_UOM_ID_CMB.onchange();};
			CAT_PRODUCT_CAT_UOM_ID_CMB.onpaste = function(){CAT_PRODUCT_CAT_UOM_ID_CMB.onchange();};
			CAT_PRODUCT_CAT_UOM_ID_CMB.oninput = function(){CAT_PRODUCT_CAT_UOM_ID_CMB.onchange();};							
		}
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("CAT_PRODUCT_CAT_DISCOUNT_ID_CMB"))
		{
			CAT_PRODUCT_CAT_DISCOUNT_ID_CMB = JSOC_ELEMENT.VAR_GET("CAT_PRODUCT_CAT_DISCOUNT_ID_CMB");      	
			CAT_PRODUCT_CAT_DISCOUNT_ID_CMB.onchange = 
				function()
				{
					if(CAT_PRODUCT_CAT_DISCOUNT_ID_CMB.disabled == false)
					{
						EDIT_HANDLER.REF_IS_MODIFIED = true;
					}
				};
			CAT_PRODUCT_CAT_DISCOUNT_ID_CMB.onkeypress = function(){CAT_PRODUCT_CAT_DISCOUNT_ID_CMB.onchange();};
			CAT_PRODUCT_CAT_DISCOUNT_ID_CMB.onpaste = function(){CAT_PRODUCT_CAT_DISCOUNT_ID_CMB.onchange();};
			CAT_PRODUCT_CAT_DISCOUNT_ID_CMB.oninput = function(){CAT_PRODUCT_CAT_DISCOUNT_ID_CMB.onchange();};							
		}
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("CAT_PRODUCT_CAT_TAXMODEL_ID_CMB"))
		{
			CAT_PRODUCT_CAT_TAXMODEL_ID_CMB = JSOC_ELEMENT.VAR_GET("CAT_PRODUCT_CAT_TAXMODEL_ID_CMB");      	
			CAT_PRODUCT_CAT_TAXMODEL_ID_CMB.onchange = 
				function()
				{
					if(CAT_PRODUCT_CAT_TAXMODEL_ID_CMB.disabled == false)
					{
						EDIT_HANDLER.REF_IS_MODIFIED = true;
					}
				};
			CAT_PRODUCT_CAT_TAXMODEL_ID_CMB.onkeypress = function(){CAT_PRODUCT_CAT_TAXMODEL_ID_CMB.onchange();};
			CAT_PRODUCT_CAT_TAXMODEL_ID_CMB.onpaste = function(){CAT_PRODUCT_CAT_TAXMODEL_ID_CMB.onchange();};
			CAT_PRODUCT_CAT_TAXMODEL_ID_CMB.oninput = function(){CAT_PRODUCT_CAT_TAXMODEL_ID_CMB.onchange();};							
		}
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("CAT_PRODUCT_AMOUNT_COST_TXT"))
		{
			CAT_PRODUCT_AMOUNT_COST_TXT = JSOC_ELEMENT.VAR_GET("CAT_PRODUCT_AMOUNT_COST_TXT");      
			CAT_PRODUCT_AMOUNT_COST_TXT.onchange = 
				function()
				{
					if(CAT_PRODUCT_AMOUNT_COST_TXT.disabled == false)
					{
						EDIT_HANDLER.REF_IS_MODIFIED = true;
					}
				};
			CAT_PRODUCT_AMOUNT_COST_TXT.onkeypress = function(){CAT_PRODUCT_AMOUNT_COST_TXT.onchange();};
			CAT_PRODUCT_AMOUNT_COST_TXT.onpaste = function(){CAT_PRODUCT_AMOUNT_COST_TXT.onchange();};
			CAT_PRODUCT_AMOUNT_COST_TXT.oninput = function(){CAT_PRODUCT_AMOUNT_COST_TXT.onchange();};
		}
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("CAT_PRODUCT_AMOUNT_PRICE_TXT"))
		{
			CAT_PRODUCT_AMOUNT_PRICE_TXT = JSOC_ELEMENT.VAR_GET("CAT_PRODUCT_AMOUNT_PRICE_TXT");      
			CAT_PRODUCT_AMOUNT_PRICE_TXT.onchange = 
				function()
				{
					if(CAT_PRODUCT_AMOUNT_PRICE_TXT.disabled == false)
					{
						EDIT_HANDLER.REF_IS_MODIFIED = true;
					}
				};
			CAT_PRODUCT_AMOUNT_PRICE_TXT.onkeypress = function(){CAT_PRODUCT_AMOUNT_PRICE_TXT.onchange();};
			CAT_PRODUCT_AMOUNT_PRICE_TXT.onpaste = function(){CAT_PRODUCT_AMOUNT_PRICE_TXT.onchange();};
			CAT_PRODUCT_AMOUNT_PRICE_TXT.oninput = function(){CAT_PRODUCT_AMOUNT_PRICE_TXT.onchange();};
		}
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("CAT_PRODUCT_AMOUNT_VAT_TXT"))
		{
			CAT_PRODUCT_AMOUNT_VAT_TXT = JSOC_ELEMENT.VAR_GET("CAT_PRODUCT_AMOUNT_VAT_TXT");      
			CAT_PRODUCT_AMOUNT_VAT_TXT.onchange = 
				function()
				{
					if(CAT_PRODUCT_AMOUNT_VAT_TXT.disabled == false)
					{
						EDIT_HANDLER.REF_IS_MODIFIED = true;
					}
				};
			CAT_PRODUCT_AMOUNT_VAT_TXT.onkeypress = function(){CAT_PRODUCT_AMOUNT_VAT_TXT.onchange();};
			CAT_PRODUCT_AMOUNT_VAT_TXT.onpaste = function(){CAT_PRODUCT_AMOUNT_VAT_TXT.onchange();};
			CAT_PRODUCT_AMOUNT_VAT_TXT.oninput = function(){CAT_PRODUCT_AMOUNT_VAT_TXT.onchange();};
		}
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("CAT_PRODUCT_AMOUNT_POINT_TXT"))
		{
			CAT_PRODUCT_AMOUNT_POINT_TXT = JSOC_ELEMENT.VAR_GET("CAT_PRODUCT_AMOUNT_POINT_TXT");      
			CAT_PRODUCT_AMOUNT_POINT_TXT.onchange = 
				function()
				{
					if(CAT_PRODUCT_AMOUNT_POINT_TXT.disabled == false)
					{
						EDIT_HANDLER.REF_IS_MODIFIED = true;
					}
				};
			CAT_PRODUCT_AMOUNT_POINT_TXT.onkeypress = function(){CAT_PRODUCT_AMOUNT_POINT_TXT.onchange();};
			CAT_PRODUCT_AMOUNT_POINT_TXT.onpaste = function(){CAT_PRODUCT_AMOUNT_POINT_TXT.onchange();};
			CAT_PRODUCT_AMOUNT_POINT_TXT.oninput = function(){CAT_PRODUCT_AMOUNT_POINT_TXT.onchange();};
		}
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("CAT_PRODUCT_ALLOW_DISCOUNT_CMB"))
		{
			CAT_PRODUCT_ALLOW_DISCOUNT_CMB = JSOC_ELEMENT.VAR_GET("CAT_PRODUCT_ALLOW_DISCOUNT_CMB");     
			CAT_PRODUCT_ALLOW_DISCOUNT_CMB.onchange = 
				function()
				{
					if(CAT_PRODUCT_ALLOW_DISCOUNT_CMB.disabled == false)
					{
						EDIT_HANDLER.REF_IS_MODIFIED = true;
					}
				};
			CAT_PRODUCT_ALLOW_DISCOUNT_CMB.onkeypress = function(){CAT_PRODUCT_ALLOW_DISCOUNT_CMB.onchange();};
			CAT_PRODUCT_ALLOW_DISCOUNT_CMB.onpaste = function(){CAT_PRODUCT_ALLOW_DISCOUNT_CMB.onchange();};
			CAT_PRODUCT_ALLOW_DISCOUNT_CMB.oninput = function(){CAT_PRODUCT_ALLOW_DISCOUNT_CMB.onchange();};						
		}
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("CAT_PRODUCT_ALLOW_SENIOR_CMB"))
		{
			CAT_PRODUCT_ALLOW_SENIOR_CMB = JSOC_ELEMENT.VAR_GET("CAT_PRODUCT_ALLOW_SENIOR_CMB");     
			CAT_PRODUCT_ALLOW_SENIOR_CMB.onchange = 
				function()
				{
					if(CAT_PRODUCT_ALLOW_SENIOR_CMB.disabled == false)
					{
						EDIT_HANDLER.REF_IS_MODIFIED = true;
					}
				};
			CAT_PRODUCT_ALLOW_SENIOR_CMB.onkeypress = function(){CAT_PRODUCT_ALLOW_SENIOR_CMB.onchange();};
			CAT_PRODUCT_ALLOW_SENIOR_CMB.onpaste = function(){CAT_PRODUCT_ALLOW_SENIOR_CMB.onchange();};
			CAT_PRODUCT_ALLOW_SENIOR_CMB.oninput = function(){CAT_PRODUCT_ALLOW_SENIOR_CMB.onchange();};						
		}
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("CAT_PRODUCT_IS_BASICCOM_CMB"))
		{
			CAT_PRODUCT_IS_BASICCOM_CMB = JSOC_ELEMENT.VAR_GET("CAT_PRODUCT_IS_BASICCOM_CMB");     
			CAT_PRODUCT_IS_BASICCOM_CMB.onchange = 
				function()
				{
					if(CAT_PRODUCT_IS_BASICCOM_CMB.disabled == false)
					{
						EDIT_HANDLER.REF_IS_MODIFIED = true;
					}
				};
			CAT_PRODUCT_IS_BASICCOM_CMB.onkeypress = function(){CAT_PRODUCT_IS_BASICCOM_CMB.onchange();};
			CAT_PRODUCT_IS_BASICCOM_CMB.onpaste = function(){CAT_PRODUCT_IS_BASICCOM_CMB.onchange();};
			CAT_PRODUCT_IS_BASICCOM_CMB.oninput = function(){CAT_PRODUCT_IS_BASICCOM_CMB.onchange();};						
		}
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("CAT_PRODUCT_IS_SERVICE_CMB"))
		{
			CAT_PRODUCT_IS_SERVICE_CMB = JSOC_ELEMENT.VAR_GET("CAT_PRODUCT_IS_SERVICE_CMB");     
			CAT_PRODUCT_IS_SERVICE_CMB.onchange = 
				function()
				{
					if(CAT_PRODUCT_IS_SERVICE_CMB.disabled == false)
					{
						EDIT_HANDLER.REF_IS_MODIFIED = true;
					}
				};
			CAT_PRODUCT_IS_SERVICE_CMB.onkeypress = function(){CAT_PRODUCT_IS_SERVICE_CMB.onchange();};
			CAT_PRODUCT_IS_SERVICE_CMB.onpaste = function(){CAT_PRODUCT_IS_SERVICE_CMB.onchange();};
			CAT_PRODUCT_IS_SERVICE_CMB.oninput = function(){CAT_PRODUCT_IS_SERVICE_CMB.onchange();};						
		}
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("CAT_PRODUCT_REORDER_POINT_TXT"))
		{
			CAT_PRODUCT_REORDER_POINT_TXT = JSOC_ELEMENT.VAR_GET("CAT_PRODUCT_REORDER_POINT_TXT");      
			CAT_PRODUCT_REORDER_POINT_TXT.onchange = 
				function()
				{
					if(CAT_PRODUCT_REORDER_POINT_TXT.disabled == false)
					{
						EDIT_HANDLER.REF_IS_MODIFIED = true;
					}
				};
			CAT_PRODUCT_REORDER_POINT_TXT.onkeypress = function(){CAT_PRODUCT_REORDER_POINT_TXT.onchange();};
			CAT_PRODUCT_REORDER_POINT_TXT.onpaste = function(){CAT_PRODUCT_REORDER_POINT_TXT.onchange();};
			CAT_PRODUCT_REORDER_POINT_TXT.oninput = function(){CAT_PRODUCT_REORDER_POINT_TXT.onchange();};
		}
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("CAT_PRODUCT_REORDER_QUANTITY_TXT"))
		{
			CAT_PRODUCT_REORDER_QUANTITY_TXT = JSOC_ELEMENT.VAR_GET("CAT_PRODUCT_REORDER_QUANTITY_TXT");      
			CAT_PRODUCT_REORDER_QUANTITY_TXT.onchange = 
				function()
				{
					if(CAT_PRODUCT_REORDER_QUANTITY_TXT.disabled == false)
					{
						EDIT_HANDLER.REF_IS_MODIFIED = true;
					}
				};
			CAT_PRODUCT_REORDER_QUANTITY_TXT.onkeypress = function(){CAT_PRODUCT_REORDER_QUANTITY_TXT.onchange();};
			CAT_PRODUCT_REORDER_QUANTITY_TXT.onpaste = function(){CAT_PRODUCT_REORDER_QUANTITY_TXT.onchange();};
			CAT_PRODUCT_REORDER_QUANTITY_TXT.oninput = function(){CAT_PRODUCT_REORDER_QUANTITY_TXT.onchange();};
		}
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("CAT_PRODUCT_CAT_PRODUCT_ID_CMB"))
		{
			CAT_PRODUCT_CAT_PRODUCT_ID_CMB = JSOC_ELEMENT.VAR_GET("CAT_PRODUCT_CAT_PRODUCT_ID_CMB");      	
			CAT_PRODUCT_CAT_PRODUCT_ID_CMB.onchange = 
				function()
				{
					if(CAT_PRODUCT_CAT_PRODUCT_ID_CMB.disabled == false)
					{
						EDIT_HANDLER.REF_IS_MODIFIED = true;
					}
				};
			CAT_PRODUCT_CAT_PRODUCT_ID_CMB.onkeypress = function(){CAT_PRODUCT_CAT_PRODUCT_ID_CMB.onchange();};
			CAT_PRODUCT_CAT_PRODUCT_ID_CMB.onpaste = function(){CAT_PRODUCT_CAT_PRODUCT_ID_CMB.onchange();};
			CAT_PRODUCT_CAT_PRODUCT_ID_CMB.oninput = function(){CAT_PRODUCT_CAT_PRODUCT_ID_CMB.onchange();};							
		}
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("CAT_PRODUCT_PER_PIECE_QTY_TXT"))
		{
			CAT_PRODUCT_PER_PIECE_QTY_TXT = JSOC_ELEMENT.VAR_GET("CAT_PRODUCT_PER_PIECE_QTY_TXT");      
			CAT_PRODUCT_PER_PIECE_QTY_TXT.onchange = 
				function()
				{
					if(CAT_PRODUCT_PER_PIECE_QTY_TXT.disabled == false)
					{
						EDIT_HANDLER.REF_IS_MODIFIED = true;
					}
				};
			CAT_PRODUCT_PER_PIECE_QTY_TXT.onkeypress = function(){CAT_PRODUCT_PER_PIECE_QTY_TXT.onchange();};
			CAT_PRODUCT_PER_PIECE_QTY_TXT.onpaste = function(){CAT_PRODUCT_PER_PIECE_QTY_TXT.onchange();};
			CAT_PRODUCT_PER_PIECE_QTY_TXT.oninput = function(){CAT_PRODUCT_PER_PIECE_QTY_TXT.onchange();};
		}
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("CAT_PRODUCT_CAT_SUPPLIER_ID_CMB"))
		{
			CAT_PRODUCT_CAT_SUPPLIER_ID_CMB = JSOC_ELEMENT.VAR_GET("CAT_PRODUCT_CAT_SUPPLIER_ID_CMB");      	
			CAT_PRODUCT_CAT_SUPPLIER_ID_CMB.onchange = 
				function()
				{
					if(CAT_PRODUCT_CAT_SUPPLIER_ID_CMB.disabled == false)
					{
						EDIT_HANDLER.REF_IS_MODIFIED = true;
					}
				};
			CAT_PRODUCT_CAT_SUPPLIER_ID_CMB.onkeypress = function(){CAT_PRODUCT_CAT_SUPPLIER_ID_CMB.onchange();};
			CAT_PRODUCT_CAT_SUPPLIER_ID_CMB.onpaste = function(){CAT_PRODUCT_CAT_SUPPLIER_ID_CMB.onchange();};
			CAT_PRODUCT_CAT_SUPPLIER_ID_CMB.oninput = function(){CAT_PRODUCT_CAT_SUPPLIER_ID_CMB.onchange();};							
		}
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("CAT_PRODUCT_IS_INVENTORY_ONLY_TXT"))
		{
			CAT_PRODUCT_IS_INVENTORY_ONLY_TXT = JSOC_ELEMENT.VAR_GET("CAT_PRODUCT_IS_INVENTORY_ONLY_TXT");      
			CAT_PRODUCT_IS_INVENTORY_ONLY_TXT.onchange = 
				function()
				{
					if(CAT_PRODUCT_IS_INVENTORY_ONLY_TXT.disabled == false)
					{
						EDIT_HANDLER.REF_IS_MODIFIED = true;
					}
				};
			CAT_PRODUCT_IS_INVENTORY_ONLY_TXT.onkeypress = function(){CAT_PRODUCT_IS_INVENTORY_ONLY_TXT.onchange();};
			CAT_PRODUCT_IS_INVENTORY_ONLY_TXT.onpaste = function(){CAT_PRODUCT_IS_INVENTORY_ONLY_TXT.onchange();};
			CAT_PRODUCT_IS_INVENTORY_ONLY_TXT.oninput = function(){CAT_PRODUCT_IS_INVENTORY_ONLY_TXT.onchange();};
		}
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("CAT_PRODUCT_IS_SERIALIZED_CMB"))
		{
			CAT_PRODUCT_IS_SERIALIZED_CMB = JSOC_ELEMENT.VAR_GET("CAT_PRODUCT_IS_SERIALIZED_CMB");     
			CAT_PRODUCT_IS_SERIALIZED_CMB.onchange = 
				function()
				{
					if(CAT_PRODUCT_IS_SERIALIZED_CMB.disabled == false)
					{
						EDIT_HANDLER.REF_IS_MODIFIED = true;
					}
				};
			CAT_PRODUCT_IS_SERIALIZED_CMB.onkeypress = function(){CAT_PRODUCT_IS_SERIALIZED_CMB.onchange();};
			CAT_PRODUCT_IS_SERIALIZED_CMB.onpaste = function(){CAT_PRODUCT_IS_SERIALIZED_CMB.onchange();};
			CAT_PRODUCT_IS_SERIALIZED_CMB.oninput = function(){CAT_PRODUCT_IS_SERIALIZED_CMB.onchange();};						
		}
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("CAT_PRODUCT_STATUS_CMB"))
		{
			CAT_PRODUCT_STATUS_CMB = JSOC_ELEMENT.VAR_GET("CAT_PRODUCT_STATUS_CMB");      	
			CAT_PRODUCT_STATUS_CMB.onchange = 
				function()
				{
					if(CAT_PRODUCT_STATUS_CMB.disabled == false)
					{
						EDIT_HANDLER.REF_IS_MODIFIED = true;
					}
				};
			CAT_PRODUCT_STATUS_CMB.onkeypress = function(){CAT_PRODUCT_STATUS_CMB.onchange();};
			CAT_PRODUCT_STATUS_CMB.onpaste = function(){CAT_PRODUCT_STATUS_CMB.onchange();};
			CAT_PRODUCT_STATUS_CMB.oninput = function(){CAT_PRODUCT_STATUS_CMB.onchange();};							
		}
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("CAT_PRODUCT_SYSTEM_GENERATED_TXT"))
		{
			CAT_PRODUCT_SYSTEM_GENERATED_TXT = JSOC_ELEMENT.VAR_GET("CAT_PRODUCT_SYSTEM_GENERATED_TXT");      
			CAT_PRODUCT_SYSTEM_GENERATED_TXT.onchange = 
				function()
				{
					if(CAT_PRODUCT_SYSTEM_GENERATED_TXT.disabled == false)
					{
						EDIT_HANDLER.REF_IS_MODIFIED = true;
					}
				};
			CAT_PRODUCT_SYSTEM_GENERATED_TXT.onkeypress = function(){CAT_PRODUCT_SYSTEM_GENERATED_TXT.onchange();};
			CAT_PRODUCT_SYSTEM_GENERATED_TXT.onpaste = function(){CAT_PRODUCT_SYSTEM_GENERATED_TXT.onchange();};
			CAT_PRODUCT_SYSTEM_GENERATED_TXT.oninput = function(){CAT_PRODUCT_SYSTEM_GENERATED_TXT.onchange();};
		}
		if(JSOC_ELEMENT.VAR_ELEMENT_EXISTS("PARAM_CAT_PRODUCT_ID_FILE_FP"))
		{
			PARAM_CAT_PRODUCT_ID_FILE_FP = JSOC_ELEMENT.VAR_GET("PARAM_CAT_PRODUCT_ID_FILE_FP");
			PARAM_CAT_PRODUCT_ID_FILE_FP.onchange = 
				function()
				{
					if(PARAM_CAT_PRODUCT_ID_FILE_FP.disabled == false)
					{
						EDIT_HANDLER.REF_IS_MODIFIED = true;
					}
				};
		}
				
		
		// Initialize: Default Settings
		// ...........................................
		// FORM_PREPARE_DEFAULT_SETTINGS();   	
	}