Hi all,
Using code from the link I created a quick search button and the search works but selecting a part doesn’t.
I’m aware of the error message but I’m not sure what’s causing the error. The button being referenced was created by the toolbox, and the only code I have is wizard-generated code for the button and the code provided by Jose in the link. The error is below, I’d appreciate any help. Thanks.
Application Error
Exception caught in: App.PartTracker.PartTrackerForm.EP.200.Customization.2024_01_17_Part_Tracker_v1.CustomCode.19
Error Detail
============
##!Message:##! Object reference not set to an instance of an object.
##!Program:##! App.PartTracker.PartTrackerForm.EP.200.Customization.2024_01_17_Part_Tracker_v1.CustomCode.19.dll
##!Method:##! btnPartNum2_Click
Client Stack Trace
==================
at Script.btnPartNum2_Click(Object sender, EventArgs args)
at System.Windows.Forms.Control.OnClick(EventArgs e)
at Infragistics.Win.Misc.UltraButtonBase.OnClick(EventArgs e)
at Ice.Lib.Framework.EpiButton.OnClick(EventArgs e)
at Infragistics.Win.Misc.UltraButton.OnMouseUp(MouseEventArgs e)
at Ice.Lib.Framework.EpiButton.OnMouseUp(MouseEventArgs e)
at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)