Velocity Reviews

Velocity Reviews (http://www.velocityreviews.com/forums/index.php)
-   ASP .Net (http://www.velocityreviews.com/forums/f29-asp-net.html)
-   -   Refresh Schema doesn't work (http://www.velocityreviews.com/forums/t497043-refresh-schema-doesnt-work.html)

Steve Elliott 04-06-2007 03:45 PM

Refresh Schema doesn't work
 
When you link an ObjectDataSource to a business object, it appears that the
Refresh Schema button does nothing. Here's the scenario:

I have two class libraries, one is a Data Access Layer and the other is a
List class. The former implements all of the CRUD logic, and the latter
implements a number of interfaces for the purpose of aggregate
functionality. For example, the following is the method I select when I
configure the object datasource for a class I call "Template" (No relation
to <Template>):

public static List<TemplateInfo> GetTemplates()
{
List<TemplateInfo> templates = new List<TemplateInfo>();

TemplateInfo[] templatelist =
TemplateData.GetTemplate();

foreach (TemplateInfo info in templatelist)
{
templates.Add(info);
}

return templates;
}

Now, all works fine, once I do that and link a GridView to the
ObjectDataSource, I see my columns and can manipulate them in design mode.
The problem occurs when I modify the underlying database object, perhaps
adding a column. In this case the TemplateInfo class is modified to store
the new fields. However nothing I do will cause those columns to appear in
the "Edit Columns" wizard. I tried "Refresh Schema" to no avail. I even ran
SQL Server Profiler to see what happens when Refresh Schema is selected -
Nada.

So, how do I get those columns to appear?

Thanks
Steve


All times are GMT. The time now is 12:39 AM.

Powered by vBulletin®. Copyright ©2000 - 2014, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.