Text Editor? (1 Viewer)

smiles_chicago

New member
Local time
Today, 03:03
Joined
Oct 21, 2008
Messages
3
Greetings! Newbie here. I have a form with a lot of fields...one of which is a memo field. Users add text to this and we can scroll up and down to see the entry. Is it possible to add a button which when clicked the user can see the entire contents in a text editor at the same time (forexample to enter a summary they now see what they entered a few lines at a time- I want them to be able to see the entire contents at the same time and be able to spell check etc?
Does my question make sense?
Thanks in advance!
Jas
 

Uncle Gizmo

Nifty Access Guy
Staff member
Local time
Today, 11:03
Joined
Jul 9, 2003
Messages
15,823
I don't know of anything that will do what you want.

My suggestion is you create a new form linked to the same table as your main form, on that form have one text box linked to your memo field. Expand this text box so it takes up most of the form , make the form a decent size for text editing. Have a button on your main form which opens this editing form to the correct record.
 

missinglinq

AWF VIP
Local time
Today, 06:03
Joined
Jun 20, 2003
Messages
6,423
You could use the ZoomBox command, but you have no control over the size of the popup that it generates, so I roll my own. Rather than adding an extra button, I simply use the Double-Click event on the textbox to popup the "zoombox."

You need to create a textbox named MyZoomBox. Position it and size it like you want. With it selected, goto Properties - Data and set its Control Source to the same field as the original textbox. Then use this code

Code:
Private Sub Form_Current()
  'Closes the zoombox in case you leave the last record without doing so  
  MyZoomBox.Visible = False
End Sub

When you Double-Click the original textbox, the "zoombox" pops up. Just replace YourTextBox with the actual name of your textbox holding your memo field:

Code:
Private Sub YourTextBox_DblClick(Cancel As Integer)
  'When you double click the field, make the MyZoomBox
  'visible and move the cursor to the end of any text
   MyZoomBox.Visible = True
   MyZoomBox.SetFocus
   If Not IsNull(Me.MyZoomBox) Then
     MyZoomBox.SelStart = Len(Me.MyZoomBox)
   End If
End Sub

When you Double-Click the "ZoomBox" it runs SpellCheck then closes it
Code:
Private Sub MyZoomBox_DblClick(Cancel As Integer)
'Double click the MyZoomBox to close it, run
'Spellcheck and return to your original field
 If Len(Me.MyZoomBox.Text) > 0 Then
   DoCmd.SetWarnings False
   MyZoomBox.SelStart = 1
   MyZoomBox.SelLength = Len(Me.MyZoomBox.Text)
   DoCmd.RunCommand acCmdSpelling
   MyZoomBox.SelLength = 0
   DoCmd.SetWarnings True
 End If
    Me.YourTextBox.SetFocus
    MyZoomBox.Visible = False
End Sub
 
Last edited:

missinglinq

AWF VIP
Local time
Today, 06:03
Joined
Jun 20, 2003
Messages
6,423
I think so. I use a fair number of memo fields for things like summaries and progress notes, and I never liked the standard ZoomBox because, like a messagebox, you can't control the size or positioning of it.
 

smiles_chicago

New member
Local time
Today, 03:03
Joined
Oct 21, 2008
Messages
3
Re: Text Editor?-THANKS!

I love your idea! Thanks! I did create the form but when I click on the button it opens the new form but not to the correct record? What do I need to do for it to open to the right record?
Thanks
Jas

I don't know of anything that will do what you want.

My suggestion is you create a new form linked to the same table as your main form, on that form have one text box linked to your memo field. Expand this text box so it takes up most of the form , make the form a decent size for text editing. Have a button on your main form which opens this editing form to the correct record.
 

Users who are viewing this thread

Top Bottom