Ketan Patil
Posts: 0
Joined: Tue Dec 03, 2013 1:10 pm

how to make a phone call

on click of label i set local storage variable pn1 with phone no. from lable.

on pop up i put a button and in click event put js
window.location.href='tel:' + pn1;

after running app on real phone it is not working

Igor
Posts: 0
Joined: Tue Apr 02, 2013 12:05 pm

how to make a phone call

To get value from local storage please use next code:
pre
localStorage.getItem('pn1');
/pre
Your code should be like this:
pre
var phone=localStorage.getItem('pn1');
window.location.href='tel:' + phone;
/pre

Ketan Patil
Posts: 0
Joined: Tue Dec 03, 2013 1:10 pm

how to make a phone call

i tried it on phone .
it just send no. 5 to call.

if i put direct no. instead of local storage i will send that no. to call.

Igor
Posts: 0
Joined: Tue Apr 02, 2013 12:05 pm

how to make a phone call

Please try to put next code on button click event:
pre
window.location.href='tel:8805693250';
/pre

Does it work for you?

Ketan Patil
Posts: 0
Joined: Tue Dec 03, 2013 1:10 pm

how to make a phone call

as i told u , i want to dial the no. fetched from database not a fix no.

Ketan Patil
Posts: 0
Joined: Tue Dec 03, 2013 1:10 pm

how to make a phone call

the person is not knowledgeable

Igor
Posts: 0
Joined: Tue Apr 02, 2013 12:05 pm

how to make a phone call

Thank you for your feedback. Your opinion is very important for us.

Kateryna Grynko
Posts: 0
Joined: Thu Nov 15, 2012 9:13 am

how to make a phone call

Hi Ketan,

What data do you store in Database?
Could you show us a screenshot of service response please?

Ketan Patil
Posts: 0
Joined: Tue Dec 03, 2013 1:10 pm

how to make a phone call

I am storing number.
Fetching it to a label.
After touching label popup is opening.
On pop up there is a button for calling the number.

Kateryna Grynko
Posts: 0
Joined: Thu Nov 15, 2012 9:13 am

how to make a phone call

Hi Ketan,

Let's try the following:prewindow.open("tel:" + Appery('label').text());/preWhere 'label' is a label where you mapped a number beforehand.

Return to “Issues”