# Known Issues and Changes In Behavior

- As of release 4.1.0, Cognex Designer employs a background Garbage Collection technique by default for all new projects. See Scheduling Garbage Collection
- Auto Camera Detection only functions when Creating a New Project with Project Types.
- When migrating to another deployment system, you must recompile your Cognex Designer scripts before they can execute again.
- Cognex Designer abnormally terminates with an exception reporting a missing component (HMI.SetFocusOn()). A related message is found in the stack trace referencing a call to HmiFunctions.SetFocusOn
- In Recipes, when loading a large configuration (for example, the file size of the corresponding .json file is greater than 550M), an error such as Array dimensions exceeded supported range results.
- As of release 4.0.0, 2.x Cognex Designerproject sequences are replaced with a sub task.

- In release 4.0.0, tasks will take a longer time to execute in Test Mode than in release 2.x. This is due to increased Garbage Collection time in the development environment. As a result, always benchmark using a deployed application.

- Anti-Virus Software

  If anti-virus software is enabled for real-time protection it may also perform disk scans at a user-specified time. The disk scans may interfere with busy vision software applications. If so, consider disabling anti-virus software, or managing behavior in a manner appropriate for the application.

- The Expression Builder 'ItemAt($index, $array) ' Function Does Not Update the Returned Value When Items in the Collection Change

  When an "ItemAt($index, $array)" function is constructed in the Expression Builder, it will only update the returned value when the value of the "$index" tag changes, or a new array is assigned to the "$array" tag.

  The following C# script statements illustrate how to trigger a value change event:

      $index++;
      $array = { "one", "two", "three" };

  The following C# script statement will not trigger a value change event:

      $array[1] = "new value";

- VisionPro Tool Editor and ToolBlock Editor Controls Modifications While a Task is Running

  If a Page contains a VisionPro Tool Editor or VisionPro ToolBlock Editor element, they should be configured to not allow user interaction while the application sequence is running. Changes to these two types of controls can be made when the application is being modified at design time in the development environment, or in a deployed application, but only when the sequence using the tools is not running.

- Unable to Load Microsoft® SQL Server® Database That Contains decimal, money or smallmoney Column Data Types

  Designer does not support the decimal, geography, hirachyid, image, money, numeric, smallmoney , sql_variant, time, timestamp and xml data type parameters. When creating a database, ensure that these types are not used for columns, otherwise Designer will be unable to connect to the database.

  Designer only supports a sub-set of data types: bigint, binarybit, char, date, datetime, datetime2, datetimeoffset, float, int, nchar, ntext, nvarchar, real, smalldatetime, smallint, text, tinyint, uniqueidentifier, varbinary, varchar. Use Microsoft® SQL Server® 2008 Management Studio or later to create and edit SQL Server databases.

- Modifications to Page Elements During Test Mode Persist

  If an element on a Page (e.g. CheckBox, TextBox, etc.) is modified while in Test Mode, after exiting Test Mode, the element will not return to its state prior to entering Test Mode. To do so, the Designer OnStartup Script must be used to explicitly set the default values of Page elements. For example, if a Page contained a TextBox which should be blank at startup, the script would be:

      $Pages.Page.TextBox.Text = string.Empty;

- Return Statements in Designer Script Editor

  When wanting to use a return statement to exit a script function, use the "return null;" statement, instead of the "return;" statement. In the Designer Script Editor, scripts must always return an object, even though the signature of the script function returns void.

- Designer User Authentication and Authorization

  Designer offers a simple mode for user authentication and authorization, and is not intended to be used in environments that require high security. For a more secure authentication and authorization model, please use Active Directory.

- FFP Offline Requested Task Triggers for "Online" and "Offline" Status

  When implementing Factory Floor Protocol communications, it is important to note that within Designer, the OfflineRequested event is mapped into both a scriptable point called FFP Offline Requested and a Task Trigger called Devices.{CommCardName}.FfpOffineRequested. During execution, if the OfflineRequested event is fired, it will run the script registered to the scriptable point called FFP Offline Requested. At this point, the user can access the ReturnToPreviousState member of the argument, and determine the state of the device (False = Offline and True = Online). After this has occurred, the event triggers the FfpOfflineRequested Task Trigger. However, in this case, there is no way to determine the requested state, so any Task registered to run as a result of this trigger will be executed, regardless of the state.

- Uninstalling/Reinstalling Software on a Cognex Vision Controller

  In the event that the default installations of VisionPro or Designer need to be uninstalled and then newer versions installed, if a black desktop (no Cognex wallpaper) and a blank, blue Taskbar is encountered after the initial reboot after uninstalling/reinstalling, press the Windows Logo key to return to the Start screen, and then select the Desktop tile/icon to return to the correct Desktop.

- Changing the Primary Language of the Operating System on a Cognex Vision Controller

  If the primary language of the Operating System on a Cognex Vision Controller is changed (e.g. from English, the default language, to Simplified Chinese), the Vision Controller will need to be restarted. In the event that the desktop appears without the Cognex wallpaper and a blank, blue Taskbar is encountered after the reboot, press the Windows Logo key on your keyboard to return to the Start screen. Next, select the Desktop tile/icon to return to the correct Desktop.

- Factory Floor Protocol to Output Mappings

  A startup issue whereby if the mapping is set to falling-edge trigger, and the bit state is low, and another signal transition causes the factory protocol to push an update through the logic, the mapping will false-trigger one time and incorrectly fire the discrete event.

  This only occurs when the bit state starts low, and the mapping is set to falling-edge trigger, or the bit state starts high, and the mapping is set to rising-edge trigger.