Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Problem in PopulateForeignParentKeyField() in SaveDataSe
Message
Information générale
Forum:
ASP.NET
Catégorie:
The Mere Mortals .NET Framework
Versions des environnements
Environment:
C# 1.1
OS:
Windows XP SP2
Network:
Windows 2003 Server
Database:
MS SQL Server
Divers
Thread ID:
01037612
Message ID:
01037673
Vues:
14
Ty,

>I think there may be a problem in the SaveDataSet method on mmBusinessObject when trying to use the automatic population of the foreign key in a parent/child relationship.
>
>If you call any of the SaveDataSet overloads (they all piggy back each other) that takes a tablename as a paramter and you are trying to populate a foreign key field reference via the ForeignParentKeyField, then the method PopulateForeignParentKeyField() fails.
>
>I think the call to the PopulateForeignParentKeyField() method should have a 'string tableName' overload and that is what should be called from the SaveDataSet() method.
>
>If anyone has a workaround, please let me know...

The code is assuming the foreign parent key field you have defined is associated with the primary table name you have specified for the business object, since it's recommended you use the table specified in the TableName property for updates and alternate table names for lookups. Does this scenario not work out for you?

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