public bool Verify_Sub_Conditions_Equals(String id, int c, String t, Tabla tmp_t) { bool temp = false; List <Entity_Table> ls = tmp_t.getList(); for (int i = 0; i < ls.Count; i++) { Entity_Table entity_t = ls.ElementAt(i); if (entity_t.getEntity().ToUpper() == id.ToUpper()) { ArrayList ar = entity_t.getDataArray(); for (int j = 0; j < ar.Count; j++) { if (contadorVerify != 0) { if (t == ar[position_D].ToString()) { return(temp = true); } else { return(temp = false); } } else { if (c == 9) { if (t == ar[j].ToString()) { position_D = j; contadorVerify++; return(temp = true); } } } } break; } } return(temp); }
public void ImprimirTablas() { String html_Content; String Cabezera_Html; String Title_Table = ""; String Content_Celda = ""; String Content_Table = ""; Cabezera_Html = "<html>" + "<link rel=\"stylesheet\" type=\"text/css\" href=\"bootstrap.css\">" + "<body>"; for (int i = 0; i < TableList.Count; i++) { String Columns_Table = ""; Tabla t = TableList.ElementAt(i); Title_Table = "</br>" + "<h2 align='center'>" + "Tabla" + " " + t.getName() + "</h2></br>" + "<table cellpadding='10' border = '1' align='center'>"; for (int j = 0; j < t.getList().Count; j++) { Entity_Table ts = t.getList().ElementAt(j); Columns_Table += "<td><strong>" + ts.getEntity() + "</strong></td>"; } if (t.getList() != null) { Content_Celda = tx(t); } Content_Table += Title_Table + Columns_Table + "</tr>" + Content_Celda + "</table>"; } html_Content = Cabezera_Html + Content_Table + "</body>" + "</html>"; File.WriteAllText("Tables.html", html_Content); System.Diagnostics.Process.Start("Tables.html"); }
public int Verify_Sub_Conditions_mMi(String id, int c, String t, Tabla tmp_t, int con) { int contador = con; if (positions.Count != 0) { Console.WriteLine("paso por aca prro"); List <Entity_Table> ls = tmp_t.getList(); for (int i = 0; i < ls.Count; i++) { Entity_Table entity_t = ls.ElementAt(i); if (entity_t.getEntity().ToUpper() == id.ToUpper()) { ArrayList ar = entity_t.getDataArray(); int postion = int.Parse(positions[0].ToString()); if (ar[postion].Equals(t)) { Console.WriteLine("EL sdflkasdklajsdkl;R"); contador++; break; } } } } else { try { ArrayList ar = null; List <Entity_Table> ls = tmp_t.getList(); for (int i = 0; i < ls.Count; i++) { Entity_Table entity_t = ls.ElementAt(i); if (entity_t.getEntity().ToUpper() == id.ToUpper()) { ar = entity_t.getDataArray(); break; } } if (ar != null) { for (int j = 0; j < ar.Count; j++) { if (ar[j].ToString() != "") { if (c == 10)//MENOR { if (int.Parse(ar[j].ToString()) < int.Parse(t)) { positions.Add(j); contador++; break; } } else if (c == 11) {//MAYOR if (int.Parse(ar[j].ToString()) > int.Parse(t)) { positions.Add(j); contador++; break; } } else if (c == 12)//IGUAL { if (ar[j].ToString().ToUpper() == t.ToUpper()) { Console.WriteLine("su cumplioi" + t); positions.Add(j); contador++; break; } else { Console.WriteLine("su cumplioi" + t); } } else if (c == 13)//MAYOR IGUAL { if (int.Parse(ar[j].ToString()) >= int.Parse(t)) { positions.Add(j); contador++; break; } } else if (c == 14)//MENOR IGUAL { if (int.Parse(ar[j].ToString()) <= int.Parse(t)) { positions.Add(j); contador++; break; } } else if (c == 15)//DISTINTO { if (int.Parse(ar[j].ToString()) != int.Parse(t)) { positions.Add(j); contador++; break; } } else { //NADA } } } } } catch (System.FormatException) { } } return(contador); }