CurrentDataTable not changed / ASPxGridView


Author
Message
ChanKK
ChanKK
Advanced StrataFrame User (622 reputation)Advanced StrataFrame User (622 reputation)Advanced StrataFrame User (622 reputation)Advanced StrataFrame User (622 reputation)Advanced StrataFrame User (622 reputation)Advanced StrataFrame User (622 reputation)Advanced StrataFrame User (622 reputation)Advanced StrataFrame User (622 reputation)Advanced StrataFrame User (622 reputation)
Group: Forum Members
Posts: 190, Visits: 1.3K
Hi
As anyone who follow my previous post, might notice that I am facing memory leak issue when bind BO to ASPxGridView via WebBusinessBindingSource.
I found the workaround by change SF source code to auto dispose the internal BBS in Unload event. I tested it with ANTS memory profiler and found that the memory leak issue solved.

However, I have another issue here. I have attached a sample project. It is using Northwind db. 
The project UI consist of 2 gridview, upper one is using ParentBO (EmployeesBO), and the bottom one is using childBO  (EmployeeTerritoriesBO). WHen ParentBO.Navigated, childBO will be refilled.

1. Run the web app
2. Key in any firstname in the list, and click "FILL" button. 
3. The child ASPxGridview is refreshed correctly.
4. Repeat step 2 with another first name again.
5. The child ASPxGridView will not refreshed anymore. It will always show the result when do the first time query.

Any ideas?

Thank you
Attachments
NotRefresh.zip (172 views, 5.00 MB)
Reply
Andrew Harper
Andrew Harper
StrataFrame User (411 reputation)StrataFrame User (411 reputation)StrataFrame User (411 reputation)StrataFrame User (411 reputation)StrataFrame User (411 reputation)StrataFrame User (411 reputation)StrataFrame User (411 reputation)StrataFrame User (411 reputation)StrataFrame User (411 reputation)
Group: StrataFrame Users
Posts: 91, Visits: 3.4K
Hi Chan,

I downloaded your sample and did the following:

1. Opened and converted project in VS2010, I did not update the project to use a newer .net target platform

2. Changed the Microfour References to the Microfour dll's you supplied. The solution would then build without error

3. Changed the Global.asax to point to my Northwind DB 

4. Built the solution

5. Ran the application and got the error below:



Method not found: 'MicroFour.StrataFrame.Business.BusinessBindingSource WBBSEnumerator.get_BBS()'.

Source File: C:\chank\NotRefresh\Common\BaseWBBS.cs    Line: 49 



6. Modified BaseWBBS and commented out the code below base.OnUnload(e)



public class BaseWBBS : MicroFour.StrataFrame.UI.Web.WebBusinessBindingSource

{

#region " Private Fields "

private bool _autoDispose = true;

#endregion

#region " Public Properties "

/// <summary>

/// Method to set gridview to auto dispose datasource

/// </summary>

public bool AutoDispose

{

get

{

return this._autoDispose;

}

set

{

this._autoDispose = value;

}

}

#endregion

protected override void OnUnload(EventArgs e)

{

base.OnUnload(e);

/*

if(this.AutoDispose && this.DataView != null

&& this.DataView.CurrentEnumerator.BBS != null)

{

this.DataView.CurrentEnumerator.BBS.Dispose();

}

*/

}

}

}



7. Rebuilt and ran the application and the clicking on the fill button worked as expected,

I suspect the initial error is due to a different strataframe dll being picked up at run time on my machine, however the fix suggests to me that the issue is with your version. 

Hope this helps,

Andy

ps. The format change in this post from point 6 onwards is unintentional - I tried but couldn't overcome it in the editor!


Edited 14 Years Ago by Andrew Harper
GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...





Similar Topics

Reading This Topic

Login

Explore
Messages
Mentions
Search