Welcome, Guest
Username: Password: Remember me
  • Page:
  • 1

TOPIC: Copy Userclass from 4.6 project to 4.5 project

Copy Userclass from 4.6 project to 4.5 project 14 years 11 months ago #451

  • PeterO
  • PeterO's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 3
  • Karma: 0
I have tried to copy a userclass and function object from a 4.6 project to a 4.5 project but I cannot get the PLC-code in the PlcTemplate. I have tried to copy the PlcTemplate, by opening the .dbs-file and copy the PlcTemplate, and also tried to copy the code in the PlcTemplate to an existing empty PlcTemplate. Either I dont get any code in the C-arithm blocks, text in dSup, etc. or I dont get any code at all.

I know that I might not get all the references correct on the copy of the PlcTemplate but how can I at least get the code?
The administrator has disabled public write access.

Re:Copy Userclass from 4.6 project to 4.5 project 14 years 11 months ago #452

  • claes
  • claes's Avatar
  • OFFLINE
  • Platinum Boarder
  • Posts: 3178
  • Thank you received: 502
  • Karma: 133
Hello Peter,

Try to copy with copy/ignore_errors (from the commandline). This will execute the copy even if there are some unknown classes or other errors found during the copy.

You should not use the copy in the plc editor if you are copying between different versions, because this copy doesn't preform any version check or conversion of objects with modified classes. You should only use it if you are sure that no class is modified.

/Claes
The administrator has disabled public write access.

Re:Copy Userclass from 4.6 project to 4.5 project 14 years 11 months ago #453

  • PeterO
  • PeterO's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 3
  • Karma: 0
I have made the copy and manually changed all references in the wb_load-file (before I got many error messages when I was opening the classvolume).

When I try to open the code-block, of the userclass copied from another system, nothing happens. If i try to open it again the Class Editor crasches with Segmentation Fault.

Do I need to rewrite the program from start?

/Peter
The administrator has disabled public write access.

Re:Copy Userclass from 4.6 project to 4.5 project 14 years 11 months ago #454

  • claes
  • claes's Avatar
  • OFFLINE
  • Platinum Boarder
  • Posts: 3178
  • Thank you received: 502
  • Karma: 133
Hi,

I think the problem is that you have some functionobjects in the code that are unknown in the current project. When copying with the /ignore_errors switch, they will be replaced by objects of class $ClassLost, which are not always handled so well by the plc editor. Usually you can remove the $ClassLost objects from the configurator and then open the plceditor and fix the code.

/Claes
The administrator has disabled public write access.
  • Page:
  • 1
Time to create page: 8.797 seconds