Changeset 1514 for Scheduling/trunk/cs/bsdx0200GUISourceCode
- Timestamp:
- Aug 9, 2012, 6:21:39 PM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
Scheduling/trunk/cs/bsdx0200GUISourceCode/CGDocument.cs
r1174 r1514 961 961 string sLen = sp.TotalMinutes.ToString(); 962 962 string sPatID = rApptInfo.PatientID.ToString(); 963 string sNote = rApptInfo.Note;963 string sNote = stripC30C31(rApptInfo.Note); 964 964 string sResource = rApptInfo.Resource; 965 965 … … 1004 1004 } 1005 1005 1006 /// <summary> 1007 /// Replaces ascii 30 and 31 as they are used as delimiters. Funny users can crash the program. 1008 /// </summary> 1009 /// <param name="s">Input String</param> 1010 /// <returns>Output Stripped String</returns> 1011 public string stripC30C31(string s) 1012 { 1013 if (s != null && s.Length > 0) 1014 { 1015 System.Text.StringBuilder sb = new System.Text.StringBuilder(s.Length); 1016 foreach (char c in s) 1017 { 1018 sb.Append(((c==30)||(c==31)) ? ' ' : c); 1019 } 1020 s = sb.ToString(); 1021 } 1022 1023 return s; 1024 } 1025 1006 1026 public void EditAppointment(CGAppointment pAppt, string sNote) 1007 1027 { … … 1009 1029 { 1010 1030 int nApptID = pAppt.AppointmentKey; 1011 string sSql = "BSDX EDIT APPOINTMENT^" + nApptID.ToString() + "^" + s Note;1031 string sSql = "BSDX EDIT APPOINTMENT^" + nApptID.ToString() + "^" + stripC30C31(sNote); 1012 1032 1013 1033 System.Data.DataTable dtAppt = m_DocManager.RPMSDataTable(sSql, "EditAppointment");
Note:
See TracChangeset
for help on using the changeset viewer.