InputPanel throws NullReferenceException on submission

Jan 28, 2011 at 7:17 PM

I'm trying to use the InputPanel in a VB.NET WP7 app I'm writing, and whenever the user clicks the submit button on the panel, the control throws a NullReferenceException:

System.NullReferenceException was unhandled
       at Coding4Fun.Phone.Controls.PopUp`2.OnCompleted(PopUpEventArgs`2 result)
       at Coding4Fun.Phone.Controls.InputPrompt.ok_Click(Object sender, RoutedEventArgs e)
       at System.Windows.Controls.Primitives.ButtonBase.OnClick()
       at System.Windows.Controls.Button.OnClick()
       at System.Windows.Controls.Primitives.ButtonBase.OnMouseLeftButtonUp(MouseButtonEventArgs e)
       at System.Windows.Controls.Control.OnMouseLeftButtonUp(Control ctrl, EventArgs e)
       at MS.Internal.JoltHelper.FireEvent(IntPtr unmanagedObj, IntPtr unmanagedObjArgs, Int32 argsTypeIndex, String eventName)
       at Microsoft.Xna.Framework.Input.UnsafeNativeMethods.CallWindowProc(IntPtr lpPrevWndFunc, IntPtr hWnd, UInt32 msg, IntPtr wParam, IntPtr lParam)
       at Microsoft.Xna.Framework.Input.SafeNativeMethods.CallWindowProc(IntPtr lpPrevWndFunc, IntPtr hWnd, UInt32 msg, IntPtr wParam, IntPtr lParam)
       at Microsoft.Xna.Framework.Input.WindowMessageHooker.Hook.WndProc(IntPtr msgWnd, UInt32 msg, IntPtr wParam, IntPtr lParam)

This happens even with a fresh control dropped on the form (displays and functions fine, until the user submits the text), so it doesn't appear to have to do with my code.

Any ideas?

Jan 29, 2011 at 1:15 AM

can you provide a small repo for me and create a bug (  Right now I'm not 100% sure how you're leveraging the my control.  I'll attempt a few things, but without a bit more, I'm aiming blind.


Jan 29, 2011 at 1:45 AM

Ok, I've uploaded a test project:

Feb 4, 2011 at 5:55 AM

Thanks!  Fixed!