Results 1 to 3 of 3
  1. #1
    Maarten is offline Member
    Join Date
    Dec 2011
    Location
    Utrecht
    Posts
    35
    Rep Power
    0

    Default call method in htm test on label

    Hi,
    I want to set an html text on al label, but also call a method.

    I tried:

    Java Code:
    scoreMens.setText("<html>joejoe<BR>jaja<BR</html>" + naamSpeler.laatKaartenZien());
    but the naamSpeler.laatKaartenZien(), which returns a string, doesn't show on the label. Is there a way to call a method and use a html text on a label?
    thanks,
    Maarten.

    ps
    the name of the thread should be "call method in html text on label"

  2. #2
    JosAH's Avatar
    JosAH is offline Moderator
    Join Date
    Sep 2008
    Location
    Voorschoten, the Netherlands
    Posts
    14,422
    Blog Entries
    7
    Rep Power
    28

    Default Re: call method in htm test on label

    The String returned by the method should be part of the <html> ... </html> text, i.e.

    Java Code:
    scoreMens.setText("<html>joejoe<BR>jaja<BR>" + naamSpeler.laatKaartenZien() + "</html>");
    kind regards,

    Jos
    Last edited by JosAH; 09-07-2014 at 04:10 PM. Reason: I can't even spell my own name correctly ...
    Build a wall around Donald Trump; I'll pay for it.

  3. #3
    Maarten is offline Member
    Join Date
    Dec 2011
    Location
    Utrecht
    Posts
    35
    Rep Power
    0

    Default Re: call method in htm test on label

    Thank you, that was it :)



    Quote Originally Posted by JosAH View Post
    The String returned by the method should be part of the <html> ... </html> text, i.e.

    Java Code:
    scoreMens.setText("<html>joejoe<BR>jaja<BR>" + naamSpeler.laatKaartenZien() + "</html>");
    kind regards,

    Jos

Similar Threads

  1. Effect of calling real service call in test
    By anjibman in forum New To Java
    Replies: 3
    Last Post: 07-18-2014, 10:39 AM
  2. Replies: 6
    Last Post: 06-21-2013, 04:42 PM
  3. call a method from another method in same class
    By rockstaedy in forum New To Java
    Replies: 5
    Last Post: 10-03-2012, 03:42 PM
  4. Please help. blue j test method
    By chang- in forum New To Java
    Replies: 12
    Last Post: 06-02-2011, 05:29 AM
  5. cannot call private method from static method
    By jon80 in forum New To Java
    Replies: 3
    Last Post: 05-07-2008, 09:37 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •