public String Pedidos_CQ_Instant() { SessionClass session = new SessionClass(); session.UserLogon("admin", "admin", "PRESU", 2, "BPD_DESA"); OAdQuerydef queryDef = (OAdQuerydef)session.BuildQuery("Pedido_Pago"); queryDef.BuildField("id"); queryDef.BuildField("Importe_Total"); OAdResultset resultset = (OAdResultset)session.BuildResultSet(queryDef); resultset.Execute(); var Status = resultset.MoveNext(); String data = ""; while (Convert.ToInt32(Status) == 1) { data = (String)resultset.GetColumnValue(2); Status = resultset.MoveNext(); } return(data); }
public ArrayList Pedidos_CQ() { SessionClass session = new SessionClass(); session.UserLogon("admin", "admin", "PRESU", 2, "BPD_DESA"); OAdQuerydef queryDef = (OAdQuerydef)session.BuildQuery("Pedido_Pago"); queryDef.BuildField("id"); queryDef.BuildField("Importe_Total"); OAdResultset resultset = (OAdResultset)session.BuildResultSet(queryDef); ArrayList PedidosdePagos = new ArrayList(); resultset.Execute(); var Status = resultset.MoveNext(); while (Convert.ToInt32(Status) == 1) { Pedido_Pago data = new Pedido_Pago(); data.id_pedido = (String)resultset.GetColumnValue(1); data.importe_total = (String)resultset.GetColumnValue(2); PedidosdePagos.Add(data); Status = resultset.MoveNext(); } return(PedidosdePagos); }
internal static int ResultSetMoveNext(OAdResultset resultSet) { int retval = 0; try { retval = resultSet.MoveNext(); } catch (COMException ex) { InteropErrorHandler.HandleCQException(ex); } return(retval); }