Split a string into many string! - Printable Version +- Logic Machine Forum (https://forum.logicmachine.net) +-- Forum: LogicMachine eco-system (https://forum.logicmachine.net/forumdisplay.php?fid=1) +--- Forum: Scripting (https://forum.logicmachine.net/forumdisplay.php?fid=8) +--- Thread: Split a string into many string! (/showthread.php?tid=1121) |
Split a string into many string! - phongvucba - 01.12.2017 Please help me, if anybody can do! I have a any string "abcd12345678901234567". Now I want to split the strings into two strings: - The first string from the first letter to the 14th character. "abcd1234567890" - The last string is from the 15th character to the end of the string. "1234567". - Count the number of characters in the string "abcd12345678901234567". Because this string is always changing. so I need the last string to get the correct value ending. Who can help me? thank you very much. RE: Split a string into many string! - admin - 01.12.2017 Code: str = 'abcd12345678901234567' RE: Split a string into many string! - phongvucba - 01.12.2017 Thank you very much admin! I have a little question! please help me! I have a string "Hold me tight or don't", but when displayed on the screen KNX it appears "Hold me tight or don't". Does KNX have no unicode code? and it transforms code(') into (' ) To be correct, please help me write a script: -Search strings (' ) in string "Hold me tight or don't" and then change to ('). Thank so much! RE: Split a string into many string! - Erwin van der Zwart - 01.12.2017 Hi, Use this: Code: str = 'Hold me tight or don't' Other metadata options are in this function: Code: function unescapemetadata(str) BR, Erwin RE: Split a string into many string! - phongvucba - 02.12.2017 very good! I very thank friend! |