Ejemplo n.º 1
0
		///<summary>Constructs the ObjFormEhrMeasures fro use with late binding.</summary>
		private static void constructObjFormEhrMeasuresHelper() {
			string dllPathEHR=ODFileUtils.CombinePaths(Application.StartupPath,"EHR.dll");
			ObjFormEhrMeasures=null;
			AssemblyEHR=null;
			if(File.Exists(dllPathEHR)) {//EHR.dll is available, so load it up
				AssemblyEHR=Assembly.LoadFile(dllPathEHR);
				Type type=AssemblyEHR.GetType("EHR.FormEhrMeasures");//namespace.class
				ObjFormEhrMeasures=Activator.CreateInstance(type);
				return;
			}
			#if EHRTEST
				ObjFormEhrMeasures=new FormEhrMeasures();
			#endif
		}
Ejemplo n.º 2
0
 public static bool QuarterlyKeyIsValid(string year, string quarter, string practiceTitle, string qkey)
 {
     try{
                         #if EHRTEST //This pattern allows the code to compile without having the EHR code available.
         return(FormEhrMeasures.QuarterlyKeyIsValid(year, quarter, practiceTitle, qkey));
                         #else
         constructObjFormEhrMeasuresHelper();
         Type     type = AssemblyEHR.GetType("EHR.FormEhrMeasures");                  //namespace.class
         object[] args = new object[] { year, quarter, practiceTitle, qkey };
         return((bool)type.InvokeMember("QuarterlyKeyIsValid", System.Reflection.BindingFlags.InvokeMethod, null, ObjFormEhrMeasures, args));
                         #endif
     }
     catch {
         return(false);
     }
 }
Ejemplo n.º 3
0
 public static bool ProvKeyIsValid(string lName, string fName, bool hasReportAccess, string provKey)
 {
     try{
                         #if EHRTEST //This pattern allows the code to compile without having the EHR code available.
         return(FormEhrMeasures.ProvKeyIsValid(lName, fName, hasReportAccess, provKey));
                         #else
         constructObjFormEhrMeasuresHelper();
         Type     type = AssemblyEHR.GetType("EHR.FormEhrMeasures");                  //namespace.class
         object[] args = new object[] { lName, fName, hasReportAccess, provKey };
         return((bool)type.InvokeMember("ProvKeyIsValid", System.Reflection.BindingFlags.InvokeMethod, null, ObjFormEhrMeasures, args));
                         #endif
     }
     catch {
         return(false);
     }
 }