Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Binding on a ListBox
Message
Information générale
Forum:
ASP.NET
Catégorie:
The Mere Mortals .NET Framework
Divers
Thread ID:
00798546
Message ID:
00798687
Vues:
27
Stephen,

>When I try to use them in a ListBox I bomb out. A reference to a key is the WEB error I get.
>
>I see the key in that Select statement identical to the key listed in the BO.
>public SAE()
>{
>this.TableName = "depappl";
>this.PrimaryKey = "ap_key";

If I understand what you're saying, I think the problem is that you have specified the business object’s TableName as “depappl” and its PrimaryKey as “ap_key”...but ap_key is not a key field in the "depappl" table?

When the Framework tries to retrieve this value, you get the key error. If your table is read only and doesn’t have a primary key, don’t set the PrimaryKey field at all in your business object.R

Regards,
Kevin McNeish
Eight-Time .NET MVP
VFP and iOS Author, Speaker & Trainer
Oak Leaf Enterprises, Inc.
Chief Architect, MM Framework
http://www.oakleafsd.com
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform