1 2 Previous Next 20 Replies Latest reply on Sep 8, 2009 11:46 AM by comment_1

    Replace field contents shows wrong string when used in check box field

    cbum

      Summary

      Replace field contents shows wrong string when used in check box field

      Description of the issue

      FM pro 10.0.v3 / Os X.5.8 In a value-list defined check box field, the Replace field content command always shows the same entry, regardless of the actual last entry applied (and saved). I don't know if this is related to the circumstance that this was originally a radio button filed, that was changed to check box to allow multiple entries.  Also, what are forbidden characters as list values for check boxes (e.g. ?? is invalid, giving an error when trying a find) 

        • 1. Re: Replace field contents shows wrong string when used in check box field
          philmodjunk
            

          And the "same entry" is? Might help to supply more detail there. I'd also suggest examining your fields complete unformatted contents for possible problems. You can simply place a copy of the field next to the original check box field on the layout and use field / control setup... to format it as an edit box. Now you can see what's actually in the field without the check box formatting concealing data stored in the field that doesn't happen to exactly match one of the check box values.

           

          "Also, what are forbidden characters as list values for check boxes"

          Actually ?? isn't forbidden at all for a value list. The issue lies with how find requests work. Any character from the operators drop down, if entered as value in a value list will cause problems as part of a find because they need to be enclosed in quotes in order to not be treated as an operator in the find. You can use a script to avoid this or use "??" instead of ?? in your value list.

           

          As far as I know only the hyphen (-) is "forbidden" as it will be treated as a list separator. To include it as a value instead of a list separator, include a space with it.

          • 2. Re: Replace field contents shows wrong string when used in check box field
            cbum
              

            Thanks Phil.

             

            Looking at the field as edit field did show why it was showing the entry, although IMHO this is still a bug:

             

            The field lists entries apparently in chronological order, not in the order seen on the layout in the check box field.

             

            The replace command grabs the top entry, regardless if this was the last one entered or not, and displays that as the entry to replace with, which is not typically what you want.

             

            The other entries are truncated / invisible.

            • 3. Re: Replace field contents shows wrong string when used in check box field
              philmodjunk
                

              The order of entries will match the order the checkboxes were clicked.

               

              "The replace command grabs the top entry, regardless if this was the last one entered or not, and displays that as the entry to replace with, which is not typically what you want.

               

              The other entries are truncated / invisible."

               

              Please give a specific example. If I click a check box and then choose replace field contents using the "replace with" option, I can update all the records of the found set to store the same values I have in the current field of the current record. This would appear to be correct, expected behavior so I'm guessing you are attempting something different.

               

              Note: In the dialog box, I will see only one value quoted even if I've selected multiple values. That's because filemaker stores the values separated by carriage returns and the dialog box only has one line to display the current field's contents. The replace itself will work correctly.

              • 4. Re: Replace field contents shows wrong string when used in check box field
                cbum
                  

                Yes are indeed describing the behavior, correct or not.

                 

                The problem is twofold: one, the quoted value in the dialog does not (fully) reflect the replacement, since items beyond the first CR are invisible.

                 

                Two, and more serious, although a longstanding issue, is that to enduser assumes the different items in the check box are handled separately, while FM happily replaces the entire field and wipes out data expected to remain untouched (e.g. you have items 1 OR 2 checked, and want to check 3 on all records - you either get all 1&3 or all 2&3 checked.)

                • 5. Re: Replace field contents shows wrong string when used in check box field
                  philmodjunk
                    

                  Actually both issues are "long standing". Filemaker has never listed multiple values in the replace dialog. It would be a nice upgrade if Filemaker's replace dialog did show all selected values.

                   

                  Personnally, Replace Field Contents is a good tool to keep out of the hands of everyday users. It's a powerful tool that can fix a lot of problems, but it's very power makes it dangerous to your data in the hands of an uninformed user--even if a check box field is not involved. This is especially true when using this tool on a shared database as a record locked by another user will be "skipped" during the replace. Filemaker will tell you that "x records were skipped..." after you do the replace, but often there will be no simple way to figure out which records were actually skipped.

                  • 6. Re: Replace field contents shows wrong string when used in check box field
                    cbum
                       No argument there, but I could use a better way to deal with this myself. These limitations essentially destroy much of the utility of this otherwise very useful field type.
                    • 7. Re: Replace field contents shows wrong string when used in check box field
                      philmodjunk
                        

                      Well, since we can't just snap our fingers and get FM inc to put in the features we want, ( I tried that, but now my fingers hurt :smileyvery-happy: ) we can post a suggestion on their feature request form and program work arounds in our database.

                       

                      You could script this operation and use either a special layout and/or a custom dialog to confirm for the user the results of your replace operation and then use a script to kick off the replace (no dialog option selected) to do the replace after the user confirms it.

                      • 8. Re: Replace field contents shows wrong string when used in check box field
                        comment_1
                          

                        cbum wrote:

                        The problem is twofold: one, the quoted value in the dialog does not (fully) reflect the replacement, since items beyond the first CR are invisible.

                         

                        Two, and more serious, although a longstanding issue, is that to enduser assumes the different items in the check box are handled separately, while FM happily replaces the entire field and wipes out data expected to remain untouched (e.g. you have items 1 OR 2 checked, and want to check 3 on all records - you either get all 1&3 or all 2&3 checked.)


                        I agree that the display is faulty.

                         

                        However, the result of the action is perfectly correct - and enduser has no grounds to assume otherwise.


                        • 9. Re: Replace field contents shows wrong string when used in check box field
                          philmodjunk
                            

                          "....and enduser has no grounds to assume otherwise."

                           

                          As an experienced user yes, but if I were new to filemaker and saw only one of several checked items listed in the dialog? In that circumstance, I think there are definitely grounds for such a new user to assume otherwise until that new user actual uses Replace Field Contents a few times and learns all selected values will be used in the replace operation.

                          • 10. Re: Replace field contents shows wrong string when used in check box field
                            comment_1
                              

                            Is there a developer in the picture? If not, let the user read the help before trying out stuff - or learn the hard way. If yes, then enduser has no business seeing that dialog, ever.

                             

                            Anyway that's all beside the point. The important thing is that the actual behavior is correct, and the last thing we need is FMI trying to "correct" it.

                            • 11. Re: Replace field contents shows wrong string when used in check box field
                              philmodjunk
                                
                              Comment wrote:

                              Is there a developer in the picture? If not, let the user read the help before trying out stuff - or learn the hard way. If yes, then enduser has no business seeing that dialog, ever.

                               

                              I agree that the end user should not see this dialog. That's why I mentioned layout/custom dialogs that can be used to avoid it.

                               

                              "Anyway that's all beside the point. The important thing is that the actual behavior is correct, and the last thing we need is FMI trying to "correct" it."

                              Filemaker should correct the information shown in the Dialog not the behavior of the Replace action. That's the point of this thread. (It took a bit to clarify from the first post, but that IS what this thread is about.)

                               

                              This is a basic WYSIWYG principle. The dialog should accurately describe what is about to happen when the Replace button is clicked. In the case of check box fields, this is not always the case.

                               

                              "let the user read the help before trying out stuff - or learn the hard way"

                              Reading the help file won't tell the user that "Replace Fields really will work correctly, it just doesn't look that way in the dialog." and a simple update of the dialog box to show all values (or at least indicate that there are multiple values) in the current field or simply including a "..." after the first value would be better than the current version.

                               

                              Nuff said. You have your opinion. I have mine. Off to the suggestion form to suggest an improvement.

                              • 12. Re: Replace field contents shows wrong string when used in check box field
                                cbum
                                   sorry, but showing anincomplete and often missleading string is NOT behaving correctly, IMHO...
                                • 13. Re: Replace field contents shows wrong string when used in check box field
                                  comment_1
                                    

                                  Is there some problem with the way my posts are being displayed?

                                  I seem to have unusual difficulties with getting even the simplest message across - like:

                                   

                                   

                                  I agree that the display is faulty.

                                  • 14. Re: Replace field contents shows wrong string when used in check box field
                                    cbum
                                       I was responding to your comment that " the last thing we need is FMI trying to "correct" it ".
                                    1 2 Previous Next