Keresés

Új hozzászólás Aktív témák

  • James Bond

    csendes tag

    válasz amargo #2842 üzenetére

    Köszi a választ, jó lett a satic-al.

    public static class GlobalVar
    {
    public static string GlobalString = "gfdgdsg";
    static int[] szelvenyev = new int[5000];
    static int[] szelvenyhet = new int[5000];
    static int[] szelvenyszam1 = new int[5000];
    static int[] szelvenyszam2 = new int[5000];
    static int[] szelvenyszam3 = new int[5000];
    static int[] szelvenyszam4 = new int[5000];
    static int[] szelvenyszam5 = new int[5000];

    static int szamindex;
    public static int Szamindex
    {
    get
    {
    return szamindex;
    }
    set
    {
    szamindex = value;
    }
    }

    Még egy kérdésem lenne:

    public Form1()
    {
    GlobalVar.Szamindex = 50;

    FileStream fs = new FileStream("Otos.txt", FileMode.Open);
    StreamReader sr = new StreamReader(fs);
    string s = "";

    while (s != null)
    {

    s=sr.ReadLine();

    }

    sr.Close();
    fs.Close();

    Az Otos.txt- fájl ban Tabulátorokkal vannak elválasztva a szamok.

    Nekem olyan kéne, hogy a beolvasott sort feldarabolja. s=sr.ReadLine();

Új hozzászólás Aktív témák