i have made code to make USSD call:
PhoneArguments call = new PhoneArguments(PhoneArguments.ARG_CALL, "*004*"+
_String1+
"*"+
_String2+
"#"
);
Invoke.invokeApplication(Invoke.APP_TYPE_PHONE, call);
the app make the call and send the USSD request and show the response without any problems.
but it gives an error message with "cannot connect to ....", how to hide this error message ?
make sure there's no duplication
Related
im using slack to make chat bot so i can create a message center from my ios app to send message from ios app to slack.
getting following response from hitting joinChannel api https://slack.com/api/channels.join
cant get channel ids
{
"provided" : "admin,identify,chat:write:bot",
"ok" : false,
"needed" : "channels:write",
"error" : "missing_scope"
}
As the error message says you need the channels.write scope to use channels.join method.
Just add the missing scope to your access token and it will work.
I want to make call from browser to iOS app using twilio. And when i receive call at that time i need to open a custom view to accept and reject the call.
Is any body knows how to call TcDevice delegate method exa. -(void)device:(TCDevice*)device didReceiveIncomingConnection:(TCConnection*)connection
on receive a browser call ?
I am able to call from browser to device using php code but it will open the default calling screen and i need to open my custom screen and for that TcDevice delegate methods need to call.Please help.
Here is my php code to make a call
<?php
require 'Services/Twilio.php';
$version = "2010-04-01";
$sid = '******';
$token = '******';
$phonenumber = 'Twillonumber';
$client = new Services_Twilio($sid, $token, $version);
try {
$call = $client->account->calls->create(
$phonenumber,
'To_phonenumber',
'http://demo.twilio.com/welcome/voice/'
);
echo 'Started call: ' . $call->sid;
}
catch (Exception $e) {
echo 'Error: ' . $e->getMessage();
}
?>
Thanks.
Twilio developer evangelist here.
I would recommend reading through the quickstart guide for Twilio Client on iOS. It takes you through setting up a server (which you will need for this) to receiving incoming calls on the device using the iOS library.
In short, you need to set up your iOS device as a client which has an identifier, and then use that identifier to dial into instead of the device's phone number. But get through the guide and you'll find out everything you need to know.
Overview:
I am working on a VB.NET application that places a call into Twilio, the number is not a test number. I am using the C# library with the code written in VB.Net.
When I use this line of code:
Console.WriteLine(account.SendSmsMessage(Caller, to1, strBody))
I receive a text message on my phone however the post back is never posted to my website. I have included the URL of the site on the account under Messaging > Request URL.
When I reply to the message, Twilio does make a post to my site. From what I understand, a POST should have been made when Twilio was first sent a message from my application, however this is not the case.
When using this code, I do not get any text message and no POST is made.
Console.WriteLine(account.SendMessage(Caller, to1, strBody, PostBackURL))
I have tried SendSMSMessage, I have tried it with the URL on my account and without it,
nothing seems to effect the behavior.
I need the SmsMessageSid at the time the message is sent. From everything I have seen, Twilio does not provide a response other then what is sent to the PostBackURL, I could parse a response for the
SmsMessageSid however since there is no response that is not an option. If I am mistaken on that point that would be great, however it looks like the only way to get a reply is with the post back URL. Thanks for your help with this! Below you will find an excerpt of the code I am working with:
PostBackURL = "http%3A%2F%2F173.111.111.110%3A8001/XMLResponse.aspx"
' Create Twilio REST account object using Twilio account ID and token
account = New Twilio.TwilioRestClient(SID, Token)
message = New Twilio.Message
Try
'WORKS
'Console.WriteLine(account.SendSmsMessage(Caller, to1, strBody))
'DOES NOT WORK
Console.WriteLine(account.SendMessage(Caller, to1, strBody, PostBackURL))
Catch e As Exception
Console.WriteLine("An error occurred: {0}", e.Message)
End Try
Console.WriteLine("Press any key to continue")
Console.ReadKey()
I'm doing something similar with C# and like you, I'm not getting the POST to the callback URL. I don't know why that's not working, but if all you need is the sid when you send the message, you should be able to do this:
message = SendSmsMessage(Caller, to1, strBody))
and message.Sid will give you what you need, assuming no exceptions.
Is it possible to know the state of application invoked in blackberry? For example, if we invoke blackberry email application after sending an email, can we know if the application has closed or still running and also where the email has been sent, the subject, the content, etc.? The code may be something like this:
try {
Message message = new Message();
Address address = new Address("email#yahoo.com", "Email");
Address[] addresses = {address};
message.addRecipients(RecipientType.TO, addresses);
message.setContent("Testing email from MyTabViewDemo application");
message.setSubject("Testing Email");
Invoke.invokeApplication(Invoke.APP_TYPE_MESSAGES, new MessageArguments(message));
log.debug(MyApp.GUID_LOG, "Send email action done!");
} catch (Exception e) {
Dialog.inform(e.toString());
}
and how about retrieving the state of other applications like phone, sms, camera?
Thank you.
You can view the visible applications by calling
ApplicationManager.getApplicationManager().getVisibleApplications();
That returns an array of application descriptors. From a descriptor, you can know the names and ids.
It is possible, however, that the messaging app is always on background and cannot be closed (I'm not 100% sure here)
But you can't know if a message has ben sent or not sending the mail like that.
I would like to make make userregistartion app in Blackberry. In which I have used ksoap2 to send request to server and get response from server.
I want that when I send request to server and within 10 second if server not give any response than say any msg like "Try again". and before 10sec server give response then proceed further.
How's this possible? Is there used TimerTask or any method for Tomeout in Ksoap?
may be the following example will helpful for you:
String ht_params = ";ConnectionTimeout=10000"; // 10 seconds timeout
HttpTransport ht = new HttpTransport(this.SERVICE_URL + ht_params);
I'm from Russia, so my English is very bad.