As a follow up to the earlier thread, I am trying to build an all Access chat.
It should be a fairly simple project. To understand it fully, it would be necessary to learn more about the setup and solutions already implemented in the application. The information can be found in the already mentioned thread, in post #77.
The application will be designed for communication between two people on the local network.
The chat data will be stored in tblChat containing fields: ID, Person1Text, Person2Text, TimeStamp, conditionSeen1, conditionSeen2. The table will be stored in the beDB (please see the thread, post #77 for more reference).
The chat information will be presented in the subform or the main form frmTasks (reference thread, post #77). The chat message will be entered from the text field on the main form (frmTasks) to prevent interfering in cases when both users are entering the message and triggering simultaneous Loop-updating (reference thread, post #77) of the remote subform. The subform will have a name frmChat and will be continuous form. The frmChat will be part of 4 front end files (reference thread, post #77).
Received messages are located on the left side in the form's detail, sent messages on the right. The back color of the text fields are the same as the back color of the form (invisible). Using conditional formatting, when the form text filed is not Null, the back color of the text fields change (lighter color for a received, darker color for sent message) and the non-empty fields shows up.
I will post the final solution later in the thread, once the project is completed.
The chat is already functional but needs some fine-tuning. I would appreciate the support on the different issues along the way.
The issue I am currently facing is sizing the message box on the subform according to the message size. As one message can be anything from one row to many more rows, the text boxes must be somehow size-adaptable. If the text box is too high, form space is being lost (and it can never be high enough). If the text box is just one row high, the user is limited to type messages using only a certain number of characters per message. The best solution I could think of so far is to store message information in the table with max number of characters per row. For example, if max number of characters per row is set to 20 and the message has 50 characters, it would be stored in a table under 3 rows (3 IDs) 20char + 20char + 10char. Probably using the Len function. Later in the appearance, text fields are located Top = 0 and hight the same as hight of the detail, appearing closest to one "cloud" per message, as the text boxes will stick to each other. To be able to edit/delete a full message, regardless of the row numbers (different IDs in the table), one more field would be added in the table, storing the exclusive number for the group of rows (IDs) that belong to one message. Something like a group ID. The setback to this solution is that there is a line between text fields in the form. I cannot find a way to make the appearance of a single "cloud".
As this is not an appropriate solution, any suggestions on solving a single-cloud-per-message appearance issue are more than welcome. The project is at the beginning. Any work already made is easy to change at this stage. So, how would it be possible to make the one-cloud appearance?
It should be a fairly simple project. To understand it fully, it would be necessary to learn more about the setup and solutions already implemented in the application. The information can be found in the already mentioned thread, in post #77.
The application will be designed for communication between two people on the local network.
The chat data will be stored in tblChat containing fields: ID, Person1Text, Person2Text, TimeStamp, conditionSeen1, conditionSeen2. The table will be stored in the beDB (please see the thread, post #77 for more reference).
The chat information will be presented in the subform or the main form frmTasks (reference thread, post #77). The chat message will be entered from the text field on the main form (frmTasks) to prevent interfering in cases when both users are entering the message and triggering simultaneous Loop-updating (reference thread, post #77) of the remote subform. The subform will have a name frmChat and will be continuous form. The frmChat will be part of 4 front end files (reference thread, post #77).
Received messages are located on the left side in the form's detail, sent messages on the right. The back color of the text fields are the same as the back color of the form (invisible). Using conditional formatting, when the form text filed is not Null, the back color of the text fields change (lighter color for a received, darker color for sent message) and the non-empty fields shows up.
I will post the final solution later in the thread, once the project is completed.
The chat is already functional but needs some fine-tuning. I would appreciate the support on the different issues along the way.
The issue I am currently facing is sizing the message box on the subform according to the message size. As one message can be anything from one row to many more rows, the text boxes must be somehow size-adaptable. If the text box is too high, form space is being lost (and it can never be high enough). If the text box is just one row high, the user is limited to type messages using only a certain number of characters per message. The best solution I could think of so far is to store message information in the table with max number of characters per row. For example, if max number of characters per row is set to 20 and the message has 50 characters, it would be stored in a table under 3 rows (3 IDs) 20char + 20char + 10char. Probably using the Len function. Later in the appearance, text fields are located Top = 0 and hight the same as hight of the detail, appearing closest to one "cloud" per message, as the text boxes will stick to each other. To be able to edit/delete a full message, regardless of the row numbers (different IDs in the table), one more field would be added in the table, storing the exclusive number for the group of rows (IDs) that belong to one message. Something like a group ID. The setback to this solution is that there is a line between text fields in the form. I cannot find a way to make the appearance of a single "cloud".
As this is not an appropriate solution, any suggestions on solving a single-cloud-per-message appearance issue are more than welcome. The project is at the beginning. Any work already made is easy to change at this stage. So, how would it be possible to make the one-cloud appearance?