Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Using subsets of same table for different drop down list
Message
 
À
02/08/2006 14:20:39
Jason Mesches
Ocean Systems Engineering Corporation
Carlsbad, Californie, États-Unis
Information générale
Forum:
ASP.NET
Catégorie:
The Mere Mortals .NET Framework
Versions des environnements
Environment:
C# 2.0
OS:
Windows Server 2003
Network:
Windows 2003 Server
Database:
Visual FoxPro
Divers
Thread ID:
01140484
Message ID:
01142524
Vues:
9
Jason,

I tried adding the tablename to the BindingSourceDisplayMember and BindingSourceValueMember and it didn't make any difference. Then I removed the old drop down list, moved the list using the 1st table to be the first control and made a copy of the 1st control to create the 2nd. That did not solve the problem either. Do I need to do something to register the 2nd table with the form?

Here is the code I used to create the reader:
        public IDataReader ReadApprovers()
        {
            IDataReader dr = this.DataSet.CreateDataReader(this.DataSet.Tables[1]);
            return dr;
        }
Thanks.

Linda

[UPDATE]

I stepped through the binding code. This may be the problem. mmBusinessWebPage.cs has a method called GetBizObj, which calls RefBizObj, passing the name of the 2nd table ("Approvers") as the parameter. It calls
an mmCollections.cs method Get(string ObjClass). If the ObjectType ("Users", which is the primary table) does not equal the ObjClass ("Approvers", which is the 2nd table), it returns a null.

That seems like it is ending up with a null object reference for data binding. I still don't know what to do to fix this, though. It seems like I probably need to register something else with the form. I tried registering another instance of the business object Users but that caused both drop down lists to have no values.

I hope you've still got some more ideas.

Thanks.

Linda
Linda Harmes
HiBit Technologies, Inc.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform