Android Question Register as default Phone app

Philip Prins

Active Member
Licensed User
Longtime User
Hello

I have a IP Android phone and i want to detect onhook/offhook events;

According to the manual i need to set this in the manifest:

B4X: Copy
Register Customized Phone Service
<service android:name=“.DemoService” >
<intent-filter>
<action android:name=”com.gs.phone.service”/>
</intent-filter>
</service>

How to translate this to B4A manifest?

Regards,
Philip
 
try the manifest put the following command ...

Code: Copy
AddApplicationText(
<service android:name=".DemoService" >
  <intent-filter>
  <action android:name="com.gs.phone.service"/>
  </intent-filter>
</service>)

just remembering that DemoService is the name of your service module that will receive the intention, if it is another name. you must change it to the name that is in your project
 
Upvote 0
It should be:
Code: Copy
AddServiceText(YourService,
<intent-filter>
<action android:name=”com.gs.phone.service”/>
</intent-filter>
)
what is "YourService" ? "Starter" ? Error... cannot compile...

Packaging files. Error
AndroidManifest.xml:42: error: Error parsing XML: not well-formed (invalid token)
 
Upvote 0
what is "YourService" ? "Starter" ? Error... cannot compile...

Packaging files. Error
AndroidManifest.xml:42: error: Error parsing XML: not well-formed (invalid token)

just remembering that YourService is the name of your service module that will receive the intention, if it is another name. you must change it to the name that is in your project
 
Upvote 0
Back
Top