• Which the release of FS2020 we see an explosition of activity on the forun and of course we are very happy to see this. But having all questions about FS2020 in one forum becomes a bit messy. So therefore we would like to ask you all to use the following guidelines when posting your questions:

    • Tag FS2020 specific questions with the MSFS2020 tag.
    • Questions about making 3D assets can be posted in the 3D asset design forum. Either post them in the subforum of the modelling tool you use or in the general forum if they are general.
    • Questions about aircraft design can be posted in the Aircraft design forum
    • Questions about airport design can be posted in the FS2020 airport design forum. Once airport development tools have been updated for FS2020 you can post tool speciifc questions in the subforums of those tools as well of course.
    • Questions about terrain design can be posted in the FS2020 terrain design forum.
    • Questions about SimConnect can be posted in the SimConnect forum.

    Any other question that is not specific to an aspect of development or tool can be posted in the General chat forum.

    By following these guidelines we make sure that the forums remain easy to read for everybody and also that the right people can find your post to answer it.

ADE-GP Exception

scruffyduck

Administrator
Staff member
FSDevConf team
Resource contributor
Messages
34,981
Country
unitedkingdom
Roby has sent this exception:

Code:
System.ArgumentOutOfRangeException: Waarde van -8 is niet geldig voor LargeChange. LargeChange moet groter dan of gelijk aan 0 zijn.
Parameternaam: LargeChange
   bij System.Windows.Forms.ScrollBar.set_LargeChange(Int32 value)
   bij ADE_GroundPolys.GPEditor.CalcScrollBars()
   bij ADE_GroundPolys.GPEditor.ResizeDialog()
   bij ADE_GroundPolys.GPEditor.Mybase_Resize(Object sender, EventArgs e)
   bij System.Windows.Forms.Control.OnResize(EventArgs e)
   bij System.Windows.Forms.Form.OnResize(EventArgs e)
   bij System.Windows.Forms.Control.OnSizeChanged(EventArgs e)
   bij System.Windows.Forms.Control.UpdateBounds(Int32 x, Int32 y, Int32 width, Int32 height, Int32 clientWidth, Int32 clientHeight)
   bij System.Windows.Forms.Control.UpdateBounds()
   bij System.Windows.Forms.Control.WndProc(Message& m)
   bij System.Windows.Forms.ScrollableControl.WndProc(Message& m)
   bij System.Windows.Forms.ContainerControl.WndProc(Message& m)
   bij System.Windows.Forms.Form.WndProc(Message& m)
   bij System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
   bij System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   bij System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)

Don

I have had a similar exception which I just managed to repeat:

Code:
System.ArgumentOutOfRangeException: Value of '1' is not valid for 'Value'. 'Value' should be between 'minimum' and 'maximum'.
Parameter name: Value
   at System.Windows.Forms.ScrollBar.set_Value(Int32 value)
   at ADE_GroundPolys.GPEditor.CalcScrollBars()
   at ADE_GroundPolys.GPEditor.Zoom(Boolean bZoomIn, Single nChange)
   at ADE_GroundPolys.GPEditor.pbData_MouseWheel(Object sender, MouseEventArgs e)
   at System.Windows.Forms.Control.OnMouseWheel(MouseEventArgs e)
   at System.Windows.Forms.ScrollableControl.OnMouseWheel(MouseEventArgs e)
   at System.Windows.Forms.Control.WmMouseWheel(Message& m)
   at System.Windows.Forms.Control.WndProc(Message& m)
   at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
   at System.Windows.Forms.ContainerControl.WndProc(Message& m)
   at System.Windows.Forms.Form.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)

I did this by opening the editor and resizing it. I then used the mouse wheel to zoom the Editor display. The exception occurred as the horizontal appeared
 
And here is a "Hang" when entering the editor for a gp_PatternedLines_40f/Single(Yellow).

"Maximum zoom has been exceeded". Clicking OK caused the error to be displayed again. Needed to crash ADE.



Repeatable until I deleted the line and re-drew it.
 
Last edited:
"Maximum zoom has been exceeded". Clicking OK caused the error to be displayed again. Needed to crash ADE.
Curious that you and Roby have both come up with a similar issue (that I can't duplicate). As for having to crash ADE to get out, ADE_GP attempts to recovere from that situation (out of memory) by redrawing at half the zoom level. But obviously, that didn't work in this case.

I've just tried a few tests with very long, multi-segment lines and nothing goes amiss. So, if any of you can tell me how to reliably repeat the problem, please do so.

I did this by opening the editor and resizing it. I then used the mouse wheel to zoom the Editor display. The exception occurred as the horizontal appeared
Jon, the two exceptions you noted could indicate the problem in the attempted recovery from the "maximum zoom" error.

Don
 
Hello Don,

Attached is the asm file of when the editor threw an exception upon drawing a multisegmented line with patterned lines.
Hope you can learn something from the asm file if not I can send you the ADE workfile (which is a lot bigger of course).
 

Attachments

I was unable to reproduce the "maximum Zoom exceeded" error. However, I did find an issue that causes a similar exception when the dialog is minimized and that I've fixed in 0.0.64. Curiously, Windows reports a negative size for the editor display area when the dialog is minimized and the editor couldn't handle that.

Why is this latter issue relevant? In the exception message reported by Roby and subsequently posted by Jon, this is exactly what happened, i.e., the display area width was reported as negative. Why? I haven't the faintest idea, because it's Windows that is reporting it. But, perhaps the fix I've applied will work in other situations as well. Jon, the exception you generated was due to a similar cause.

At this point, no one has told me how to reliably force the exception. So, I'm not sure it's completely fixed. Should it happen again, please try to devise a method to force it.

Don
 
Try this, Don:

Zoom in on the groundline in the screenshot and click on it.
you will get this:

63maxzoomexceeded3.jpg


and ADE freezes.
 
Doesn't cause an exception on my system. What's in the exception message?

DOn
 
There is only this pop up window that says maximum zoom has been exceeded.
I haven't yet updated to your newest version though.
 
I tried with the previous release and it doesn't make any difference. Perhaps its machine-related.

Don
 
I am getting an odd behavior in 0.0.64.

I created a new line, and selected a texture (40F) and line style (double yellow). I then clicked in the white area of the display (as if I was going to select some vertices) and get this message:

attachment.php


When I click OK and then OK my line style has been lost, both here and in ADE. It happens all the time when I try this.

Hope this helps,
 

Attachments

  • ade_gp_64_1.jpg
    ade_gp_64_1.jpg
    69 KB · Views: 725
Sorry, Tom. That's a little "wrinke" in the logic to preserve line types with moves along the axis of the line but not across.

Just be careful where you click.

Don
 
I think it is using the wrong axis.

I am attempting to align the texture to the left of the line. but, having selected the horizontal move button, as soon as I click I get "Line Pattern/Style deselected".



This worked in previous versions.
 
No. It's just wrong. (I did'nt take intoo account that the texture is not always shown full-size. I'll be re-releasing in a couple of minutres.

Don
 
OK. Here is another one.

I thought the area might not be flat so I added a flatten but it made no difference.

I surrounded the runway with a polygon but there seems to be an extra triangle:



Zoomed-in:



and in FSX:

 
There's no vertex in any likely position, so it must be the 100m chunking.

The earlier probelm I thought I had with the line vertex moves was not a logic problem. Rather, it was due to some old data I had in my test airport.

SO, I'm going to re-enable it, but disable the 100m. chunking in a release in the next couple of minutes.

Don
 
I think I can confrim that the problem is in the 100m chunking algorithm.

It seemed to work well on that very complex poly you placed at EFMA, but it still seems to have difficulty with verY large polys.

Tomorrow!

Don
 
I'm not sure how I can be more careful.

I select all the vertices (if even touching the white area doesn't give me the error), I push the up/down button (vertical lines), and then drag the top of the line to the edge of the texture. The error message immediately pops up. I didn't move the line horizontally at all (I couldn't, since I used the up/down move button).
 
Tom, if you are working with an object created before yesterday, I suggest you compile the file before doing anything else. That will update all the object data. The try again

Don
 
Hi,

I'm working with brand new lines. I also compiled the airport in case there was something remaining.

With 0.0.66 I don't get the error when I just click on the white area, but I do get the error when I drag a vertical line vertically so the top end is at the top edge of the texture. It is a long line with a width of 1 foot.
 
This may be a complete red herring and I have probably completely missed the point :o

I notice on the zoom errors that ADE is not that much zoomed. ADE can zoom to 100 and the screenshots show values less than 10. I am also not sure how the zoom level in ADE can affect the GP Editor since no information related to that is passed to the Editor.
 
Back
Top