예제 #1
0
 //Formatting
 private void frmt(string gtdat)
 {
     try
     {
         int indx    = 0;
         int frntend = 0;
         int endend  = 0;
         foreach (char cnt in gtdat)
         {
             if (gtdat[indx] + gtdat[indx + 1] + gtdat[indx + 2] + gtdat[indx + 3] == 'P' + 'R' + 'T' + '>')
             {
                 frntend = indx;
             }
             else if (gtdat[indx] + gtdat[indx + 1] + gtdat[indx + 2] + gtdat[indx + 3] == '<' + 'P' + 'R' + 'T')
             {
                 endend = indx;
                 Main.Am_err mert = new Main.Am_err();
                 stfrmt(frntend, endend, gtdat);
             }
             indx++;
         }
     }
     catch (Exception exctrll)
     {
     }
 }
예제 #2
0
        public string amdsrder()
        {
            string gret = "";

            try
            {
                string       red   = "";
                FileStream   fsrde = new FileStream(Main.Properties.Settings.Default.Serverloc, FileMode.Open, FileAccess.Read);
                StreamReader srde  = new StreamReader(fsrde);
                red = srde.ReadToEnd();
                fsrde.Flush();
                srde.Close();
                fsrde.Close();
                return(red);
            }
            catch (Exception excnofl)
            {
                Main.Am_err mer = new Main.Am_err();
                mer.tx(excnofl.Message.ToString());
            }
            return(gret);
        }