(0)| 8/28/2017 8:03 PM | |
|
Posts: 5 Rating:
|
I needed a function which will copy a string to a character array. I found one on here for Step 7 Ver 5, but could not find one for TIA. The one on here for Step 7 Ver 5 was protected, so I couldn't copy it to TIA. So I wrote the function myself. Figured others might benefit from it so I'm attaching it here. It is also available on our web site at: http://files.rubeautomation.com/S7-300%20Strg_To_Char%20170825.zap13
AttachmentS7-300 Strg_To_Char 170825.zip (365 Downloads) |
This contribution was helpful to
|
|
| 8/29/2017 10:43 AM | |
|
Posts: 101 Rating:
|
It is 2017, pointers are archaic and should be avoided. Thanks for sharing your work though I'm sure it will be usefull for some people. This is why I wrote your the same in SCL with an AT overlay, it's literally 3 lines. (Granted I didn't return all the outputs the same way you did, outputs you might need such as the number of characters but you can adapt as you see fit).
AttachmentS7-300 Strg_To_Char2 170829.zip (380 Downloads) |
Last edited by: Jeremy Mahieu at: 8/29/2017 10:44:50 AMLast edited by: Jeremy Mahieu at: 8/29/2017 10:45:30 AM |
|
| 2/13/2025 7:46 PM | |
|
Joined: 1/14/2020 Last visit: 2/14/2025 Posts: 1 Rating:
|
ok and what does the code look like to convert the char back into a string in scl? |
Follow us on