https://help.tallysolutions.com/docs/td9rel54/auth_lib/get_company_name_corresponding_to_the_connect_name.htm

Get Company Name Corresponding to the Connect Name

You can send an XML request to get the company name in Tally.ERP 9 to correspond to the selected connect name.

To get the desired connect name

Send the request to <TRBURL> received in response to TPGETCOMPANIES (described in 7.1), corresponding to the selected company connect name.

Retain the Tally company name for further use.

The XML request to get the company name in Tally.ERP 9, corresponding to the selected connect name is:

HTTP Headers

ID : GetCompanyName

SOURCE: <Partner Source Name>

TARGETACCOUNTINTERNALID: <ACCOUNTINTERNALID>

TARGETCOMPANYNAME: <COMPANYCONNECTNAME>

TARGET: TALLY

CONTENT-TYPE:text/xml;charset=<utf-16> or <utf-8>

XML Message

<ENVELOPE>

<HEADER>

<VERSION>1</VERSION>

<TALLYREQUEST>Export</TALLYREQUEST>

<TYPE>DATA</TYPE>

<ID>GetCompanyName</ID>

<TOKEN></TOKEN>

<SESSIONID></SESSIONID>

</HEADER>

<BODY>

<DESC>

<STATICVARIABLES>

<SVCOMPANYCONNECTNAME>

{Company Connect Name}

</SVCOMPANYCONNECTNAME>

</STATICVARIABLES>

</DESC>

</BODY>

</ENVELOPE>

I n the XML request, fetch the Tally company name corresponding to the required connect name. This is done, so that further XML data requests can contain the Tally company name within the <SVCURRENTCOMPANY> tag.

The XML response with the Tally company name is:

<ENVELOPE>

<HEADER>

<VERSION>1</VERSION>

<STATUS>1</STATUS>

</HEADER>

<BODY>

<DATA>

<SERVERCOMPANYNAME>

{Company Name}

</SERVERCOMPANYNAME>

</DATA>

</BODY>

</ENVELOPE>

I n the above XML response, the <SERVERCOMPANYNAME> holds the company name in Tally.ERP 9.