3
Answers

connect with tally

Photo of Shyja Abraham

Shyja Abraham

13y
7.7k
1

    hai,

     how to connect with tally in C#.net, and how to Export data from windows form controls to tally?
is it possible? plz help?

Answers (3)

0
Photo of Vulpes
NA 98.3k 1.5m 12y
Assuming there's only one GUID in each file or it's just the first one you need to match, then this is easily done using a regular expression.

Here's some sample code:

using System;
using System.IO;
using System.Text.RegularExpressions;

class Test
{
   static void Main()
   {
      string regExp = 
      @"(?i)\b" +
      @"[0-9A-F]{8}-" +
      @"[0-9A-F]{4}-" +
      @"[0-9A-F]{4}-" +
      @"[0-9A-F]{4}-" +
      @"[0-9A-F]{12}" +
      @"\b";

      string text = File.ReadAllText("darma.xml");
      string guid = Regex.Match(text, regExp).Value;
      Console.WriteLine(guid);

      string text2 = File.ReadAllText("darma.ini");
      string guid2 = Regex.Match(text2, regExp).Value;
      Console.WriteLine(guid2);

      if (guid == guid2)
         Console.WriteLine("Files are the same");
      else
         Console.WriteLine("Files are not the same");
      Console.ReadKey();
   }
 
 


Accepted
0
Photo of darma teja
NA 493 194.3k 12y
Wonderful!!!

Thanks allot!!!