Hi sir
i m tring to send SMS when Condition satifed but they send SMS again and again but i have to send SMS only one time if condition is satisfied . please suggest me the proper way to send SMS only once if condition is Satisfied.
You need a variable that keeps track of whether the message has been sent. Suppose it is called messageSent and it is set to false at the top of the program. Then when it comes time to send the message the code can be like this
if (messageSent == false) {
sendMessage();
messageSent = true;
}