Results 1 to 2 of 2

Thread: getActionCommand[Resolved]

Threaded View

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Feb 2002
    Posts
    103

    getActionCommand[Resolved]

    okay, buttons A, B, C, D, and E.

    how do i make it so that, if button A, B, or C is pressed, do method1, else do method2? i'm using getActionCommand, not getSource.

    i tried something along the lines of:

    String in = e.getActionCommand();

    if in.indexOf("ABC") > -1 //found
    method1();
    else method2(); //not found
    Last edited by Dilenger4; Jun 27th, 2003 at 09:43 PM.

Posting Permissions

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



Click Here to Expand Forum to Full Width