Error "There are no rows in the current data table. An edit is not allowed."


Author
Message
Ivan George Borges
Ivan George Borges
Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)
Group: StrataFrame MVPs
Posts: 1.9K, Visits: 21K
Good to know that, Michel.

Yep, I do that all the time and then I try to break up the logic into small pieces and go 1 by 1 untill I can isolate where the issue is.
Michel Levy
Michel Levy
StrataFrame User (441 reputation)StrataFrame User (441 reputation)StrataFrame User (441 reputation)StrataFrame User (441 reputation)StrataFrame User (441 reputation)StrataFrame User (441 reputation)StrataFrame User (441 reputation)StrataFrame User (441 reputation)StrataFrame User (441 reputation)
Group: StrataFrame Users
Posts: 193, Visits: 9K
Thanks Ivan

I preffered to find a workaround, because I was unsure of the debugging between VS2008 and VS2010.

Begining the Edit process, I save an empty snapshot of the empty BO, add a "dummy" new row, and at the end of the saving process of an edit, I restore the empty snapshot. Yes, I know, it's not very pretty Whistling ... but it works.

Before going deeper in SF code, I want to verify the problem on a more simple form, without all this confuse code I wrote.

Thanks again, and merry Christmas
Ivan George Borges
Ivan George Borges
Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)
Group: StrataFrame MVPs
Posts: 1.9K, Visits: 21K
Hi Michel.

Probably this is not the only way, but it is one that will surely show you where the issue is.

For the VS 2010 thing, I wouldn't think it would be a problem, as long as you are using VS 2010, I guess.

Merry Christmas! Smile
Michel Levy
Michel Levy
StrataFrame User (441 reputation)StrataFrame User (441 reputation)StrataFrame User (441 reputation)StrataFrame User (441 reputation)StrataFrame User (441 reputation)StrataFrame User (441 reputation)StrataFrame User (441 reputation)StrataFrame User (441 reputation)StrataFrame User (441 reputation)
Group: StrataFrame Users
Posts: 193, Visits: 9K
Hi Ivan,

no, not yet. Do you think that's the only way to determine where this exception comes from?

I didn't want to debug SF source code Unsure but everything needs a first time... I'll build the SF project source in debug mode and go on. 

Arghh! Angry SF source code is in VS2010, and this project is on VS2008. Do you think I need to upgrade my project in VS20010, for debugging in SF source code?
Edited 14 Years Ago by Michel Levy
Ivan George Borges
Ivan George Borges
Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)Strategic Support Team Member (3.5K reputation)
Group: StrataFrame MVPs
Posts: 1.9K, Visits: 21K
Have you tried debugging and steping into SF source code to determine where you get the exception?
Michel Levy
Michel Levy
StrataFrame User (441 reputation)StrataFrame User (441 reputation)StrataFrame User (441 reputation)StrataFrame User (441 reputation)StrataFrame User (441 reputation)StrataFrame User (441 reputation)StrataFrame User (441 reputation)StrataFrame User (441 reputation)StrataFrame User (441 reputation)
Group: StrataFrame Users
Posts: 193, Visits: 9K
Hi,

On editing from the form, I get a message "There are no rows in the current data table.  An edit is not allowed." It is a SF message, not of mine.

(There are no rows in the current data table.  An edit is not allowed.
   à MicroFour.StrataFrame.Business.BusinessLayer.Edit(Boolean CheckSecurity)
   à MicroFour.StrataFrame.UI.Windows.Forms.BaseForm.Edit(Boolean CheckSecurity)
   à MicroFour.StrataFrame.UI.Windows.Forms.MaintenanceFormToolStrip.cmdEdit_Click(Object sender, EventArgs e)
...)

After validating the message, I can edit and save.

On a maintenance form, I've 3 BO. The IncludeInFormEditType property is set to DeterminedByBusinessObject.
The Primary BO is set on IncludeInFormEdit = True, the 2 other one are set to False. Only the primary BO is set to ManageUIReadOnlyState = True.
One of these BO is a child of the primary BO (ChildAutoFilter is set to MatchCurrentRow). There is a ChildFormDialog on this form, with BO translations for the primary and its child.
The only BO with no row is neither the primary, neither its child (the third one...)

The code for the EditingStateChanged for the form is in a Try/Catch, and the catch is never raised. Same thing with a try/catch on EditingStateChanged of each BO.

What could be the origin of this message? How could I trap it?
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