aspose file tools*
The moose likes Java in General and the fly likes Running jFlex Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » Java in General
Bookmark "Running jFlex" Watch "Running jFlex" New topic
Author

Running jFlex

Hunter McMillen
Ranch Hand

Joined: Mar 13, 2009
Posts: 492

Does anyone have any experience running the jFlex??

I have downloaded and installed jFlex, and following the directions changed both my JAVA_HOME path and JFLEX_HOME path to where both files exist. When I try to run jFlex from the command line I receive this error:


'jflex' is not recognized as an internal or external command,
operable program or batch file.

any help would be great,
Hunter


"If the facts don't fit the theory, get new facts" --Albert Einstein
Campbell Ritchie
Sheriff

Joined: Oct 13, 2005
Posts: 36478
    
  16
Are you supposed to add the jFlex installation directory to your PATH? I don't remember doing that ever; is it the same JFlex as I have used?
Hunter McMillen
Ranch Hand

Joined: Mar 13, 2009
Posts: 492

This is the exact instruction:

Edit the file bin\jflex.bat (in the example it's C:\JFlex\bin\jflex.bat) such that
JAVA_HOME contains the directory where your Java JDK is installed (for instance C:\java) and
JFLEX_HOME the directory that contains JFlex (in the example: C:\JFlex)

I set JAVA_HOME to where my jdk is: C:\Program Files\Java
and JFLEX_HOME to where the jFlex is: C:\Documents and Settings\Hunter\Desktop\jflex-1.4.3\lib

Campbell do you see any mistakes??


Thanks
Hunter
Campbell Ritchie
Sheriff

Joined: Oct 13, 2005
Posts: 36478
    
  16
That appears to be the same JFlex I have used (but I used it only on Linux), but surely JAVA_HOME ends with \jdk1_6_0_18 or similar, despite the example they give here?
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 39547
    
  27
JFLEX_HOME : C:\Documents and Settings\Hunter\Desktop\jflex-1.4.3\lib

Just a hunch, but that should probably be C:\Documents and Settings\Hunter\Desktop\jflex-1.4.3 (without the "\lib")


Ping & DNS - updated with new look and Ping home screen widget
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Running jFlex
 
Similar Threads
javac not recognized as an internal or external command
CLASSPATH PROBLEM
Problem when executing the LWJGL native library under Java via shell script
path and classpath
Syntax Highlighting