gov.va.medora.mdws.LabsLib.getSurgicalPathologyReports C# (CSharp) Method

getSurgicalPathologyReports() public method

public getSurgicalPathologyReports ( string fromDate, string toDate, int nrpts ) : TaggedSurgicalPathologyRptArrays
fromDate string
toDate string
nrpts int
return gov.va.medora.mdws.dto.TaggedSurgicalPathologyRptArrays
        public TaggedSurgicalPathologyRptArrays getSurgicalPathologyReports(string fromDate, string toDate, int nrpts)
        {
            TaggedSurgicalPathologyRptArrays result = new TaggedSurgicalPathologyRptArrays();

            if (!mySession.ConnectionSet.IsAuthorized)
            {
                result.fault = new FaultTO("Connections not ready for operation", "Need to login?");
            }
            else if (fromDate == "")
            {
                result.fault = new FaultTO("Missing fromDate");
            }
            else if (toDate == "")
            {
                result.fault = new FaultTO("Missing toDate");
            }
            if (result.fault != null)
            {
                return result;
            }

            try
            {
                LabsApi api = new LabsApi();
                IndexedHashtable t = api.getSurgicalPathologyReports(mySession.ConnectionSet, fromDate, toDate, nrpts);
                result = new TaggedSurgicalPathologyRptArrays(t);
            }
            catch (Exception e)
            {
                result.fault = new FaultTO(e);
            }
            return result;
        }