Results 1 to 4 of 4
Thread: Method Help
- 10-22-2010, 01:05 AM #1
Member
- Join Date
- Oct 2010
- Posts
- 10
- Rep Power
- 0
Method Help
I am having difficulty figuring out how to write text, put it in a variable and then pass it through a method. I have no problems passing integers or doubles, but when I try to do it with characters I get errors.
Example:
int v1 = 2;
int v2 = 3;
String myText = "Label One";
create_Label(v1, v2, myText);
MyText gives me an error. How do I write a method in a way that I can pass a String value to it?
Thank you in advance.
Regards,
Chad
- 10-22-2010, 01:35 AM #2
Where is your method create_Label? You must make sure that create_Label has two integers and a string for it's parameters.
Sincerely, Joshua Green
Please REP if I help :)
- 10-22-2010, 01:46 AM #3
Member
- Join Date
- Oct 2010
- Posts
- 10
- Rep Power
- 0
Thank you for your help.
IT WORKED! I spent hours on this and I couldn't figure it out!!!
- 10-22-2010, 03:15 AM #4
Similar Threads
-
Thread problem, calling method in run method
By majk in forum Threads and SynchronizationReplies: 4Last Post: 09-27-2010, 11:40 AM -
Turning Recursion Method into Iterative method
By mattakuevan in forum New To JavaReplies: 9Last Post: 06-15-2010, 06:46 AM -
method not abstract, does not override actionperformed method.
By Theman in forum New To JavaReplies: 2Last Post: 03-26-2010, 05:12 PM -
ArrayLists compareTo method, equals method
By random0munky in forum New To JavaReplies: 2Last Post: 10-26-2009, 07:20 PM -
cannot call private method from static method
By jon80 in forum New To JavaReplies: 3Last Post: 05-07-2008, 08:37 AM


LinkBack URL
About LinkBacks
Reply With Quote
Bookmarks