57 lines
No EOL
1.6 KiB
C#
57 lines
No EOL
1.6 KiB
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Data;
|
|
using System.Linq;
|
|
using System.Web;
|
|
using System.Web.UI;
|
|
using System.Web.UI.WebControls;
|
|
using System.Web.UI.HtmlControls;
|
|
|
|
using AyABL;
|
|
using AyAEL.ADM;
|
|
|
|
using AyADAL;
|
|
using AyABL.RCS;
|
|
using AyABL.ADM;
|
|
using AyABL.AGP;
|
|
using System.Web.Script.Serialization;
|
|
using System.Web.Services;
|
|
|
|
public partial class Prueba : General
|
|
{
|
|
|
|
UbicacionBL objUbicacionBL;
|
|
JavaScriptSerializer _Json = new JavaScriptSerializer();
|
|
|
|
protected void Page_Load(object sender, EventArgs e)
|
|
{
|
|
|
|
}
|
|
|
|
private string llenarDDLProvincias() //M
|
|
{
|
|
List<UbicacionEL> lstInfoProvincias = new List<UbicacionEL>();
|
|
try
|
|
{
|
|
//Instancia el objeto
|
|
objUbicacionBL = new UbicacionBL();
|
|
objUbicacionBL.objUbicacionEL.PK = 0;
|
|
objUbicacionBL.objUbicacionEL.Padre = -1;
|
|
objUbicacionBL.objUbicacionEL.ASTATE = true;
|
|
DataSet dsProvincia = objUbicacionBL.getUbicacion();
|
|
|
|
foreach (DataRow drProvincia in dsProvincia.Tables[0].Rows)
|
|
{
|
|
var infoProvincia = new UbicacionEL { PK = int.Parse(drProvincia["PKUBICACION"].ToString()), Nombre = drProvincia["NOMBREUBICACION"].ToString() };
|
|
|
|
lstInfoProvincias.Add(infoProvincia);
|
|
}
|
|
}
|
|
catch (Exception ex)
|
|
{
|
|
MensajeError("Error en R6M", ex);
|
|
}
|
|
|
|
return _Json.Serialize(lstInfoProvincias);
|
|
}
|
|
} |