Jump to content

Auto Enter repeating field with custom info


pajonate

This topic is 6083 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Hi, I notice a topic talking about populating repeating field with consecutive serial (Daniele's way) and with the same value.

But, what if I want couple of custom values to get in there, like

"Door" in rep(1)

"Window" in rep(2)

"Room" in rep(3)

"House" in rep(4)

Soren mentioned something about CF, which is not coming to my head as of now. I need this for building relationships (explanation for Soren).

I tried repeating global field, but the weirdest thing is that the related data is not showing always (if I open the definitions of the related dbs and confirm them, than I get the related data). Any idea why is that?

Thank you

Link to comment
Share on other sites

I think it's nessersary that you see this movie, holding type as well in the multiline keying seems pretty tough to update, and reluctant refreshings are likely to occure.

http://www.filemakermagazine.com/secured/transfer/513/DataTagging_full.mov?key=2a43223d50edae684db9b3ac2b515f5c

--sd

Link to comment
Share on other sites

hi Soren, I watched the video, but it is making the whole thing more complicated (I think), because implements value lists, calculations, globals, layouts etc. in all the related files, which I am trying to avoid.

Let me clarify my problem:

I have a person's record in one table with their ID# and one global (not necessary) field that represent what kind of note I want to see in the portal (all, personal, work related etc...), and notes table where 1 rec is one note with that persons ID# and note type as repeating field (2 values from which one is always "all" and the other is the more specific note type "personal", "work related", "exclusive" etc).

My relationship is build on the elements:same ID# for both and same global field in person's table and the repeating field in the note table. So, in case in person's record I set the global to "all" I can see all the notes for that person regardless of the type (since all of the note recs have value "all" in one of the repetitions), but, if I chose "personal" in the person's global field, than I will be able to see only the "personal" notes.

I was populating that repeating field with script whenever a user adds a note they have to put the type of note they want to make and that the script makes the repetitions. Can this be automate, so when a use choses a note type in the portal the repeating filed gets updated to "all" and the note type chosen in the second repetition

Link to comment
Share on other sites

Thanks, Soren and Comment.

Comment, using repeating filed was a solution we thought was an elegant one, and no one bother to check if that's gonna work with regular text field with multiple lines.

That was a our mistake.

Anyway, it works good with regular field with multiple lines.

Also, in case someone still needs to populate a 2 repeating field with custom values, here what I have achieved so far (without scripts).

Let say you need a RF with values "ALL" and note type in the other rep.

2 fields are needed:

NoteTypeRF (2 rep field) and

NoteType (text field)

Set NoteTypeRF as an auto-enter calc with data checked and value "ALL" (no quotes) and check also calculated value where this calc should be entered:

Substitute ( Extend ( NoteTypeRF ) ; NoteTypeRF ; NoteType )

This will extend value "ALL" to all repetitions, and than substitute only the first one with the chosen note type, but, only when you set note type. If note type is not set, than rep. field has "all" in both repetitions.

I hope this will help someone.

Edited by Guest
Link to comment
Share on other sites

Well, you could use a regular (non-repeating) text field with auto-entered calculation =

NoteType & "¶All"

but it could be somewhat confusing to the user. I would go for a calculation field using the same formula. This would be hidden to the user and used only for the relationship.

Alternatively, the same trick could be employed on the parent side, with a calculation =

Case ( gNoteType = "All" ; "Door¶Window¶Room¶House" ; gNoteType )

If you have a value list of the types, you could use the ValueListItems() function instead of hard-coding the values into the formula.

Link to comment
Share on other sites

This topic is 6083 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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.