Required Fields Problem


Author
Message
Greg McGuffey
Greg McGuffey
Strategic Support Team Member (4.8K reputation)
Group: Forum Members
Posts: 2K, Visits: 6.6K
I've set some required fields on my BO. When I go to test it, I don't get any broken rule messages. It prompts me to save the bo. Here's what happens:



1. I click new

2. I click save (no data entered...should be some broken rules as many required fields aren't specified)

3. I get prompted to Save changes, no broken rules



In the BO, all I've done is setup my required fields. Is there something else I need to do to get these fields validated (or could I have turned something off)?
Replies
Greg McGuffey
Greg McGuffey
Strategic Support Team Member (4.8K reputation)
Group: Forum Members
Posts: 2K, Visits: 6.6K
Here is the stack trace:



   RamsBase.dll!FOXSystems.RAMS.Base.Navigation.ListBONavBase._dataBO_BusinessRulesChecked(MicroFour.StrataFrame.Business.BusinessRulesCheckedEventArgs e = {MicroFour.StrataFrame.Business.BusinessRulesCheckedEventArgs}) Line 584 + 0x5 bytes   Basic

   MicroFour StrataFrame Business.dll!MicroFour.StrataFrame.Business.BusinessLayer.raise_BusinessRulesChecked(MicroFour.StrataFrame.Business.BusinessRulesCheckedEventArgs e = {MicroFour.StrataFrame.Business.BusinessRulesCheckedEventArgs}) + 0x8f bytes

   MicroFour StrataFrame Business.dll!MicroFour.StrataFrame.Business.BusinessLayer.OnBusinessRulesChecked(MicroFour.StrataFrame.Business.BusinessRulesCheckedEventArgs e = {MicroFour.StrataFrame.Business.BusinessRulesCheckedEventArgs}) + 0x20 bytes

   MicroFour StrataFrame Business.dll!MicroFour.StrataFrame.Business.BusinessLayer.ShowBrokenRules(bool RaiseCheckedEvent = true) + 0x366 bytes

   MicroFour StrataFrame Business.dll!MicroFour.StrataFrame.Business.BusinessLayer.CheckRules(bool RaiseCheckedEvent = true) + 0x2a0 bytes

   MicroFour StrataFrame Business.dll!MicroFour.StrataFrame.Business.BusinessLayer.Save(bool Transactional = false, string TransactionKey = "") + 0xed bytes

   MicroFour StrataFrame Business.dll!MicroFour.StrataFrame.Business.BusinessLayer.Save() + 0x2a bytes

   RamsBase.dll!FOXSystems.RAMS.Base.Navigation.ListviewBONavManagerByToolStrip._saveControl_Click(Object sender = {System.Windows.Forms.ToolStripButton}, System.EventArgs e = {System.EventArgs}) Line 312 + 0x17 bytes   Basic

   System.Windows.Forms.dll!System.Windows.Forms.ToolStripItem.RaiseEvent(object key, System.EventArgs e) + 0x41 bytes

   System.Windows.Forms.dll!System.Windows.Forms.ToolStripButton.OnClick(System.EventArgs e) + 0x3e bytes

   System.Windows.Forms.dll!System.Windows.Forms.ToolStripItem.HandleClick(System.EventArgs e) + 0xc7 bytes

   System.Windows.Forms.dll!System.Windows.Forms.ToolStripItem.HandleMouseUp(System.Windows.Forms.MouseEventArgs e = {X = 21 Y = 19 Button = Left}) + 0x220 bytes

   System.Windows.Forms.dll!System.Windows.Forms.ToolStripItem.FireEventInteractive(System.EventArgs e, System.Windows.Forms.ToolStripItemEventType met) + 0x87 bytes

   System.Windows.Forms.dll!System.Windows.Forms.ToolStripItem.FireEvent(System.EventArgs e, System.Windows.Forms.ToolStripItemEventType met) + 0x122 bytes

   System.Windows.Forms.dll!System.Windows.Forms.ToolStrip.OnMouseUp(System.Windows.Forms.MouseEventArgs mea) + 0xc7 bytes

   System.Windows.Forms.dll!System.Windows.Forms.Control.WmMouseUp(ref System.Windows.Forms.Message m, System.Windows.Forms.MouseButtons button, int clicks) + 0xf2 bytes

   System.Windows.Forms.dll!System.Windows.Forms.Control.WndProc(ref System.Windows.Forms.Message m) + 0x56f bytes

   System.Windows.Forms.dll!System.Windows.Forms.ScrollableControl.WndProc(ref System.Windows.Forms.Message m) + 0x45 bytes

   System.Windows.Forms.dll!System.Windows.Forms.ToolStrip.WndProc(ref System.Windows.Forms.Message m = {msg=0x202 (WM_LBUTTONUP) hwnd=0x1130e wparam=0x0 lparam=0x14007b result=0x0}) + 0x71 bytes

   System.Windows.Forms.dll!System.Windows.Forms.Control.ControlNativewindow.OnMessage(ref System.Windows.Forms.Message m) + 0xd bytes

   System.Windows.Forms.dll!System.Windows.Forms.Control.ControlNativewindow.WndProc(ref System.Windows.Forms.Message m) + 0xd6 bytes

   System.Windows.Forms.dll!System.Windows.Forms.Nativewindow.Callback(System.IntPtr hWnd, int msg = 514, System.IntPtr wparam, System.IntPtr lparam) + 0x75 bytes

   [Native to Managed Transition]

   user32.dll!7e418734()

   [Frames below may be incorrect and/or missing, no symbols loaded for user32.dll]

   user32.dll!7e418816()

   user32.dll!7e4189cd()

   user32.dll!7e418a10()

   [Managed to Native Transition]

   System.Windows.Forms.dll!System.Windows.Forms.Application.ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop(int dwComponentID, int reason = -1, int pvLoopData = 0) + 0x2ea bytes

   System.Windows.Forms.dll!System.Windows.Forms.Application.ThreadContext.RunMessageLoopInner(int reason = -1, System.Windows.Forms.ApplicationContext context = {System.Windows.Forms.ApplicationContext}) + 0x17d bytes

   System.Windows.Forms.dll!System.Windows.Forms.Application.ThreadContext.RunMessageLoop(int reason, System.Windows.Forms.ApplicationContext context) + 0x53 bytes

   System.Windows.Forms.dll!System.Windows.Forms.Application.Run(System.Windows.Forms.Form mainForm) + 0x2e bytes

   MicroFour StrataFrame UI.dll!MicroFour.StrataFrame.Application.StrataFrameApplication.RunApplication() + 0x379 bytes

   RAMS.NET.exe!FOXSystems.RAMS.AppMain.Main() Line 28 + 0x6 bytes   Basic

   ntdll.dll!7c926abe()

   ntdll.dll!7c9268ad()

   ntdll.dll!7c91056d()

   kernel32.dll!7c80a027()

   ntdll.dll!7c91056d()

   ntdll.dll!7c926abe()

   ntdll.dll!7c9268ad()

   ntdll.dll!7c91056d()

   ntdll.dll!7c919bd3()

   ntdll.dll!7c910895()

   ntdll.dll!7c919a9c()

   ntdll.dll!7c919b3f()

   ntdll.dll!7c919aeb()

   ntdll.dll!7c919aeb()

   ntdll.dll!7c919ba0()

   kernel32.dll!7c80adde()

   kernel32.dll!7c80adf0()

   ntdll.dll!7c9106eb()

   ntdll.dll!7c9106eb()

   mscoree.dll!79004044()

   kernel32.dll!7c816fd7()

   ntdll.dll!7c9106eb()





The only code in the _dataBO_BusinessRulesChecked method is a "Stop" statement to get the stack trace.
Greg McGuffey
Greg McGuffey
Strategic Support Team Member (4.8K reputation)
Group: Forum Members
Posts: 2K, Visits: 6.6K
I forgot to update this. It was my bad (doh). What has happening was that the BO was being saved by a navigation component (allowing the BO to be navigated using a listbox). That component was designed to handle the case when the user clicked on another item in the list without saving first. In that case it would prompt the use to save/undo the changes or cancel the navigation. However, I wasn't checking on the broken rules here, so I'd get the prompt. I added a check for broken rules and it is working. I'd coded the component a while ago and forgot that I had that logic...oops Blush
StrataFrame Team
S
StrataFrame Developer (6.5K reputation)StrataFrame Developer (6.5K reputation)StrataFrame Developer (6.5K reputation)StrataFrame Developer (6.5K reputation)StrataFrame Developer (6.5K reputation)StrataFrame Developer (6.5K reputation)StrataFrame Developer (6.5K reputation)StrataFrame Developer (6.5K reputation)StrataFrame Developer (6.5K reputation)
Group: StrataFrame Developers
Posts: 3K, Visits: 2.5K
Hehe, no problem Smile  And I was on vacation, so you didn't get much help from me while I was gone...
GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Threaded View
Threaded View
Greg McGuffey - 18 Years Ago
Trent L. Taylor - 18 Years Ago
Greg McGuffey - 18 Years Ago
                 Correction...
[quote]If you put a debug in the...
Greg McGuffey - 18 Years Ago
StrataFrame Team - 18 Years Ago
                         Actually, what happens is that I get prompted to save changes. If I...
Greg McGuffey - 18 Years Ago
                             So, when you call Save() on the BO, you get the message asking you if...
StrataFrame Team - 18 Years Ago
                                 [quote]So, when you call Save() on the BO, you get the message asking...
Greg McGuffey - 18 Years Ago
                                     When you put a break point in the BusinessRules checked, can you copy...
StrataFrame Team - 18 Years Ago
                                         Here is the stack trace:
...
Greg McGuffey - 18 Years Ago
                                             I forgot to update this. It was my bad (doh). What has happening was...
Greg McGuffey - 18 Years Ago
                                                 Hehe, no problem :) And I was on vacation, so you didn't get much help...
StrataFrame Team - 18 Years Ago

Similar Topics

Reading This Topic

Login

Explore
Messages
Mentions
Search