KNOWLEDGE BASE
Log In    |    Knowledge Base    |    4D Home
Tech Tip: When code will not tokenize...
PRODUCT: 4D | VERSION: 2004 | PLATFORM: Mac & Win
Published On: May 1, 2007

You may run into situations from time to time when your 4D code will not tokenize.

For example, you enter something like !00/00/00! and it becomes:

!0 0/0/00!

Or perhaps a plug-in function will not tokenize. Here are some things to try:


  • Delete the "preferences".

  • Delete and re-enter the code in the method.



This simplest way to test whether or not deleting the preference will fix the problem is to rename the "4D" folder. This folder stores application preferences, licenses, etc. This folder is located at (be default):

Mac OS:

/Library/Application Support/4D

Windows XP:

C:\Documents and Settings\All Users\Application Data\4D

Simply close 4D, rename this folder (e.g. to "4D_old"), and start 4D again. 4D will create a new "4D" folder at the previously mentioned location. 4D will be unable to locate your licenses, so select "I would like to evaluate..." in order to launch 4D in demo mode. Check to see if the code will tokenize now.

Typically the file that causes this problem is the "4D Preferences 2004.RSR" file. You can also delete this file, instead of renaming the whole "4D" folder, and 4D will recreate it.

Note that you can restore all of your previous preferences, licenses, etc. by deleting the new "4D" folder and renaming the old one back to 4D.

If the above does not help, try entering the code into the method again. Sometimes you need only delete the first line that will not tokenize. Other times it may be faster to just delete the whole method and start again.

Finally be sure to check the database with 4D Tools to be sure nothing else is wrong.