Vivian M Posted September 8, 2008 Posted September 8, 2008 I would like to limit the number of character that a user can enter. I understand setting up the field with the Maximum set to the desired number, but the user can enter as many characters as he wants. The user doesn't know he's gone over the, let's say, 80 character limit until he tries to go to the next field. At which time, the error message shows up. Is there a way to have filemaker stop allowing any characters to be typed in to the field when past the limited number of characters?
Colin Keefe Posted September 9, 2008 Posted September 9, 2008 One method to at least flag them before the record is committed is to use conditional formatting on the fields(say, add a red fill) Length(Self)>10 It won't stop them from entering the extra characters, but when they tab to the next field, the formatting will be applied, which might help a bit.
Cabinetman Posted September 9, 2008 Posted September 9, 2008 ...It won't stop them from entering the extra characters.... Not sure how that helps. The whole idea is to stop them from typing, say 200 characters, before they waste their time. I played a bit with the conditional formatting and even the HTML - joke - file and even a calc of the text field, no luck. Not sure why you have to tab out of the field. Seems like their should be a way to stop the typing. I know some (a little) HTML and thought maybe that was the way to go right now.... not sure how or if you can set that HTML text field in the web viewer to export (post) to the FMP field..........
Colin Keefe Posted September 9, 2008 Posted September 9, 2008 Not enough coffee today. Yeah. I'd be curious if anyone has any techniques for this, either natively or via plugins. I can't think of any way to accomplish what the OP needs until the field contents are actually evaluated by exiting the field or record.
Vivian M Posted September 9, 2008 Author Posted September 9, 2008 I appreciate everyone's input. As a relatively newbie, I just wanted to know IF it can be done. I have spend so much time pouring through the FM Help. The information being entered in this field also shows up on a form we use which has limited space. What I am considering doing is creating a separate field which takes the first 80 characters and then adds "See attached form." Putting the new field on the report. I can then add an additional, optional form which would have enough space to accommodate a large number of characters-and use the original field.
Vivian M Posted September 9, 2008 Author Posted September 9, 2008 I tried the html that was sent. I don't understand how to get from the html in to the field. I've never worked with html's, but it certainly did limit the number of characters that could be entered. I just don't know how to translate that to field entry.
Colin Keefe Posted September 9, 2008 Posted September 9, 2008 Daniele - who posted that example - called it a joke, mainly because it was. There's probably a way to do it using the Web Viewer but it would likely involve a plugin and hosting your database using CWP or some such thing. I sort of doubt that's the route you want to go down just yet.
Cabinetman Posted September 9, 2008 Posted September 9, 2008 If you look he called it a joke........ It is just an HTML text field set in a web viewer and I guess the only way they could see to do it. However it did leave me wondering if this could be used to accomplish what you need.
Vivian M Posted September 9, 2008 Author Posted September 9, 2008 Is there a way using "conditional" formating - to format the first 80 characters as a particular TEXT COLOR? So when character 81 is typed, the text color changes. Or is the conditional format also limited to when you leave the field?
Raybaudi Posted September 9, 2008 Posted September 9, 2008 Hi Vivian HFAIK there is no way to do what you need and it is due to the way that FileMaker makes calculations: only when the record is committed or you exit the field. So that I posted my "joke"... But we can always hope that the next version will have such ability
Cabinetman Posted September 10, 2008 Posted September 10, 2008 I tried that and no.... didn't work until I exited the field
Vivian M Posted September 10, 2008 Author Posted September 10, 2008 I got around the problem by doing the following: I limited the number of characters in the fields to 500. I created a new field that I put on the report that takes the first 80 characters and adds a "cont'd on Page 6." I added an additional page (page 6) to my report. On Page 6. I expanded the field to accept 500 characters. Page 6 is printed when needed.
Raybaudi Posted September 12, 2008 Posted September 12, 2008 Just a joke ! Continuing the joke... P.S.: tested only on Win with IE FixedCharsNumber.zip
Cabinetman Posted September 15, 2008 Posted September 15, 2008 Well same principle but better than where I'm at... I did get it using my web browser and was in the middle of converting to use the web viewer also. BUT SO MUCH WORK! Based on my limited knowledge I went with this. 1. I wrote the html with 'post' and a cgi. 2. Had to install Perl 3. Had to install Apache 4. Still have to do some sort of script step to update the fields.... Finally quit..... nothing I'd use anyway. I just wanted to see if I could do it.
Raybaudi Posted September 15, 2008 Posted September 15, 2008 Hi don't know html, but the event OnBlur ( and OnFocus ) is the lonely way that I can use to say to the Webviever to do something... in this case to say it to place the contents of the Input field into the clipboard on exit the WebViever.
Cabinetman Posted September 15, 2008 Posted September 15, 2008 So only one field can be done at a time then? Hhhuuummmmm. I thought this was it. I figured to just add the extra fields and create it as an entire layout. Then throw in a button 'commit to record' to get all the info in each field. Glad you explained it before I wasted more time. LOL.... of course even pursuing the Apache and Perl stuff was probably too much to begin with. I may look again later at this and try to figure workaround.
Raybaudi Posted September 15, 2008 Posted September 15, 2008 So only one field can be done at a time then? Hhhuuummmmm. I thought this was it. I figured to just add the extra fields and create it as an entire layout. Not exactly... You can have all the fields that you need, but one field for each WV and a scripted "Go to next field" that is really a "Go to the object" while pasting the first result somewhere. I think ( but again I don't Know html ) that is even possible to copy to the clipboard MORE than a field of an unique WV
Josh Ormond Posted September 15, 2008 Posted September 15, 2008 I had seen a solution not to long ago that used the Fusion plugin. It basically used the WebViewer and Java/HMTL to do it. I can't seem to put my fingers on it now...I will keeping looking.
Thomas Seidler Posted November 1, 2008 Posted November 1, 2008 yes, Fusion Reactor plug-in would work very well for this. LiveField is what you are after. Download the demo and check it out. And if you go the FileMaker Technet membership route [besides the many other benefits] there is a discount on the Developer License, well worth getting, and I'm not paid by them, I just like the power it gives for UI development and simplicity... a slightly unrelated demo, but showing why its worthwhile... http://www.harmlesswise.com/0810-filemaker-fusion-reactor-livefield u can see in this demo that if you type more than 2 separate words u get a red error box appear [using conditional formatting] - so very easy to just adapt it to go red on over 80 chars... blessings, tom
Recommended Posts
This topic is 5866 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