Tex Link and Paragraph

Discussion in 'New Member Introductions & Site Assistance' started by JJJCR, Dec 5, 2013.

  1. JJJCR

    JJJCR New Member

    Joined:
    Dec 4, 2013
    Messages:
    4
    Likes Received:
    0
    Trophy Points:
    1
    Ratings:
    +0
    Hello Droiders,

    Getting my hands wet on Android and has started doing Hello World!!

    I just want to ask, how to make a text as link?

    Like I have a text:
    Beyond the Storm

    And if I click the text "Beyond the Storm" a new paragraph will open

    And to make a new paragraph, does it need only a textview method? or are there other ways to display a paragraph after clicking a link?

    Thank you Gurus, for any input and ideas.. :) :happy:
     
  2. JJJCR

    JJJCR New Member

    Joined:
    Dec 4, 2013
    Messages:
    4
    Likes Received:
    0
    Trophy Points:
    1
    Ratings:
    +0
    any help guys.. :)
     
  3. MotoXGirl

    MotoXGirl Active Member

    Joined:
    Nov 12, 2013
    Messages:
    381
    Likes Received:
    69
    Trophy Points:
    28
    Location:
    Missouri
    Ratings:
    +69
    Hey JJJ,

    Im sorry, I don't really understand your question. You said you're doing "hello world"? Are you referring to starting to program?
     
  4. SFGate

    SFGate Guest

    Ratings:
    +0
    Welcome to the site. Think you may need to make your question a little more clear. DancingNexus
     
  5. JJJCR

    JJJCR New Member

    Joined:
    Dec 4, 2013
    Messages:
    4
    Likes Received:
    0
    Trophy Points:
    1
    Ratings:
    +0
    Hi MotoX,

    Sorry for the confusion..

    I mean I had finished doing the Hello World!!

    And had started to explore other things.

    After a couple searching on the web, I had this code and it seems to work.,


    @Override
    public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.activity_first); // Our only layout for this app is main.xml

    // Initialize the UI components
    changingTextView = (TextView) findViewById(R.id.textView1);
    final TextView view = (TextView) findViewById(R.id.textView1);
    view.setOnClickListener(this);

    @Override
    public void onClick(View v) { // Parameter v stands for the view that was clicked.


    if(v.getId() == R.id.textView1){
    Toast.makeText(this, "Text View Link Testing!!!",
    Toast.LENGTH_LONG).show();
    }

    Thanks,hope it will help someone else along the way :)
     
    #5 JJJCR, Dec 7, 2013
    Last edited: Dec 7, 2013
  6. JJJCR

    JJJCR New Member

    Joined:
    Dec 4, 2013
    Messages:
    4
    Likes Received:
    0
    Trophy Points:
    1
    Ratings:
    +0
    Hi SFGate, thanks for your welcome!! Appreciate it!!

    dancedroid

    Sorry for the confusion, I manage to found a code after searching the web and I share the code above.