good day everyone!

i have a problem...

i have 27 text files in a folder named dito... and every minute there will be new text file in a folder...

i need to create a program that saves a record locator(9-digit-code)...

the rule is that there will be no human interactions..

once the program is opened,,, it will automatically open the text files one by one in the folder named dito and save the 9-digit-code(record locator) which is located in line 4 beside MUC1A(note: this is a consistent data... all of the text files that will go in the folder will contain this MUC1A data..)

then it will automatically save the 9-digit-code in the database and move the textfile to another folder name trash and delete its copy in the folder named dito...

it should be a continues process that will not stop unless the folder named dito will no longer receive a textfile

who can help me? please my deadline is tomorrow and i'm new in c sharp programming and in using 3.5 windows application

here's the code that i started but it's not yet finish

my code just open a single textfile and show the 9 digit code in a label1.text

using System;
using System.IO;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using ftl.DataSet1TableAdapters;

namespace ftl
    public partial class Form1 : Form
        ReLocTableAdapter rs = new ReLocTableAdapter();
        public Form1()

        private void Form1_Load(object sender, EventArgs e)
            string file_name = "C:\\dito\\AIR41391.txt";

            if (System.IO.File.Exists(file_name) == true)

                System.IO.StreamReader objReader;
                objReader = new System.IO.StreamReader(file_name);

                textBox1.Text = objReader.ReadToEnd();


            string str = textBox1.Text;
            string retString = "MUC1A";
            str = textBox1.Text;
            retString = str.Substring(111,9);
            label1.Text= retString;




This article has been dead for over six months. Start a new discussion instead.