DMT stands for Data Management Tool.
Basically, it is a tool which allows the import of information into Epicor in the form of a text file.
We really only use DMT when first setting up a new Epicor implementation. The thing about DMT is, it is limited.
For some tables, you still must populate the data manually, or write custom code to populate it for you.
Here are some of the tables we populate using C# and .dll files in the Epicor Software/Client folder:
SalesRep, SalesTerritory, RefCategory, AnalysisCode
In you project, add references to:
- Epicor.Mfg.Common.BOExceptions
- Epicor.Mfg.Core.BLConnectionPool
- Epicor.MFG.Core.CallContext
- Epicor.Mfg.UI.EpiClientLib
- Epicor.Mfg.Lib.ISessionMod
- Epicor.Mfg.Lib.SessionMod
And then, for the business objects you want to use, add two references like this:
- Epicor.Mfg.BO.(business object name)
- Epcior.Mfg.IF.I(business object name)
Here is some sample code on how you can connect directly to Epicor:
public BOFactory(string company)
{
this.company = company;
string user = "manager";
string password = "manager";
m_cnVantage = new BLConnectionPool(user, password, "AppServerDC://"
+ ConfigurationSettings.AppSettings[m_strKeyVantageServer] + ":"
+ ConfigurationSettings.AppSettings[m_strKeyVantagePort]);
}
public Epicor.Mfg.BO.SalesTer GetSalesTerBO()
{
Epicor.Mfg.BO.SalesTer saleTer = new Epicor.Mfg.BO.SalesTer(m_cnVantage);
return saleTer;
}
And then, once you have your business object:
dataSet = new SalesTerDataSet();
salesTer.GetNewSalesTer(dataSet);
...
salesTer.Update(dataSet);
Also note that you can change the company you working with using this code:
public void SetCompany(string company)
{
this.company = company;
Epicor.Mfg.Lib.SessionMod sessionMod = new Epicor.Mfg.Lib.SessionMod(m_cnVantage);
sessionMod.SetCompany(company,
out companyName, out plantID, out plantName, out workstationID, out workstationDescription,
out employeeID, out countryGroupCode, out countryCode);
}