dbTalk Databases Forums  

Limiting a Text Field

comp.databases.filemaker comp.databases.filemaker


Discuss Limiting a Text Field in the comp.databases.filemaker forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Jake
 
Posts: n/a

Default Limiting a Text Field - 10-30-2006 , 06:11 PM






I have people entering into a database that includes a large text field
for misc. remarks. These tend to extend past the size of the field
which causes the field to expand and obstruct the rest of the layout.
I was wondering if there was any good way to solve this problem.
So far I have created a running word count to let people know when they
were getting near the maximum number of words, but this failed because
the count only updates when you click out of the field. I need the
user to be told that they are going over the limit as they do it.
I also tried to have an error message come up if they exceed a certain
number of characters, but this also only happens when you click out of
the field.
I appreciate any help I can get on this. I am a high school student,
and the database I am creating is for the volunteer ambulance service
that I am part of.


Reply With Quote
  #2  
Old   
Bill Marriott
 
Posts: n/a

Default Re: Limiting a Text Field - 10-30-2006 , 06:22 PM






Would scroll bars work for you? When they are active, the field doesn't
expand in size.

"Jake" <JMartin89 (AT) gmail (DOT) com> wrote

Quote:
I have people entering into a database that includes a large text field
for misc. remarks. These tend to extend past the size of the field
which causes the field to expand and obstruct the rest of the layout.
I was wondering if there was any good way to solve this problem.
So far I have created a running word count to let people know when they
were getting near the maximum number of words, but this failed because
the count only updates when you click out of the field. I need the
user to be told that they are going over the limit as they do it.
I also tried to have an error message come up if they exceed a certain
number of characters, but this also only happens when you click out of
the field.
I appreciate any help I can get on this. I am a high school student,
and the database I am creating is for the volunteer ambulance service
that I am part of.




Reply With Quote
  #3  
Old   
Kent
 
Posts: n/a

Default Re: Limiting a Text Field - 10-30-2006 , 06:28 PM



Not sure how useful it is, but you could have them type into a global, put xx
characters into a field that displays in the correct place, and the rest into a
separate filed on another layout they can reach with a more button? I'm guessing
that if you looked for last occurrence of a period (or maybe did a word count in
the xx characters) before the max characters is reached, it would help to avoid
truncating things in an unseemly fashion.

Then, if you want, they can see where they ran out of space and go back in to make
some changes if they prefer.

Kent


Jake wrote:
Quote:
I have people entering into a database that includes a large text field
for misc. remarks. These tend to extend past the size of the field
which causes the field to expand and obstruct the rest of the layout.
I was wondering if there was any good way to solve this problem.
So far I have created a running word count to let people know when they
were getting near the maximum number of words, but this failed because
the count only updates when you click out of the field. I need the
user to be told that they are going over the limit as they do it.
I also tried to have an error message come up if they exceed a certain
number of characters, but this also only happens when you click out of
the field.
I appreciate any help I can get on this. I am a high school student,
and the database I am creating is for the volunteer ambulance service
that I am part of.


Reply With Quote
  #4  
Old   
Kent
 
Posts: n/a

Default Re: Limiting a Text Field - 10-30-2006 , 06:33 PM



[Edited version, in case you see it twice]

Not sure how useful it is to your needs, but if Bill's suggestion of a scroll bar
doesn't work, maybe you could have them type into a global, put xx characters into
a field that displays in the correct place, put the rest into a separate field on
another layout they can reach with a more button? Perhaps the button could be
hidden except where you were forced to dump some text into the other field.

I'm guessing that if you looked for last occurrence of a period or at least space
(or maybe just did a word count in the xx characters) before the max characters is
reached, it would help to avoid truncating things in an unseemly fashion.

Then, if you want, they can see where they ran out of space and go back in to make
some changes if they prefer.

Kent


Jake wrote:
Quote:
I have people entering into a database that includes a large text field
for misc. remarks. These tend to extend past the size of the field
which causes the field to expand and obstruct the rest of the layout.
I was wondering if there was any good way to solve this problem.
So far I have created a running word count to let people know when they
were getting near the maximum number of words, but this failed because
the count only updates when you click out of the field. I need the
user to be told that they are going over the limit as they do it.
I also tried to have an error message come up if they exceed a certain
number of characters, but this also only happens when you click out of
the field.
I appreciate any help I can get on this. I am a high school student,
and the database I am creating is for the volunteer ambulance service
that I am part of.



Reply With Quote
  #5  
Old   
Matt Wills
 
Posts: n/a

Default Re: Limiting a Text Field - 10-31-2006 , 06:42 AM



In article <1162253501.631025.214100 (AT) b28g2000cwb (DOT) googlegroups.com>,
"Jake" <JMartin89 (AT) gmail (DOT) com> wrote:

Quote:
I have people entering into a database that includes a large text field
for misc. remarks. These tend to extend past the size of the field
which causes the field to expand and obstruct the rest of the layout.
I was wondering if there was any good way to solve this problem.
So far I have created a running word count to let people know when they
were getting near the maximum number of words, but this failed because
the count only updates when you click out of the field. I need the
user to be told that they are going over the limit as they do it.
I also tried to have an error message come up if they exceed a certain
number of characters, but this also only happens when you click out of
the field.
I appreciate any help I can get on this. I am a high school student,
and the database I am creating is for the volunteer ambulance service
that I am part of.
NOTE: FileMaker version not specified. Answer assumes 7 or greater.

As you've already discovered, there is nothing that will update a word
count unless the user leaves the field.

Others have suggested ways of letting people know they've exceeded the
limit, but they still have to click outside the field.

I haven't tried this, but it's worth a shot:

The free plugin zippScript
(http://www.nightwing.com.au/FileMake...ppScript20.dmg)
provides for triggering a script on entry to a field. It also provides
for triggering a script at a certain point in the future.

The flow:

Entry to the field triggers the script.

Script checks checks length of text in field. If less than the defined
max, it sets to trigger itself to check again, perhaps one or two
seconds in the future.

If the max is exceeded, a Custom Dialog advises the user.

As I said, I have not played with this. There may be an issue with where
the cursor ends up once the script executes. I haven't yet figured out
how to go to a certain point in a field.

Matt


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.