コード例 #1
0
        //devuelve el volumen del trailes
        private string ReturnTrailerVolume(int idtrailer)
        {
            string VolumeTrailer = "";

            if (idtrailer > 0)
            {
                AssignmentsDataSet ds = new AssignmentsDataSet();
                AssignmentsDataSetTableAdapters.TrailerInfoTableAdapter adapter = new AssignmentsDataSetTableAdapters.TrailerInfoTableAdapter();
                AssignmentsDataSet.TrailerInfoDataTable dataTable = adapter.GetDataBy1IdTrailer(idtrailer);

                if (dataTable.Rows.Count > 0)
                {
                    AssignmentsDataSet.TrailerInfoRow row = (AssignmentsDataSet.TrailerInfoRow)dataTable.Rows[0];
                    VolumeTrailer = row.TankVolume.ToString();
                }
            }
            return(VolumeTrailer);
        }
コード例 #2
0
        //devuelve la licensia del trailer
        private string ReturnTrailerLicense(int idtrailer)
        {
            string LicenseTrailer = "";

            if (idtrailer > 0)
            {
                AssignmentsDataSet ds = new AssignmentsDataSet();
                AssignmentsDataSetTableAdapters.TrailerInfoTableAdapter adapter = new AssignmentsDataSetTableAdapters.TrailerInfoTableAdapter();
                AssignmentsDataSet.TrailerInfoDataTable dataTable = adapter.GetDataBy1IdTrailer(idtrailer);

                if (dataTable.Rows.Count > 0)
                {
                    AssignmentsDataSet.TrailerInfoRow row = (AssignmentsDataSet.TrailerInfoRow)dataTable.Rows[0];
                    LicenseTrailer = row.LicensePlate;
                }
            }

            return(LicenseTrailer);
        }