getting text from a textview to display in a string in android -


i trying create share button once user presses allow user share social networking site.

i have textview text "chipotle" in xml , text "chipotle" appear in string intent. example, if user post onto facebook display "hey i'm going chipotle" , allow user post onto wall.

i have done far this:

placename = (textview) findviewbyid(r.id.place_text); placename.gettext().tostring(); string eshare = "hey i'm going to" + placename; 

with following

 i'm going android.widget.textview{123212432423....app:id/place_text) 

thanks in advance

you have assign variable line

placename.gettext().tostring(); 

like this

placename = (textview) findviewbyid(r.id.place_text); string placenamestring = placename.gettext().tostring(); string eshare = "hey i'm going to" + placenamestring; 

Comments

Popular posts from this blog

java - Oracle EBS .ClassNotFoundException: oracle.apps.fnd.formsClient.FormsLauncher.class ERROR -

c# - how to use buttonedit in devexpress gridcontrol -

nvd3.js - angularjs-nvd3-directives setting color in legend as well as in chart elements -