// ----------------------------------------------------------- // Define global Variables // ----------------------------------------------------------- var hugmarSettings = {}; // Hugmar Server Settings var hjsonEditResponse = {}; // JSON Edit Field Response var hjsonBrowser = new Object(); // JSON Browser Info var hjsonGridColStr = null; // JSON Grid Columns String var hjsonGridCol = []; // JSON Grid Columns JS var hjsonViewCtl = null; // JSON View Specs var hjsonCol = {}; // JSON Column Specs var hjsonColDndItem = {}; // JSON Column Dnd Item // ----------------------------------------------------------- // Replace Special Characters in Datacell // ----------------------------------------------------------- function globalModifyCell(cellValue) { var newValue = cellValue; if (typeof newValue != "string") { return newValue; } // Special Characters newValue = newValue.replace(/!/g, "x33y;"); // x33y replaces exclamation mark newValue = newValue.replace(/"/g, "x34y;"); // x34y replaces double quote newValue = newValue.replace(/#/g, "x35y;"); // x35y replaces number sign // x36y omitted dollar sign newValue = newValue.replace(/%/g, "x37y;"); // x37y replaces percent symbol newValue = newValue.replace(/&/g, "x38y;"); // x38y replaces ampersand newValue = newValue.replace(/'/g, "x39y;"); // x39y replaces single quotes // x40y omitted opening parenthesis // x41y omitted closing parenthesis // x42y omitted asterisk // x43y omitted plus sign newValue = newValue.replace(/,/g, "x44y;"); // x44y replaces commas newValue = newValue.replace(/-/g, "x45y;"); // x45y replaces minus/hyphen // x46y omit period // x47y omitted forward slash newValue = newValue.replace(/�/g, "x62y;"); // x62y replaces � like degrees newValue = newValue.replace(/@/g, "x64y;"); // x64y replaces at symbol // x91y omitted opening bracket // x92y omitted backslash // x93y omitted closing bracket newValue = newValue.replace(/_/g, "x95y;"); // x95y replaces underscore newValue = newValue.replace(/{/g, "x123y;");// x123y replaces opening brace // x124y omitted vertical bar newValue = newValue.replace(/}/g, "x125y;");// x125y replaces closing brace return newValue; }