Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Where to put Calculated Fields
Message
Information générale
Forum:
ASP.NET
Catégorie:
Conception classe
Versions des environnements
Environment:
C# 2.0
Database:
MS SQL Server
Divers
Thread ID:
01091608
Message ID:
01091942
Vues:
13
Alright, this isn't solved yet. While the code below does work, it doesn't allow the properties to be seen as columns for binding. So, now do I just start adding these as DataColumns to the DataTable, too?

TIA,
Chad

>>I am still quite confused about the data access objects, so I hope that someone with more experience can answer your question.
>
>Well, I have it working. Here's what I did, if anyone is interested (which it doesn't seem like many <s>):
>
>        public partial class dbSchedulesRow
>        {
>            /// <summary>
>            /// Gets or Sets the Sunday value of the nDaysOfWeek column.
>            /// </summary>
>            public bool Sunday
>            {
>                get
>                {
>                    return ((this.nDayOfWeek & 2) == 2);
>                }
>                set
>                {
>                    if (value)
>                    {
>                        this.nDayOfWeek = (byte)(this.nDayOfWeek | 2);
>                    }
>                    else
>                    {
>                        this.nDayOfWeek = (byte)(this.nDayOfWeek & 252);
>                    }
>                }
>            }
>
>            /// <summary>
>            /// Gets or Sets the Monday value of the nDaysOfWeek column.
>            /// </summary>
>            public bool Monday
>            {
>                get
>                {
>                    return ((this.nDayOfWeek & 4) == 4);
>                }
>                set
>                {
>                    if (value)
>                    {
>                        this.nDayOfWeek = (byte)(this.nDayOfWeek | 4);
>                    }
>                    else
>                    {
>                        this.nDayOfWeek = (byte)(this.nDayOfWeek & 250);
>                    }
>                }
>            }
>        }
>
>I hope this can help someone else out there looking to do something similar.
>
>Chad
_________________________________
There are 2 types of people in the world:
    Those who need closure
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform