MS Excel for generating RSL5000 rungs

DairyBoy

Member
Join Date
Jun 2007
Location
UK
Posts
393
I'm looking for a way to export/edit/import a single rung via excel so that I can use the auto increment facililty to create more rungs for importing back into my 5000 program. I had a go but it all ended up in one cell. Is there a format option that will place the results vertically on the spreadsheet? I'm guessing that this is what I need but as usual, all answers welcome. Thanks.
 
I've done this using the concatenate function in excel. Break your code up in similar chunks, ie, column A might be SOR XIC, then column B an address, column C OTE, column D an address, and column E contains EOR.

It'll take a few AND and CONCATENATE functions to get everything into one big text string in one cell, then copy, double click the rung in RSLogix and paste. Voila.

Having everything in one cell is what you want, as long as you separate the rungs by using SOR and EOR (start of rung, end of rung).
 
If you copy the text string from a single rung in RSLogix you can paste that to a cell in Excel. From that point you need to use the DATA --> "text to columns" feature to break the text at the numerical points. From there you can use the auto increment feature.

You aren't done though, you need to then rebuild that text so you can paste it into RSLogix. So you need to "concatenate" those multiple columns together back to a single cell to copy and paste.

That works great, but what if you want to do multiple rungs?

Well, you need to concatenate again to include the next rung of logic, but don't forget to manually add the "SOR" (Start Of Rung) and "EOR" (End Of Rung) functions to create the break points between rungs.

It wall works rather nicely, however if you want to expand your abilities of using Excel to auto-generate your code start learning VBA and how to create .L5X files. Then you can import the file right into the code. If you are good you could include comments, complex rungs....
 
That's brilliant! (y)(y)(y) "EOR" turns out to be a ; and SOR seems to be three spaces but wow that's quick :geek: Loads of rungs in seconds. Thank you.
 

Similar Topics

Hi, I'm trying to export data from a DataGrid to Excel using VBA, but I'm getting an error "Object doesn't support this property or method". The...
Replies
0
Views
98
I don't know if this is the right place for the subject at least I'll try. The company has one of the oldest computers that is a master Windows...
Replies
5
Views
772
Hi, I'm just looking for a simple way to make a button in excel (via VBA I presume) to toggle a bit in RSLogix 5000. I just got FactoyTalkLinx...
Replies
9
Views
583
Hello, I want to send the data from Rslogix500 to Excel. I created a connection between RSlinx and Excel. The values in Excel automatically...
Replies
5
Views
1,212
Hi guys, Im back again, this time I cannot minimized excel even though i put 6 on the exec mode.. this is my cicode.. Exec("C:\Program...
Replies
1
Views
1,099
Back
Top Bottom