Dear Community User! We will start the migration process in one hour.
The community will be then in READ ONLY mode.
Read more: Important information on the platform change.

cancel
Showing results for 
Search instead for 
Did you mean: 
SOLVED

Import PLC Open xml file gives an error: Object reference not set to an instance of an object

Import PLC Open xml file gives an error: Object reference not set to an instance of an object

Tuli
New Poster

With the ctrlX PLC 1.18 version we can import a PLC Open xml file without problems. When we import the same file with the ctrlX PLC 1.20 version we get an error: Object reference not set to an instance of an object. If we remove variables from type POINTER_TO_XXXX in the variable declaration then the PLC Open XML import goes well. It seems that in the ctrlX PLC 1.20 something has been changed regarding PLC Open XML import.

3 REPLIES 3

HmiGuide
Community Moderator
Community Moderator

1. When do you get the error? While importing or compiling?
2. What is the exact error message? It could be that the compiler checks are extend in the new version, which causes the error.
3. I can import the file in ctrlX PLC 1.20.0 without an error. Which exact version is used?
4. I can't find any text "POINTER_TO" in the imported content. Have you uploaded the file which causes the problem or the purged one?

Some general hints to your topic:

You should NOT use the PLC Open format, to exchange data between any CoDeSys implementations, because PLC Open does not support all CoDeSys features. This means some stuff like visu can't be exchanged at all. The code of other features which are extensions of CoDeSys and not included in PLC Open, may be changed while exporting.

Use Import/Export or Copy/Past with 2 PLC Engineering instances instead.

Good morning

We are with a customer trying to perform a migration of different PLC modules (FB, FC) made on an XM22 to the PLC application of a ctrlX with version 1.20 and at the time of importing them from the XML file generated in the XM22 some of the function blocks or functions are not accepted by the ctrlX.

JordiLaboria_0-1697625641104.png

The following error appears during the import process:

JordiLaboria_1-1697625641107.png

Doing tests, I have found that one of the problems why the import does not seem to work, is because of these instructions that appear blocked with the "///" and that contain the POINTER TO WORD statement.

With these lines locked, the import works correctly

JordiLaboria_2-1697625641110.png

JordiLaboria_4-1697625709340.png

As you can see, I have the same problem described earlier in the post

I also can't copy paste directly from Indraworks to ctrlX PLC, as drag and drop doesn't seem to work.

The Import/Export options also don't work. Any ideas?

Is there anything missing from ctrlX when importing XML files?

Best Regards

Jordi Laboria

E-Mail: jordi.laboria@boschrexroth.es

https://www.youtube.com/channel/UCzE-ieCIkyMsuvyE0UDji9g

DCET/SLF4-ES

 

Please read this article, which describes a better way to convert code.

https://developer.community.boschrexroth.com/t5/ctrlX-PLC/Import-PlcOpen-export-from-IndraWorks-Engi...

Icon--AD-black-48x48Icon--address-consumer-data-black-48x48Icon--appointment-black-48x48Icon--back-left-black-48x48Icon--calendar-black-48x48Icon--center-alignedIcon--Checkbox-checkIcon--clock-black-48x48Icon--close-black-48x48Icon--compare-black-48x48Icon--confirmation-black-48x48Icon--dealer-details-black-48x48Icon--delete-black-48x48Icon--delivery-black-48x48Icon--down-black-48x48Icon--download-black-48x48Ic-OverlayAlertIcon--externallink-black-48x48Icon-Filledforward-right_adjustedIcon--grid-view-black-48x48IC_gd_Check-Circle170821_Icons_Community170823_Bosch_Icons170823_Bosch_Icons170821_Icons_CommunityIC-logout170821_Icons_Community170825_Bosch_Icons170821_Icons_CommunityIC-shopping-cart2170821_Icons_CommunityIC-upIC_UserIcon--imageIcon--info-i-black-48x48Icon--left-alignedIcon--Less-minimize-black-48x48Icon-FilledIcon--List-Check-grennIcon--List-Check-blackIcon--List-Cross-blackIcon--list-view-mobile-black-48x48Icon--list-view-black-48x48Icon--More-Maximize-black-48x48Icon--my-product-black-48x48Icon--newsletter-black-48x48Icon--payment-black-48x48Icon--print-black-48x48Icon--promotion-black-48x48Icon--registration-black-48x48Icon--Reset-black-48x48Icon--right-alignedshare-circle1Icon--share-black-48x48Icon--shopping-bag-black-48x48Icon-shopping-cartIcon--start-play-black-48x48Icon--store-locator-black-48x48Ic-OverlayAlertIcon--summary-black-48x48tumblrIcon-FilledvineIc-OverlayAlertwhishlist