public TaggedText getPcpForPatient(string pid)
{
TaggedText result = new TaggedText();
string msg = MdwsUtils.isAuthorizedConnection(mySession);
if (msg != "OK")
{
result.fault = new FaultTO(msg);
}
else if (String.IsNullOrEmpty(pid))
{
result.fault = new FaultTO("Empty PID");
}
if (result.fault != null)
{
return result;
}
try
{
KeyValuePair<string, string> kvp = Patient.getPcpForPatient(mySession.ConnectionSet.BaseConnection, pid);
result = new TaggedText(kvp);
}
catch (Exception exc)
{
result.fault = new FaultTO(exc);
}
return result;
}