Anyone else getting this error when trying to save to the EZ-Cloud App Store ?
This just started to happening. I have been able to save in the past.
Thank you Rich
Version: 2018.05.01.00
System.NullReferenceException: Object reference not set to an instance of an object.
at EZ_Builder.UCForms.FormCameraDevice.GetConfiguration()
at EZ_Builder.UCForms.FormMaster.get_ConfigurationForm()
at EZ_Builder.FormMain.z1HXSaOIKq()
at EZ_Builder.FormMain.jGMXdLptVn()
at EZ_Builder.FormMain.SSK5Dl5wsq(Object , EventArgs )
at System.EventHandler.Invoke(Object sender, EventArgs e)
at System.Windows.Forms.RibbonItem.OnClick(EventArgs e)
at System.Windows.Forms.RibbonButton.OnClick(EventArgs e)
at System.Windows.Forms.RibbonMouseSensor.Control_MouseClick(Object sender, MouseEventArgs e)
at System.Windows.Forms.MouseEventHandler.Invoke(Object sender, MouseEventArgs e)
at System.Windows.Forms.Control.OnMouseClick(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.Ribbon.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)
Asked
— Edited
This is from your diagnostic log:
Unfortunately i don't know where the code is being called - so you'll have to look through your project and find what ControlCommand is sending a 0 to a parameter of the camera.
Rich
R2D2_AddAutomousmode_cameraovrlay_MotionDetectV11-Copy.EZB
DJ Attached here is the things that I tried and the errors that I still received. Please review this also.
EZBCloudApp_Errors_V2-07082018.pdf
a fixed version of your project:
R2D2_AddAutomousmode_cameraovrlay_MotionDetectV11-FIXED.ezb
Can you please confirm is ok ?
I will download and test tonight. Could you enlighten us as to what you did that should resolve the issue ? Added code, removed code, etc.
RSmith
If it helps.
troubleshooting:
The error occurs when you open the project:
Code:
1)
So there is no code i.e. script execution must be something on the file.
2)
Can't be a generic corruption, otherwise the Project content i.e. XML can't be correctly loaded/parsed.
3)
Code:
Is related to the camera control
4)
Code:
ARC is trying to assign a value to an UI component i.e. TrackBar
5)
Code:
The invalid value is a "0" and is not between a Minimum and Maximum. Maybe the minimum is more than zero, maybe a "1" ?
6)
I opened the your project with a text editor, and i copied the camera code to another file.
Code:
Then i searched for a zero value parameter (constrained to the camera settings content file): ">0< "
we are looking for a TrackBar UI component: CameraImageBrigtness and GridTransparency match our search.
The next step: discover the minimum values, so i created a new project with a camera control with all the trackbars set to the minimum value, then isolated the camera settings to a file, search for zero parameter again.
As you can see both are not there:
minimum values:
<CameraImageBrightness>-150</CameraImageBrightness>
<GridTransparency>1</GridTransparency>
So using "Sherlock Holmes" deduction method: i assumed the zero is between CameraImageBrightness (-150;150) and GridTransparency has an invalid value.
Changing the original project to "1" fixes the load and as consequence the save process. Save requests Camera control's get configuration and during the execution tries to set the trackbar again with zero failing to save, but the problem is already seen during the initial load.
The next question: Why is broken ?
If you didn't change the value by hand... my guess is: zero is the default value for an integer, ARC code during the save/Serialization process allowed the zero to go through to the file, and after that the camera settings became invalid.
It's only a guess... DJ has access to the code
That explanation was great, that was what I was hoping for. As I have been a programmer for 6 years and now doing Powershell and VBScript it makes sense. Also thank you for letting me know that we can open the project in a text or other editor (Visual Studio, Notepad++) I will look at that along the way now. So that we I make major changes to something else in the code I can verify these and other settings.
I do remember turning the grid off/on several times during the project length. I might have adjusted the camera brightness once. It is hard to remember doing that one. Could these setting have changed when I went from Direct network connection to WIFI ? If you noticed that the connect blue button is at a 192.168.1.1 address and Video Device is at 10.0.0.8. Thought that this box should match the current IP scheme. The 192.168 is my WIFI address, and the 10.0 is when the EZB connected directly to my home network.
I loaded the fixed version here in my office on a laptop with a freshly installed ARC and It let me save to the Cloud and directly on the laptop. The bigger test is when I get home and have it hooked up the the EZB controller and camera. I will keep up to date with everyone on that tonight.
@Richard R
I did what you did by taking out the camera control and putting it back into the project. However now I can't connect to the EZB using my WIFI connection. I am going to work on this some more tonight. I am not sure if I was to tired or just frustrated with the whole thing to see the real picture. That is why I am going to work on it more tonight. I connected the WIFI from EZB to my laptop first then tried to connect using ARC. It would always error out and never connect. the only thing that I didn't do was reboot the laptop several times. I re-connected about 6 times and no luck.
Thank you for your assistance.
@Richard R
Your fix of removing the camera app and added it back would fix the issue. The not connecting issue was an IP address conflict between Spectrum and EZB. Both are using the 192.168.1.1 IP address. Anyway I have resolved that IP address conflict and the camera is working and I can save to the cloud and locally.
@PTP
Your fix by removing the zero within the camera code also fixed the issue. I had to adjust the video device box IP to match what I was using for the connection button box string. To get the camera working again.
@Richard fix was the quick fix for the issue. @PTP was more of a programmers fix for the issue. Since DJ is involved I am glad for the programmer fix. Both fixes will help others in the long run.
I hope that DJ has an answer as to what might have happened to cause this. Waiting to hear from you DJ.
I want to thank @DJ, @Richard and @PTP for help in resolving this issue. It is a good feeling that there are other that are will to jump in and help.
I have installed a fresh copy of ARC. I installed that just a few days ago. I also renamed my project to shorten its name.
@DJ, is there an issues with the path name and file name being longer that 256 characters total ? Microsoft had/has that limitation. I know it was a limitation with Windows 7 and Windows Server 2008. The reason that I mention this is I am sure that I am very close to this limitation with my path name where my project is located.
Just try to think out loud and use the 30 plus year experience within the IT Technology field.