Kundinger Posted October 8, 2004 Posted October 8, 2004 Hello All... I have an issue with a 'relationship' finding the correct character in a related file. Here is how I did a test... - setup a file (ASCII Codes) with a 'char' text field and a 'code' text field -- this file has many records with individual alpha-numeric characters (a,b,c,d,1,2,3,4,A,B,C,D, etc.) entered into the 'char' field -- this same file has the same records with corresponding ASCII codes (97,98,99,100,49,50,51, etc.) entered into the 'code' field - setup a file (TEST) with a 'data' text field -- this file has a 'relationship'... "TEST:data = ASCII Codes:char" -- this file has a layout with... 'data' field & 'ASCII Codes:char' field & 'ASCII Codes:code' field Theory of operation... when a character "A" is entered into the 'TEST' file-'data' field... the 'related' 'char' & 'code' fields will display the correct alpha-numeric character and ASCII code "A" & "65". The problem... - when I enter "A" into the 'data' field, it returns the correct "A" & "65" - when I enter "2" into the 'data' field, it returns the correct "2" & "50" - when I enter "a" into the 'data' field, it returns the INCORRECT "A" & "65" - when I enter "=" into the 'data' field, it returns the INCORRECT " " & " " Observations... - FMP 6.04 appears to 'treat' "A" and "a" as the same character - FMP does NOT recognize various characters (=+-*&%$#@ etc.) when identifying characters Questions... - why does FMP treat "A" & "a" as the same character? - why does FMP NOT recognize other characters? - does FMP have a function or an unknown capability to process ASCII/CHAR codes? Thanx for the assistance! Bob Kundinger [email protected]
Kundinger Posted October 8, 2004 Author Posted October 8, 2004 Lee... I'm not sure what you are referring to... "Are you storing all fields as ASCII?" Thanx, Bob Kundinger [email protected]
-Queue- Posted October 8, 2004 Posted October 8, 2004 Your data and char fields need to be stored as ASCII. Open Define Fields, select one of the fields, click the Storage tab, click the drop-down next to 'Default language...' and scroll down to ASCII. If they're stored in English, it won't work.
Kundinger Posted October 8, 2004 Author Posted October 8, 2004 Sorry All... Lee had the correct solution... THANX, Lee! In 'Define Fields...' select the text field, click the 'Options' button, click the 'Storage' tab, select the "ASCII" menu choice from "Default language for indexing and sorting text". That fixed the problem. I only wish FMP had a ASCII/CHAR code function like most other applications. Thanx again Lee... Bob
cjaeger Posted October 9, 2004 Posted October 9, 2004 Anyway, a better way to get the ASCII code is as follows: - create a text field "ASCIIcodes) - set indexing to ASCII - then re-define that field as global Paste all ASCII characters into ASCIIcodes Now you can get the ASCII code by a simple calculation: Position(Character, ASCIIcodes)
Recommended Posts
This topic is 7350 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now