skype or callto using Skype or voipbuster

Hi,
i’m trying to use skype or voipbuster to make phonecall right out our CRM

Skype uses: skype:+31546641144?call
and also: callto:+31546641144?call (which can be used by voipbuster also)

but when I call this in the showURL method, like this:

application.showURL('skype:' + vPhoneNumber + '?call')

it does not work!

both developer AND client are saying this (look at image)
anyone?

Are you sure you shouldn’t be using skype://+31546641144?call
Thus with 2 slashes ?

I already tried that ;-)

the same result, I think anything without http://, will fail!

oke, I worked around the ( :evil: ) thing! ;-)

THIS works:

var vPhoneNumber = arguments[0]
var vString = 'skype:' + vPhoneNumber + '?call'

if(utils.stringMiddle(application.getOSName(),1,7) == "Windows") {
   application.executeProgram('rundll32', 'url.dll,FileProtocolHandler',vString)
} else { 
	application.showURL(vString)
}

this saves others some time! ;-)

Hi Harjo,

Harjo:
oke, I worked around the ( :evil: ) thing! ;-)

THIS works:

var vPhoneNumber = arguments[0]

var vString = ‘skype:’ + vPhoneNumber + ‘?call’

if(utils.stringMiddle(application.getOSName(),1,7) == “Windows”) {
application.executeProgram(‘rundll32’, ‘url.dll,FileProtocolHandler’,vString)
} else {
application.showURL(vString)
}




this saves others some time! <img src="{SMILIES_PATH}/icon_wink.gif" alt=";-)" title="Wink" />

This not working in Rich Client in Mac. Displaying the status message that the URL is copied to the Clipboard(Same as the 1st. Post).

Thanks,

I know, the workaround was for windows only!

you could try this: (did not test it)

var vPhoneNumber = arguments[0]
var vString = 'skype:' + vPhoneNumber + '?call'

if(utils.stringMiddle(application.getOSName(),1,7) == "Windows") {
   application.executeProgram('rundll32', 'url.dll,FileProtocolHandler',vString)
} else {
   application.executeProgram("open", vString);
}

Hi Harjo,

Thanks.

It is working.

Thnkx small but effective coding!
If someone might wonder how to create a skypechat: take the code above and replace ?call with ?chat

MODERATED: linkspammer

corneli:
How do I make skype not start when I start up my macbook?

Normally this happens when skype is included in startup items.
You should be able to find this somewhere in system preferences > accounts > [your account]

Hi all!

After several test, we found out example code only works in SC and WC if server and client are the same machine (launched from Developer)… Because executeProgram function works in client when launched from SC, but it’s executed in server when launched from WC.
Due to this, we are using this code to calling:

function core_Skype_call(phoneNumber)
{
	var vString = 'callto:'  
	
	// If parameter is null, opens Skype
	if (phoneNumber)
		vString = vString + phoneNumber;

	if (application.getApplicationType() == APPLICATION_TYPES.WEB_CLIENT)
	{
	application.showURL(vString,'_self')  
	}
	else
	{
		core_openFile(vString)
	}
}

and this to chat:

function core_Skype_chat(contactName)
{
	var vString = 'skype:'   

	// If parameter is null, opens Skype
	if (contactName)
		vString = vString + contactName + '?chat'
	
	if (application.getApplicationType() == APPLICATION_TYPES.WEB_CLIENT)
	{
		application.showURL(vString,'_self')  
	}
	else
	{
		core_openFile(vString)
	}
}

And the core_openFile:

	//windows
	if(utils.stringMiddle(application.getOSName(),1,7) == "Windows")
	{
	   application.executeProgramInBackground('rundll32', 'url.dll,FileProtocolHandler', vFullFileName)
	}
	//FreeBSD or Linux
	else if(utils.stringMiddle(application.getOSName(),1,7) == "FreeBSD"||utils.stringMiddle(application.getOSName(),1,5) == "Linux")
	{
	   	application.executeProgramInBackground('gnome-open', vFullFileName)
	}
	//Mac OSX
	else if(application.getOSName().match("Mac"))
	{
	   application.executeProgramInBackground('open', vFullFileName)
	}

Well, in Windows, it’s working right in all scenarios (SC, WC in a production server)… But in Linux it’s not working…

Somebody could help us with this? Some tip about this??

Thanks in advance!

//FreeBSD or Linux
else if(utils.stringMiddle(application.getOSName(),1,7) == “FreeBSD”||utils.stringMiddle(application.getOSName(),1,5) == “Linux”)
{
application.executeProgramInBackground(‘gnome-open’, vFullFileName)
}

Try

application.executeProgramInBackground('mozilla', vFullFileName)

For me this is working.