Java question

Discussion in 'OT Technology' started by D1G1T4L, Feb 18, 2003.

  1. D1G1T4L

    D1G1T4L Active Member

    Joined:
    May 4, 2001
    Messages:
    16,489
    Likes Received:
    0
    Location:
    Bay Area
    i want to make a JLabel which has a url address and when a person clicks it, it launches a browser to that url

    i would imagine you would have to add a mouselistener to the JLabel but how would you launch the link afterward?
     
  2. D1G1T4L

    D1G1T4L Active Member

    Joined:
    May 4, 2001
    Messages:
    16,489
    Likes Received:
    0
    Location:
    Bay Area
    once again 14 views and no answers, OT is useless as it can be


    for all those who were interested in the answer as well

    add a mouse_clicked event to JLabel and then call
    Runtime.getRuntime().exec("cmd /c start "+tempString);
     

Share This Page