60 lines
1.9 KiB
C#
60 lines
1.9 KiB
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Web;
|
|
|
|
|
|
namespace XPS_data
|
|
{
|
|
/// <summary>
|
|
/// Summary description for extSync
|
|
/// </summary>
|
|
public class extSync
|
|
{
|
|
#region area tableAdapter
|
|
|
|
DS_importTableAdapters.aclTableAdapter taACL_orig;
|
|
DS_applicazioneTableAdapters.AnagClientiTableAdapter taAnagCli;
|
|
|
|
private void caricaTA()
|
|
{
|
|
taAnagCli = new DS_applicazioneTableAdapters.AnagClientiTableAdapter();
|
|
taACL_orig = new DS_importTableAdapters.aclTableAdapter();
|
|
}
|
|
|
|
#endregion
|
|
|
|
protected extSync()
|
|
{
|
|
// avvio tableAdapters
|
|
caricaTA();
|
|
}
|
|
|
|
public static extSync obj = new extSync();
|
|
|
|
/// <summary>
|
|
///
|
|
/// </summary>
|
|
/// <returns></returns>
|
|
public string caricaClienti()
|
|
{
|
|
// inizializzo stringa output
|
|
string ragSocNotImp = "<b>...sync completato!</b><br /><br>";
|
|
string esito = "";
|
|
// chiamo stored x caricare anag clienti + email
|
|
SteamWare.logger.lg.scriviLog("Richiesto refresh dati anagrafiche", SteamWare.tipoLog.INFO);
|
|
try
|
|
{
|
|
XPS_data.DS_XPSTableAdapters.SP taSP = new XPS_data.DS_XPSTableAdapters.SP();
|
|
taSP.stp_CaricaAnagCliSwing(ref esito);
|
|
SteamWare.logger.lg.scriviLog(string.Format("Effettuato caricamento dati anagrafiche, esito: {0}{1}", Environment.NewLine, esito), SteamWare.tipoLog.INFO);
|
|
}
|
|
catch (Exception exc)
|
|
{
|
|
SteamWare.logger.lg.scriviLog(string.Format("Errore in caricamento dati anagrafiche: {0}{1}", Environment.NewLine, exc), SteamWare.tipoLog.INFO);
|
|
}
|
|
ragSocNotImp += esito;
|
|
// return messaggio
|
|
return ragSocNotImp;
|
|
}
|
|
}
|
|
} |