Intent to send SMS including a comma (how to escape character)

Gaétan Tanguay

New member
Use case: I want to have my Home assistant companion app sending an intent to Macrodroid in order to have MD send a SMS to someone.

Problem: If I have a message including a comma (e.g. "Hi, I'm coming home.") I have an error message and the message is not sent. I searched but it seems impossible to send the comma ',' character in a string to MD. But if I send the message "Hi I'm coming home" it works perfectly.

How can I include a comma in a string so MD can put it in the the string variable and then send the SMS message "Hi, I'm coming home" or whatever other message in fact that will include all sorts of characters?
 

hsurB

Well-known member
Seems like text manipulation action could solve it. Find another symbol you will use as ',' when sending variable to macrodroid that won't cause problems and use text manipulation action in macrodroid to make changes inside variable
 

Elieston

Member
You use 2 spaces "" and do MacRodroid Replace the 2 spaces "" by comma and space "," before sending.
As suggested above use text manipulation to do this
 

MacroDroidDev

Administrator
Staff member
I'm not aware of any issues sending a comma in an SMS message and in fact I've just tried it and it worked fine for me. Is this definitely a standard ASCII comma character and what error message do you see?
 

Endercraft

Moderator (& bug finder :D)
I'm not aware of any issues sending a comma in an SMS message and in fact I've just tried it and it worked fine for me. Is this definitely a standard ASCII comma character and what error message do you see?
I tried it too, I'm pretty sure it's the intent sent by the other app that doesn't support or maybe MacroDroid receives it in a weird way.
 
Top