Exemple #1
0
    public static SqlString ufnSelectHL7Value(string HL7Message, String HL7Location)
    {
        ParseAndScrub myParserScubber = new ParseAndScrub(Convert.ToChar("."), Convert.ToChar("#"));

        myParserScubber.LoadMessage(HL7Message);
        String returnValue;

        returnValue = "";
        System.Collections.Generic.List <String> Values = myParserScubber.FindParseValue(HL7Location);
        foreach (string v in Values)
        {
            if (returnValue == "")
            {
                returnValue = v;
            }
            else
            {
                returnValue = returnValue + ", " + v;
            }
        }
        return(returnValue);
    }
Exemple #2
0
        private void button1_Click(object sender, EventArgs e)
        {
            txtParsedValue.Text = "";
            List <String> Values = new List <string>();

            //LightWeightParser parser = new LightWeightParser(txtHL7Message.Text);

            //   if (parser.FindValue(txtLocation.Text))
            //{
            //    Values = parser.ParsedValue;
            //}
            Values = myParserScubber.FindParseValue(txtLocation.Text);
            foreach (string v in Values)
            {
                if (txtParsedValue.Text == "")
                {
                    txtParsedValue.Text = v;
                }
                else
                {
                    txtParsedValue.Text = txtParsedValue.Text + ", " + v;
                }
            }
        }