Sunday, July 21, 2019

automation - Block all calls from area code unless in Contacts


I need a way to block all calls from an area code, unless the number is in my contact list. Anyone know of a way to do that?


I found plenty of apps that can block by area code, but they'll also block any of my contacts if they have that area code. I could add each of my contacts to a whitelist, but then I have to remember to do that each time I add a contact.



Answer



is the preferred option. Many apps are available. I prefer using MacroDroid , since it is free (upto 5 macros) and easy to learn.




You would need two macros for this



First macro would be to set a flag when the call is from an area code


Macro : Area code (name of macro as example)


Trigger:




  1. Call incoming → Select number → abc* ( where abc is numeric area code you are interested in and * is wildcard to represent any number . You need to know / experiment here - in my case I needed to type +<2digit country code><2 digit state code>< * wild card > to test with land line telephone




  2. You would need another similar trigger for identifying mobile numbers from that area if / as applicable





Action: Set Macrodroid Variable → New variable → from area code ( name of flag, it can be anything ) of type Boolean to true


Constraints: Leave blank


In the next macro we reject the call when the twin conditions of calling number is a non contact and from that area code are met


Macro : Reject call (name of macro as example)


Trigger: Call incoming → Select Contact → Non contact


Action:




  1. Call reject



    add constraint to this action by long pressing action




Macrodroid Variable →from area code = True (Macro only runs in this case, satisfying twin criteria conditions)



  1. Set Macrodroid Variable → from area code to false ( initialisation of flag )


Constraints: leave blank


I have only tested with landline available to me and it worked. Logic has been explained and you would need to configure with special attention to area codes of landline / mobile


No comments:

Post a Comment

samsung galaxy s 2 - Cannot restore Kies backup after firmware upgrade

I backed up my Samsung Galaxy S2 on Kies before updating to Ice Cream Sandwich. After the upgrade I tried to restore, but the restore fails ...