Ejemplo n.º 1
0
    public static int Painter_SaveStep(clsPainter p)
    {
        MySqlInsert ins = new MySqlInsert(TABLE_PAINTER);

        foreach (var prop in p.GetType().GetProperties())
        {
            ins.Add(prop.Name, prop.GetValue(p, null));
        }

        string cmdSql = ins.ToString();

        return(MySqlDbAccess.ExecuteNonQueryInt(cmdSql, false));
    }
Ejemplo n.º 2
0
    public static int Painter_SaveStep(clsPainter p)
    {
        MySqlInsert ins = new MySqlInsert(TABLE_PAINTER);

        foreach (var prop in p.GetType().GetProperties())
        {
            ins.Add(prop.Name, prop.GetValue(p, null));
        }

        string cmdSql = ins.ToString();

        return MySqlDbAccess.ExecuteNonQueryInt(cmdSql, false);
    }
Ejemplo n.º 3
0
    public static int Painter_Save(clsPainter obj)
    {
        MySqlInsert ins = new MySqlInsert(TABLE_PAINTER);

        foreach (var prop in obj.GetType().GetProperties())
        {
            if (prop.Name == "left" || prop.Name == "type")
                ins.Add("`" + prop.Name + "`", prop.GetValue(obj, null));
            else
                ins.Add(prop.Name, prop.GetValue(obj, null));
        }

        string cmdSql = ins.ToString();

        return MySqlDbAccess.ExecuteNonQueryInt(cmdSql, false);
    }