Skip to content
This repository has been archived by the owner on Oct 22, 2022. It is now read-only.

Uncaught TypeError: Cannot read property 'CallNumber' of undefined #24

Closed
swanandvaidya opened this issue Jun 8, 2016 · 12 comments
Closed

Comments

@swanandvaidya
Copy link

Error while calling this plugin i got error mentioned in title.
Please help me whats the problem is CallNumber.js is correct ??

@chiragandroid
Copy link

i have the same issue of Cannot read property 'CallNumber' of undefined

@CrackerakiUA
Copy link

I have same issue.
When i am doing cordova plugin list, among other plugins i see mx.ferreyra.callnumber 0.0.2 "Cordova Call Number Plugin".
When i am doing console.log(window.plugins); i don't see the plugin on android device, but when i am opening browser in pc i see it.

@kumquat601
Copy link

kumquat601 commented Jun 22, 2016

When I try this plugin in phonegap desktop app + phonegap app, it doesn't work. But after phonegap build, it works perfectly in android device (Andorid 4.4.2 Galaxy note 2).

@maximooo
Copy link

am having the same issue and it was working fine month ago .... can any one help me please i spent two day looking for solution ??? :(

@kumquat601
Copy link

@maximooo Do you check copying and pasting CallNumber.js into your www/ folder and importing into your index.html ???

@maximooo
Copy link

@kumquat0601 i did and still giving me same error anyone can help

@cozzbie
Copy link

cozzbie commented Dec 2, 2016

If window.plugins is returning undefined, try window.cordova.plugins

@606ep
Copy link

606ep commented Feb 3, 2017

It looks like installing plugin with:
cordova plugin add https://github.com/Rohfosho/CordovaCallNumberPlugin.git

fixes this issue

@thidasapankaja
Copy link

Today I added this plugin for my app. And I'm getting the error.

I added the plugin using cordova plugin add https://github.com/Rohfosho/CordovaCallNumberPlugin.git
and tried changing window.plugins to window.cordova.plugins too.
But still no good.

@admiremasaga
Copy link

change this

window.plugins.CallNumber.callNumber(onSuccess, onError, number, bypassAppChooser);

to

window.plugins.CallNumber.callNumber(onSuccess, onError, number, false);

this worked for me by adding false instead of bypassAppChooser

@abdelibbi
Copy link

Hi everyone !!
did someone found a solution to this issue ??
thanks for your reaction.

@LimitlessDonald
Copy link

Hello guys . Just in case someone is having this issue.
@abdelibbi @thidasapankaja
I found a solution to this. this worked :
<script src="cordova.js"></script>
I forgot to add that. Add it to the first file that loads, which is often index.html .
We often miss the simple things :)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests