weblinks in widget

by abhay » Sat, 12 Mar 2011 04:19:38 GMT


Sponsored Links
 I am having a TextView in a widget and i have set its link clickable
to true the content of TextView is set by this code

CharSequence link = " http://www.google.com ";
 RemoteViews remoteViews = new RemoteViews(context.getPackageName(),
R.layout.main);
 remoteViews.setTextViewText(R.id.TextView01,link);


 when i run the widget and click on the link the application
forcecloses

Help me out .... Thanks ...
 I WANT A LINK TO OPEN A WEB BROWSER IN MY WIDGET if there is some
other way tell me

thanks.....

-- 



Re: weblinks in widget

by Mark Murphy » Sat, 12 Mar 2011 04:52:41 GMT


 Use adb logcat, DDMS, or the DDMS perspective in Eclipse to examine
LogCat and look at the stack trace associated with your "forcecloses".






-- 
Mark Murphy (a Commons Guy)
 http://commonsware.com  |  http://github.com/commonsguy 
 http://commonsware.com/blog  |  http://twitter.com/commonsguy 

Android Training in NYC:  http://marakana.com/training/android/ 

-- 


Sponsored Links


Other Threads

1. Blocking on a Socket read operation while in sleep mode

I have code that runs in the background and holds a connected Socket
and it's InputStream.
It calls read() infinitely until something is received, then continues
to parse. Socket timeout is 0 of course.

I am interested in what would happen when the device goes to sleep? Is
the CPU off? Will this socket be responsive in this case (Say, my
server sends some notification)?

Thanks

-- 

2. Vertical Text Aligment for Key Label in Softkeyboard example

Would there anyway to display the text for key label in vertical
aligment?
For example, display
1
2
3
in a single key instead of 123.
I tried to use \n between the numbers but it didn't work.
Would there have any other way to make the text be vertical aligment
or create a table form inside a single key?

P.S. I want it to be text instead of image.

Thanks a lot.

3. Posting data using HTTP POST to a Servlet

4. setting ANDROID ENVIRONMENT IN UBUNTU8.0 operating system

5. stt emulator

6. SMS appliaction-- would someone would like to help?

7. Starting Google Maps at pre-specified location