Exemple #1
0
    public static string Return_Full_Name(int profile_id)
    {
        string full_name = string.Empty;

        tblProfile p = ModelLayer.GetProfile(profile_id);

        full_name = p.vLastname + ", " + p.vFirstname;

        return(full_name);
    }
    private void LoadProfile(int iAccount)
    {
        if (iAccount != 0)
        {
            tblAccount     a  = ModelLayer.GetAccount(iAccount);
            tblProfile     p  = ModelLayer.GetProfile(a.iProfile);
            tblAccountType at = ModelLayer.GetAccountType(a.iAccountType);

            label_name.Text         = p.vLastname + ", " + p.vFirstname;
            label_country.Text      = p.vCountry;
            label_account_type.Text = at.vAccountType;
            label_age.Text          = p.vAge;
            label_sex.Text          = p.vSex;
        }
        else
        {
            label_name.Text         = "Admin";
            label_country.Text      = "Admin";
            label_account_type.Text = "Admin";
            label_age.Text          = "Admin";
            label_sex.Text          = "Admin";
        }
    }