Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeArchived Discus...Archived Discus...Developing Under Previous Versions of .NETDeveloping Under Previous Versions of .NETASP.Net 2.0ASP.Net 2.0Help tracking this errorHelp tracking this error
Previous
 
Next
New Post
5/21/2009 4:03 PM
 

Hello,

Any now and then I get an error like this:

InnerException: DataBinding: 'System.Data.DataRowView' does not contain a property with the name 'Id_FC'.
FileName:
FileLineNumber: 0
FileColumnNumber: 0
Method: System.Web.UI.DataBinder.GetPropertyValue
StackTrace:
Message: DotNetNuke.Services.Exceptions.PageLoadException: DataBinding: 'System.Data.DataRowView' does not contain a property with the name 'Id_FC'. ---> System.Web.HttpException: DataBinding: 'System.Data.DataRowView' does not contain a property with the name 'Id_FC'. at System.Web.UI.DataBinder.GetPropertyValue(Object container, String propName) at System.Web.UI.DataBinder.GetPropertyValue(Object container, String propName, String format) at System.Web.UI.WebControls.ListControl.PerformDataBinding(IEnumerable dataSource) at System.Web.UI.WebControls.ListControl.PerformSelect() at AGSIS.FCforma.Page_Load(Object sender, EventArgs e) in E:\Inetpub\dnn_2\DesktopModules\AGSIS\FCforma.ascx.cs:line 21 at System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) at System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) at System.Web.UI.Control.OnLoad(EventArgs e) at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) --- End of inner exception stack trace ---
 

 

This is very strange because my application works, let's say 95% of the time correctly, except these errors (let's say 5%).

In ascx.cs at line 21: ddFacultateCiclu.DataBind();

while the ddFacultate is like this:

 <asp:DropDownList ID="ddFacultateCiclu" runat="server" AutoPostBack="True" DataSourceID="sqlDSFacultateCiclu" DataTextField="Denumire" DataValueField="Id_FC" OnSelectedIndexChanged="ddFacultateCiclu_SelectedIndexChanged" Width="100%">
</asp:DropDownList>
<asp:SqlDataSource ID="sqlDSFacultateCiclu" runat="server" ConnectionString="<%$ ConnectionStrings:AGSISSqlServer %>" SelectCommand="FacultateCiclu_GetByFacultate" SelectCommandType="StoredProcedure" OnSelecting="sqlDSFacultateCiclu_Selecting">
<SelectParameters>
<asp:Parameter Name="ID_Facultate" Type="Int64" />
<asp:Parameter Name="ID_AnUniv" Type="Int64" />
</SelectParameters>
</asp:SqlDataSource>

Please note that the SP mentioned in the source returns the correct columns... Also, very strange, the DNN aplication works fine while my module(s) throw(s) errors. My modules get data from a separate database in the same instance of SQL Server 2005.

 

Plese help tracking down the source of errors...

Thank you,


Catalin

 
New Post
5/21/2009 4:13 PM
 

If your dropdown list isn't prepopulated with an entry that has the bound DataFieldValue, I believe that error gets thrown.

Have you pre-popluated your drop down list before binding data to it?
Have you verified that the desired entry is in the dropdownlist before databinding?

 
New Post
5/21/2009 4:21 PM
 

Thank you for your interest.

The problem is that the application/module works just fine with no errors, until, in some un-identified conditions, all my modules begin throwing errors. The modules built with SqlDataSource throw errors like mentioned above, while modules built with "classic" code-behind or ObjectDataSource data-binding do not throw errors but the grids/datalists/lists/dropdowns/... inside them do not get populated.

If the application is restarted (host menu), everything starts working until... these un-identified conditions...

[edit, 3 min. later]
And to answer your questions. I believe that an error would appear only when the SelectedValue for the DropDownList would populated with a value that does not exist in the data bound to the dropdownlist. But this is not the case but I believe it is a more profound one, but I do not know which one...

Catalin

 
New Post
5/21/2009 4:30 PM
 

 Oh intermittent problems, how thou dost annoy me. 

I had a bunch of stuff written up about how I debug, but since it's in your page_load, lemme see your page_load function. :)

 
New Post
5/22/2009 12:19 AM
 

Here is a link to both the C# code and the ASCX: www.unitbv.ro/cata/errors/errors.zip

Thanks for helping.

Catalin

 
Previous
 
Next
HomeHomeArchived Discus...Archived Discus...Developing Under Previous Versions of .NETDeveloping Under Previous Versions of .NETASP.Net 2.0ASP.Net 2.0Help tracking this errorHelp tracking this error


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out