Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Using meta-data in .NET
Message
From
19/10/2007 08:53:55
 
 
To
All
General information
Forum:
ASP.NET
Category:
Coding, syntax and commands
Title:
Using meta-data in .NET
Miscellaneous
Thread ID:
01262116
Message ID:
01262116
Views:
57
Hello,

How could I handle the following situation in .NET?

In a time and attendance application there any many pay categories. Each pay category needs to be agregated into several total types. Information describing pay categories, total types, and the total types into which each pay category must be added is stored in meta-data tables.

The transaction table has two child tables, one with daily data (one record for hours worked in each pay category each day) and one with summary data for the transaction which include totals by pay category as well as by total type (one record for each different total).

In VFP, I might create an object at run time with properties named after the pay categories and total types described in the meta-data tables and use them as acumulators. That may look like this:
ADDPROPERTY(oTransaction.oData,Metadata.cCategory,0)
At the beginning of the editing process I would take previous info from the daily data table and sum it into the just created properties of the business object according to the rules of the meta-data. It may be something like this:
lnAmount = DailyData.nAmount
lcCategory = DailyData.cCategory
lcTotalType = Metadata.cTotalType
oTransaction.oData..&lcCategory = oTransaction.oData..&lcCategory + lnAmount
oTransaction.oData..&lcTotalType = oTransaction.oData..&lcTotalType + lnAmount
As user adds/deletes/modifies records in daily data, changes are made to the accumulators in a similar manner. During SAVE, changes to the daily data table are commited and the values of the various properties replace the previous values in the summary data table.

How can I take a similar approach with Strataframe? In other words, how can I create and refer to properties of the Business Object at runtime based on the content of meta data tables?

TIA,

Alex
Next
Reply
Map
View

Click here to load this message in the networking platform