Memory error - possible threading issue?


Author
Message
Keith Chisarik
Keith Chisarik
StrataFrame VIP (1.6K reputation)StrataFrame VIP (1.6K reputation)StrataFrame VIP (1.6K reputation)StrataFrame VIP (1.6K reputation)StrataFrame VIP (1.6K reputation)StrataFrame VIP (1.6K reputation)StrataFrame VIP (1.6K reputation)StrataFrame VIP (1.6K reputation)StrataFrame VIP (1.6K reputation)
Group: StrataFrame Users
Posts: 939, Visits: 40K
Since it was DevExpress, it is probably something on my end I'm sure.



It might be related to my report writer now that I think of it, it has a bug where if you overlay two reports (this is big in ActiveReports) and there are fields that or "on top" of each other I get this error.



Anyhow, glad yours is fixed!

Keith Chisarik
Andria Jensen
Andria Jensen
StrataFrame User (422 reputation)StrataFrame User (422 reputation)StrataFrame User (422 reputation)StrataFrame User (422 reputation)StrataFrame User (422 reputation)StrataFrame User (422 reputation)StrataFrame User (422 reputation)StrataFrame User (422 reputation)StrataFrame User (422 reputation)
Group: Forum Members
Posts: 336, Visits: 497
Ok, just to update on this issue.  I first upgraded to the latest release of DevExpress (7.2.1) and it actually fixed the issue, although I'm not sure if the new code just caused some memory to move around and that was a coincidence or not.  Regardless, I had to uninstall it and go back to 7.1 version anyway because of some other serious bugs.  So I was hitting the error again.  DevExpress mentioned off-hand that I needed to have the MenuManager property of the GridControl set to be using a BarManager.  Once I did this, the problem was fixed.  However, they still won't admit they have any kind of bug here (haha).  I have gotten this error before, but almost always on a right click, so I was pretty sure it was their problem but wanted to post here just in case you guys had seen or run into it before.  Oh, and just to answer the question, no I'm not using security with StrataFrame.  Thanks for the help, and I hope you can get to the bottom of this one Keith.
Keith Chisarik
Keith Chisarik
StrataFrame VIP (1.6K reputation)StrataFrame VIP (1.6K reputation)StrataFrame VIP (1.6K reputation)StrataFrame VIP (1.6K reputation)StrataFrame VIP (1.6K reputation)StrataFrame VIP (1.6K reputation)StrataFrame VIP (1.6K reputation)StrataFrame VIP (1.6K reputation)StrataFrame VIP (1.6K reputation)
Group: StrataFrame Users
Posts: 939, Visits: 40K
As far as when it happens, I cannot pinpoint it at this time, I will pay more attention to it.



I had relegated it in my mind to "I'll fix it later".




Keith Chisarik
Keith Chisarik
Keith Chisarik
StrataFrame VIP (1.6K reputation)StrataFrame VIP (1.6K reputation)StrataFrame VIP (1.6K reputation)StrataFrame VIP (1.6K reputation)StrataFrame VIP (1.6K reputation)StrataFrame VIP (1.6K reputation)StrataFrame VIP (1.6K reputation)StrataFrame VIP (1.6K reputation)StrataFrame VIP (1.6K reputation)
Group: StrataFrame Users
Posts: 939, Visits: 40K
Attempted to read or write protected memory. This is often an indication that other memory is corrupt.



I would like to add that I get this a lot, I thought I was doing something wrong so I didn't bring it here.



I am using security in my application, it happens during debugging as well as when running a compiled 'release' executable.




Keith Chisarik
StrataFrame Team
S
StrataFrame Developer (4.4K reputation)StrataFrame Developer (4.4K reputation)StrataFrame Developer (4.4K reputation)StrataFrame Developer (4.4K reputation)StrataFrame Developer (4.4K reputation)StrataFrame Developer (4.4K reputation)StrataFrame Developer (4.4K reputation)StrataFrame Developer (4.4K reputation)StrataFrame Developer (4.4K reputation)
Group: StrataFrame Developers
Posts: 3K, Visits: 2.5K
Wow, that's an interesting one... are you using security?  Some of our users were getting some access violations in their apps when using security because we add a low-level hook to test for keyboard and mouse input.  Other than that, though, the only place where we start up any new threads is when you call Save() on a business object (and as of 1.6.1, we don't spawn off extra threads if the DataLayerSavingThreads on the BO is set to 1).  As for the posibility of the error coming from an "unsafe {}" block of code, we use VB (which doesn't have the "unsafe" keyword that turns off some CLR type checking, GC and stuff) so we don't have any "unsafe" regions of code in our framework.  If the icons are disappearing from your context menus, I'd say that would have to be them.

On a side note, does it only happen when you're debugging (not running the .exe standalone)?  Or does it only happen on your machine?

Andria Jensen
Andria Jensen
StrataFrame User (422 reputation)StrataFrame User (422 reputation)StrataFrame User (422 reputation)StrataFrame User (422 reputation)StrataFrame User (422 reputation)StrataFrame User (422 reputation)StrataFrame User (422 reputation)StrataFrame User (422 reputation)StrataFrame User (422 reputation)
Group: Forum Members
Posts: 336, Visits: 497
Ok, let me start by saying I'm not sure if this error is occuring with you guys (StrataFrame) or with DevExpress, since I am using both here and am a little confused about where the error is occuring.  With that said, this is what is happening:

I have a lot of inherited forms, on which are XtraGrid controls.  In my application, I am getting some seemingly random memory errors on bringing up the right click menu of a grid header.  I figured this was a DevExpress issue and have already posted with them, however on further looking into it I thought I would post here as well.  In the IDE, I turned on the showing of more exceptions, including system and CLR exceptions.  When the error is occuring, I am getting the following error:

 

It then goes through the HandleThreadException method and pops this error message:

Attempted to read or write protected memory. This is often an indication that other memory is corrupt.

After I let it finish I then get this:

Now, I thought this was a DevExpress issue but they are saying it is possibly because I have threads which are not handled properly and causing this error to occur.  I am not using any threads, so the only thing I could think of was possibly StrataFrame has some threading going on which is conflicting with the threading that DevExpress has going on.  If you can think of anything that might be causing an issue like this please let me know. 

Once again, this is all happening when I right click the grid header to go to the column chooser, etc.  It doesn't always happen, but it does about 80-90% of the time.  Also, when I mouse over the context menu items, the icons are now disappearing in the same menu i'm getting the errors in.  Let me know if you have any input on this or if you know of any possibly causes.  Thanks!

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