A blog on Tally Integration, to import and export data from Tally.ERP programmatically using VB6, VB.NET,C#,ASP.NET etc

Friday, April 20, 2007

Analyzing the Tally Server Response

RTSLINK DLL

This article describes how to read the Tally Server Response after a XML request is sent using the Send() function. To begin with, let us see the C language declaration of the Send() function.

C language declaration of the Send() function
int __stdcall Send(message);

Remarks:-
  1. The send function returns an Integer value (Zero for success, otherwise the error-code).
  2. If the return value is Zero, it implies that the XML request has been successfully sent to the Tally server.

Analysing the Tally Server Response
As mentioned above, if the Send() function returns 0 (Zero), it implies that the XML Request has been successfully sent to the Tally Server. The XML requested can be either reading or writing data to the Tally' database. Example of XML Request:-
  1. Export (read) any report data (Trial balance, Ledger etc.)
  2. Import (write) any master or voucher data to Tally's database
On receiving the XML Request message, the Tally Server processes it and then delivers a response/result which can be retrieved using the ResponseText() function which is described later on. Example:-
  1. If you had requested for any Report, the Tally Server response will contain the Report data.
  2. If you had requested for writing data to Tally's database, the Tally Server response will contain details whether a new records is created; or altered or deleted.
In the later case, when the XML request is to write to Tally's database, it becomes essential to analyze the Tally Server response and check for errors. For this the ResponseText() function is to be used. The ResponseText() function retrieves the Tally Server response and returns it in a string.

C language declaration of ResponseText() function
LPSTR __stdcall ResponseText(void);

You can either display the response message in a Message-Box or parse it using XML DOM. Use the following VB code to parse the response message and check if any errors are there or not.

Sample VB code
Set ChildNodes = XMLDOM.SelectNodes("/RESPONSE/LINEERROR")
if (ChildNodes.Length > 0) then
MsgBox "Tally write error"
else
MsgBox "Success"
end if

For more information about using XML DOM, please refer the topic "Using XML DOM" in "RTSlink - An Insight" document which can be downloaded from www.rtslink.com/downloads.html


Shweta Computers
www.rtslink.com

Tuesday, April 17, 2007

Creating customized Tally Reports - MyDaybook v1.3

MyDaybook version 1.3  supercedes the older version 1.2.

The new features in MyDaybook version 1.3 are as follows:-
1) Allows you to Delete multiple Voucher entries

Click here  for more information on MyDaybook v1.3.

Monday, April 16, 2007

Tally Customization - Linking Sales Voucher module with Tally Software

Tally Customization - How to link Sales Voucher entry module with Tally Accounting Software ?

Click here for more information.

Tuesday, April 10, 2007

Linking Receipt Voucher entry module with Tally

Click here for more information on linking the Receipt module of your software with Tally.