StrataFrame Forum

Problem calling a simple fill in a webform

http://forum.strataframe.net/Topic3345.aspx

By Keith Chisarik - 10/5/2006

I have no clue what this error means....... it occurs when my webform calls the fill method from the load, the fill is a simple top x to get things going.



System.NotImplementedException was unhandled by user code

Message="The class [commonClasses.transactionBO] must override the property 'TableName' since it derives from MicroFour.StrataFrame.Business.BusinessLayer."

Source="MicroFour StrataFrame Business"

StackTrace:

at MicroFour.StrataFrame.Business.BusinessLayer.get_TableName()

at MicroFour.StrataFrame.Business.BusinessLayer.CreateInternalTable()

at MicroFour.StrataFrame.Business.BusinessLayer.get__CurrentDataTable(Boolean IsSharedTable)

at MicroFour.StrataFrame.Business.BusinessLayer.get__CurrentDataTable()

at MicroFour.StrataFrame.Business.BusinessLayer.ChangeCurrentDataTable(DataTable NewTable, Boolean AcceptChanges, Boolean IsSharedTable)

at MicroFour.StrataFrame.Business.BusinessLayer.ChangeCurrentDataTable(DataTable NewTable, Boolean AcceptChanges)

at MicroFour.StrataFrame.Business.BusinessLayer.ChangeCurrentDataTable(DataTable NewTable)

at MicroFour.StrataFrame.Business.BusinessLayer.FillDataTable(String SelectStatement)

at commonClasses.transactionBO.FillTop100() in C:\Documents and Settings\kchisarik\My Documents\Visual Studio 2005\Projects\drsAS400\commonClassesandBOs\transactionBO.vb:line 68

at Default.Page_Load(Object sender, EventArgs e) in V:\2005 Projects\websites\drsAS400\Default.aspx.vb:line 8

at System.Web.UI.Control.OnLoad(EventArgs e)

at System.Web.UI.Control.LoadRecursive()

at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
By Trent L. Taylor - 10/6/2006

Well, I am not sure how you achieved getting this message to appear, but the problem is that the TableName property in your business object has not been overwritten (or it is missing the Implements tag at the end of the declaration).  Go to you business object and look in the transactionBO.Designer.vb file.  See if the TableName property exists within this code.  If not, rebuild your partial class and see if it exists after the rebuild of that class.

If the TableName property exists, see if there is an Implements tag at the end of the property declaration line.  If it is missing this it will cause an issue as well.

By Keith Chisarik - 10/6/2006

My issue might stem from the fact that I could not find the "Step by Step" directions to declare a BO in a webform app as referenced in the help file, so I winged it using the sample application as a model. Where is it?



The help file in general is pretty slim on webforms, am I missing something?





For information on declaring business objects within an ApplicationBasePage, see Step-by-Step -- Declaring Business Objects.
By Trent L. Taylor - 10/6/2006

To declare the business object, open the ApplicationBasePage and there will be a region that says "Business Object Definitions".  To add your BO add a line like this:

Public WithEvents Customers As CustomersBO

Notice that you do not provide the New operator.  This is all done for you.

By Keith Chisarik - 10/6/2006

OK then I got it right? Ill check your other suggestion......



Does there exist more documentation for webforms that the approx 4 paragraphs in the SF Framework help file?



Thanks.
By Trent L. Taylor - 10/6/2006

We have people working full time on the docs now.  If you'll notice there have been dramatic improvements already.  Also, we are going to publish an update next week.  We are working on this...thanks.
By Keith Chisarik - 10/6/2006

That's cool Trent, I just dont want to waste time looking for something that isnt there.....



I will look forward to the updated documentation.