10 Replies Latest reply on Nov 21, 2012 3:05 PM by MaxwellRobin

    BUILDING A MESSANGER IN FILEMAKER

    MaxwellRobin

      Title

      BUILDING A MESSANGER IN FILEMAKER

      Post

           Hi All!

           I have a Filemaker Database, which has multiple users on it.

           I was wondering if there was a way to make some sort of messenger so they can talk to each other while entering data.

           My idea is to have two fields

           One where the user can type the text and another where the chat would take place

           The user would type something in and then hit Enter

           When they hit Enter filemaker will get their username which could be the name registered to the account or just another field with text in it.

           after filemaker gets this name it will place it in the messenger followed by a ":" and then the text.

           Is this even possible? Im open to more ideas too!

           Idealy it would be a simple, yet as sophisticated as filemaker can make it, messenger so the users can chat through text in filemaker.

            

           Thank You!

        • 1. Re: BUILDING A MESSANGER IN FILEMAKER
          philmodjunk

               I've played around with that idea. The tricky part is that you have to have a script that keeps checking for new messages and brings them up if they are intended for the current user. Install OnTimer Script can be used for such a script that checks for messages.

          • 2. Re: BUILDING A MESSANGER IN FILEMAKER
            MaxwellRobin

                 i dont mind if everyone sees all the messages. anyone should be able to view the messages like a chat room. if that helps the situation. its just for simple communication purposes.

            • 3. Re: BUILDING A MESSANGER IN FILEMAKER
              philmodjunk

                   That simplifies the process a lot, but you still may need a periodic "refresh" script to keep the list of messages current.

                   You can set up a table for logging messages, one text field for the message, other fields can auto-enter the account or user name, as well as the date and time. If you set the window up with a layout based on this table, show all records and then sort them so that the most recently added record is listed first, you should get what you need and the Show All Records should elminate the need for a refresh. If you, instead pull up a found set of just some records, you then need a periodic script to kick in and update that found set or newly added records by other users won't be visible.

              • 4. Re: BUILDING A MESSANGER IN FILEMAKER
                MaxwellRobin

                     this seems logical but what i am looking for is to put the messenger in the footer of all my layouts so no matter where the user is in the document they can message. would that work?

                • 5. Re: BUILDING A MESSANGER IN FILEMAKER
                  philmodjunk

                       It can be made to work, but that sounds like you will have very limited space in which to display messages. I haven't tested it, but I think you'll need a periodic refresh script to get that to update.

                       To set it up, use a portal to your messages table with the X operator to match to all records. You may need multiple occurrences of this table to use in relationships to different other table occurrences before this will work with all of your layouts as your layouts may not all be based on the same table occurrence.

                  • 6. Re: BUILDING A MESSANGER IN FILEMAKER
                    Jade

                         I wish I could find the OP.  One poster used a scrolling banner in a web viewer to display messages from a text field.  The url was set to:

                          

                         "data:text/html,

                         <body style='border: 0; margin: 0'>

                         <marquee direction=right behavior=scroll scrollamount=10 scrolldelay=200>" &

                         News_Table::News_Field &

                         "</marquee>

                         </body>"

                    • 7. Re: BUILDING A MESSANGER IN FILEMAKER
                      philmodjunk

                           Cool!

                      • 8. Re: BUILDING A MESSANGER IN FILEMAKER
                        MaxwellRobin

                             i have narrowed it down to only two tables "Design" and "Spots" i can make it work and fit in the footer with a scroll bar on the side. do you think you could come up with a script? since i have no fields defigned yet only the two tables i can create as you say. would you mind giving me a step by step?

                              

                             thank you

                        • 9. Re: BUILDING A MESSANGER IN FILEMAKER
                          philmodjunk

                               I don't think you need any script to post a message. I haven't tested this over a network, so I don't know if a refresh script is truly needed or not.

                               The basic technique requires two scripts, the timer script and the script it performs on regular intervals:

                               Install OnTimer Script [ "RefreshScriptNameHere" ; 30 ] ---> specify an interval in seconds such as the 30 seconds specified here.

                               The refresh script may work with just Refresh Window[], but keep in mind that I have not tested this.

                          • 10. Re: BUILDING A MESSANGER IN FILEMAKER
                            MaxwellRobin

                                 so i got it to work using a portal.

                                 there is a table with a "name" "message" "message thread" and "timestamp" field

                                 the message field has a script trigger, which puts the text in the message field into the thread field, then inserts the current timestamp in the timestamp field, then creates a new record.

                                 on my two layouts where i want the messenger there are two portals

                                 one portal contains the "name" and "message" fields

                                 the other portal contains the "name" and "message thread" fields

                                 when i enter the name and message and exit the field it enters the correct information and creates a new record.

                                 when i try to create a new message all it does is replace the old message and add another blank record.

                                 is this a sorting issue? do you think i did something wrong?

                                 also what i would like is to have up to 4 different people in my network have their own "name"

                                 i can have them enter their name before each message and then that would work but is there a way to have them type it once and then have it save in that field? if two people are in the same layout would they keep replacing each other's name? any solutions or ideas?

                                  

                                 thank you