Adding comments to RSL5K UDT import file.

TConnolly

Lifetime Supporting Member
Join Date
Apr 2005
Location
Salt Lake City
Posts
6,152
I have created a UDT import file for RSLogix 5000 that imports a bit overlay UDT. What I can't find is how to add documenting comments to the XML code for the UDT.

Does anyone know how to do this, I want to add a header section to the file that is ignored on import.

Code:
* I WANT TO INSERT SOME *
* REMARKS RIGHT HERE AT THE *
* TOP OF THIS FILE TO DESCRIBE THE FILE *
* AND VERSION *
 
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<RSLogix5000Content SchemaRevision="1.0" SoftwareRevision="16.03" TargetType="DataType" ContainsContext="true" Owner="Alaric" ExportDate="Mon Jul 07 14:39:05 2008" ExportOptions="Context">
<Controller Use="Context" Name="C4_50266KN_PRESS">
<DataTypes Use="Context">
<DataType Use="Target" Name="STATE" Family="NoFamily" Class="User">
<Members>
<Member Name="STATE_NO" DataType="DINT" Dimension="0" Radix="Decimal" Hidden="false"/>
<Member Name="STATE" DataType="INT" Dimension="0" Radix="Decimal" Hidden="false"/>
<Member Name="NOT_DEFINED" DataType="BIT" Dimension="0" Radix="Decimal" Hidden="false" Target="STATE" BitNumber="0"/>
<Member Name="STATE_1" DataType="BIT" Dimension="0" Radix="Binary" Hidden="false" Target="STATE" BitNumber="1"/>
<Member Name="STATE_2" DataType="BIT" Dimension="0" Radix="Binary" Hidden="false" Target="STATE" BitNumber="2"/>
<Member Name="STATE_3" DataType="BIT" Dimension="0" Radix="Binary" Hidden="false" Target="STATE" BitNumber="3"/>
<Member Name="STATE_4" DataType="BIT" Dimension="0" Radix="Binary" Hidden="false" Target="STATE" BitNumber="4"/>
<Member Name="STATE_5" DataType="BIT" Dimension="0" Radix="Binary" Hidden="false" Target="STATE" BitNumber="5"/>
<Member Name="STATE_6" DataType="BIT" Dimension="0" Radix="Binary" Hidden="false" Target="STATE" BitNumber="6"/>
<Member Name="STATE_7" DataType="BIT" Dimension="0" Radix="Binary" Hidden="false" Target="STATE" BitNumber="7"/>
<Member Name="STATE_8" DataType="BIT" Dimension="0" Radix="Binary" Hidden="false" Target="STATE" BitNumber="8"/>
<Member Name="STATE_9" DataType="BIT" Dimension="0" Radix="Binary" Hidden="false" Target="STATE" BitNumber="9"/>
<Member Name="STATE_10" DataType="BIT" Dimension="0" Radix="Binary" Hidden="false" Target="STATE" BitNumber="10"/>
<Member Name="STATE_11" DataType="BIT" Dimension="0" Radix="Binary" Hidden="false" Target="STATE" BitNumber="11"/>
<Member Name="STATE_12" DataType="BIT" Dimension="0" Radix="Binary" Hidden="false" Target="STATE" BitNumber="12"/>
<Member Name="STATE_13" DataType="BIT" Dimension="0" Radix="Binary" Hidden="false" Target="STATE" BitNumber="13"/>
<Member Name="STATE_14" DataType="BIT" Dimension="0" Radix="Binary" Hidden="false" Target="STATE" BitNumber="14"/>
<Member Name="STATE_15" DataType="BIT" Dimension="0" Radix="Binary" Hidden="false" Target="STATE" BitNumber="15"/>
<Member Name="TRANS" DataType="INT" Dimension="0" Radix="Decimal"/>
<Member Name="BEGIN_STATE_1" DataType="BIT" Dimension="0" Radix="Binary" Hidden="false" Target="TRANS" BitNumber="1"/>
<Member Name="BEGIN_STATE_2" DataType="BIT" Dimension="0" Radix="Binary" Hidden="false" Target="TRANS" BitNumber="2"/>
<Member Name="BEGIN_STATE_3" DataType="BIT" Dimension="0" Radix="Binary" Hidden="false" Target="TRANS" BitNumber="3"/>
<Member Name="BEGIN_STATE_4" DataType="BIT" Dimension="0" Radix="Binary" Hidden="false" Target="TRANS" BitNumber="4"/>
<Member Name="BEGIN_STATE_5" DataType="BIT" Dimension="0" Radix="Binary" Hidden="false" Target="TRANS" BitNumber="5"/>
<Member Name="BEGIN_STATE_6" DataType="BIT" Dimension="0" Radix="Binary" Hidden="false" Target="TRANS" BitNumber="6"/>
<Member Name="BEGIN_STATE_7" DataType="BIT" Dimension="0" Radix="Binary" Hidden="false" Target="TRANS" BitNumber="7"/>
<Member Name="BEGIN_STATE_8" DataType="BIT" Dimension="0" Radix="Binary" Hidden="false" Target="TRANS" BitNumber="8"/>
<Member Name="BEGIN_STATE_9" DataType="BIT" Dimension="0" Radix="Binary" Hidden="false" Target="TRANS" BitNumber="9"/>
<Member Name="BEGIN_STATE_10" DataType="BIT" Dimension="0" Radix="Binary" Hidden="false" Target="TRANS" BitNumber="10"/>
<Member Name="BEGIN_STATE_11" DataType="BIT" Dimension="0" Radix="Binary" Hidden="false" Target="TRANS" BitNumber="11"/>
<Member Name="BEGIN_STATE_12" DataType="BIT" Dimension="0" Radix="Binary" Hidden="false" Target="TRANS" BitNumber="12"/>
<Member Name="BEGIN_STATE_13" DataType="BIT" Dimension="0" Radix="Binary" Hidden="false" Target="TRANS" BitNumber="13"/>
<Member Name="BEGIN_STATE_14" DataType="BIT" Dimension="0" Radix="Binary" Hidden="false" Target="TRANS" BitNumber="14"/>
<Member Name="BEGIN_STATE_15" DataType="BIT" Dimension="0" Radix="Binary" Hidden="false" Target="TRANS" BitNumber="15"/>
</Members>
</DataType>
</DataTypes>
</Controller>
</RSLogix5000Content>
 
1. What happens if you attempt to import the file directly as you have shown it?

2. if you want to add some information in XML format I suggest using 'XMLNotepad', a free utility from Microsoft. http://www.microsoft.com/downloads/...49-787d-4118-ba5f-4f30fe913628&displaylang=en

3. Try adding in your comments at various places but I would suspect that the most acceptable would be after the xml declaration at the top and the next line declaring 'RSLogix5000 Content'

4. I understand that future versions of RSLogix will allow creating and editing the overlay type UDTs from within RSLogix.
 
Greetings Bernie.

The UDT bit overlay imports just fine without the comments. However I wanted to add documentation to the file for future reference without having to delete lines should I reuse the file.

Yeah, I know, thats my OCD. 🍺

The normal XML comment format is <!-- Comment --> and it cannot be on the first line. However anywhere in the file causes it to fail, even when placed at the end of the file. I guess its possible that the import doesn't support the XML comment.

Overlay support in future versions would be a good thing. Another thing that is needed is UDT aliasing.
 
Last edited:

Similar Topics

Hi PLCs.net! I'm using Studio5k V32, and I have an EDS file for the Fanuc 30r-ib plus controllers. I have an excel spreadsheet with bitwise...
Replies
1
Views
1,442
I'm using a global DB as the i/o for some FBs (thank you, JesperMP). As I only need six bits for each FB I started with a byte as the input/output...
Replies
8
Views
3,209
Hi, I use Excel to write some routines and was wondering if it is possible to add rung comments when doing so? Excel function: ="MOV "&[@[Range...
Replies
2
Views
2,546
I am using RSLogix500 V.8.10.00 (CPR9). I know how to add comments or discriptions to the programs on my computer, but how can download them to...
Replies
1
Views
1,890
I'm trying to add comments to a program already written, doing what I can to make it easier to understand what the coils actual refer to. But I...
Replies
3
Views
4,372
Back
Top Bottom