Tyler Jordan

Ranch Hand
+ Follow
since Nov 17, 2003
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Tyler Jordan

Figured out my problem. Had to change it under Variable Name under Code tab.

I'll figure out what the other properties are used for.
Hi,
I just started working with NetBeans 6.5. I read through the NetBeans tutorial on creating a simple form and adding textboxes, labels, buttons, etc. I've also used Visual Studio, very similar functionality. My problem is I want to change the variable names, of obvious reasons. I've tried to do this in design view by changing name and accessible name (one of these seem to be the logical property for the variable name). Can't change it in source view either, locked. Is there a different property used to change the variable name?

Thanks,
-Tyler
Good call, the ^ and $ were it. Basically I was saying that all the line should contain is my regex. I removed those chars from my regex and it matches as expected now.

Thanks for the help!
13 years ago
Hi,
According to Sun, the find() method under matcher does the following:

"Attempts to find the next subsequence of the input sequence that matches the pattern."

So in human this means to me that find() returns true if a string CONTAINS a sequence that matches the regex. However, with my program, it only returns true if the string itself matches the regex. So with the following inputs:

REGEX = "^[U||C]J[A-Z]{5}[0-9]{3}$";

INPUT = "UJZEDGG111"; returns true
INPUT = "<**>UJZEDGG111"; returns false (but should return true)

Here is my full code:



Did I do something wrong here?

-Thanks
13 years ago
Thanks! The function group() from matcher fits the bill.
13 years ago
I'm looking for a way to capture a string out of a larger string that matches a regex. I looked into the String class, but there is nothing there to help. I can't believe a function like this isn't included in the class. I can match on it, but can't extract it:

ie.



Any ideas?
13 years ago
Yes, thats exactly what it was. The loop was not supposed to keep redefining the container array. I moved the following code above my "for" loop and fixed the nullpointers:



Thanks!
13 years ago
I'm having trouble figuring out why I'm having difficulty with this multidimensional array. It seems to be an accessibility issue since I've tested the declaration and defining of the elements within the array. The issue point is the last line in the code below. For some reason, I get a nullpointerexception whenever I've run the code. It spits out the same error whether or not I hard-code the values. I've verified that isMarked[1][1] is defined and I've hard-code the last array to isMarked[1][1] and I get nullpointerexception.

This is my basic code, the isMarked array is declared in another class:



Thanks,

-Tyler
13 years ago
Yes, the book looks like just what I need. I had a feeling that I was moving beyond what the Head First Design Patterns can provide with this new project.

Thanks for the reference!
I'm starting to work on a app that will support a small business. It will have information stored in a database, such as employee data, employee hours, supplies, etc. It will also create reports on the information and allow a person to add and remove employees, stock either manually or because of changes in the database.
What I am try to determine is what type of design pattern I should use to make this a scalable app. I realized how useful patterns were after I designed an app with the factory pattern after reading the Head First Design Pattersn book, made it a breeze to modify the program. Anyway, I'm thinking it may be a combination of some design patterns. However, I'd like to get some input. I figure someone may have tried to do this before and maybe I can proactively avoid some of the pitfalls.
Thanks alot! That did the trick.
Hi,
I'm trying to combine one varible with another. I'm not sure if I'm just spinning my wheels and it can't be done or what.



So if "document.forms[0].elements.name" equals the string "name" then it would look like the following to the interpreter:



Everything I've tried to get it working has failed. Any help would be appreciated.

Thanks,
-Tyler
I didn't see JCreator in that list anywhere, so I'll add it.
JCreator is has a small footprint, its free, not a resource hog, and has better output support than NetBeans. Since I'm relatively new to Java, I had difficulty figuring out the popular NetBeans and Eclipse. JCreator has everything I need in a simple format, nothing extravagant and it doesn't default to showing all those annoying syntax windows. I also love the fact that it opens a command prompt window when running an application to show all the output.
What I'll do is add a string like EOF on the end of my classcodes file and use that as a delimiter for the end of the file. This is a little cludgy, but it will at least narrow the focus.
15 years ago
I have been getting a NullPointerException during this specific section in my application. I assume that the StringTokenizer is grabbing a null value which is causing the problem, but it is my understanding that the hasMoreTokens() method should eliminate that problem. The input file that I use is a .csv file.



This is the error.

15 years ago