473,583 Members | 3,134 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Problem editing memo data in a text field in a Form

Since Access automatically highlights all of the text in a text
control (I use it to hold data from a memo field) when the control is
activated, I've added the following code to put the cursor at the end.

Private Sub txtCapability_G otFocus()

‘ Placed either behind the OnEnter or GotFocus Event of a control
named,
' in this case, txtCapability, on a form ensures that when the control
is
' activated, the cursor will automatically be placed at the END of all
' the text present in the textbox
' The "cursor at the end" code was taken from "Ten Tips for Microsoft
Access Developers"
' by Frank Rice. The code itself was created by Arvin Meyer, Microsoft
Access MVP
' and taken from a posting to the Access newsgroup
(microsoft.publ ic.access.forms coding)

Me!txtCapabilit y.SelStart = Me!txtCapabilit y.SelLength

End Sub

The problem is that when I want to edit the text I can only do it at
the end (where the cursor is). In order to begin editing in the body
of the text I have to first enter a space (at the end of the original
text), then I can move the cursor to the place I want to edit. If I
move the cursor first and start typing, the new text automatically
appears at the end of the original text.

Is there some code that I can add that will automatically put in a
space so that I can immediately move the cursor to the place within
the text that I want to begin editing? Or, better yet, is there a way
to activate a text field with data from a memo field and directly
start editing wherever I place the cursor?

This text control also has a macro assigned to "On Dirty" that
automatically updates the ChangeDate field to the current date (so
that the ChangeDate will always reflect the last time the Capability
field was changed). Could this have anything to do with it?
Nov 12 '05 #1
2 4247
jmr
I just tried this on one of my search screens that starts out
with a prefix as default. If I move the cursor to the start
or hit the home key, then type the number 2, it will appear
at the beginning of the prefix. I am using Access97. I have
had trouble with this function not working on a Terminal
server... What version of access are you using? Have you
checked for patches? Have you tried this before any patches
are installed?
On 23 Oct 2003 17:01:22 -0700, NewBob <bj****@calspac e.com> wrote:
Since Access automatically highlights all of the text in a text
control (I use it to hold data from a memo field) when the control is
activated, I've added the following code to put the cursor at the end.

Private Sub txtCapability_G otFocus()

‘ Placed either behind the OnEnter or GotFocus Event of a control
named,
' in this case, txtCapability, on a form ensures that when the control
is
' activated, the cursor will automatically be placed at the END of all
' the text present in the textbox
' The "cursor at the end" code was taken from "Ten Tips for Microsoft
Access Developers"
' by Frank Rice. The code itself was created by Arvin Meyer, Microsoft
Access MVP
' and taken from a posting to the Access newsgroup
(microsoft.publ ic.access.forms coding)

Me!txtCapabilit y.SelStart = Me!txtCapabilit y.SelLength

End Sub

The problem is that when I want to edit the text I can only do it at
the end (where the cursor is). In order to begin editing in the body
of the text I have to first enter a space (at the end of the original
text), then I can move the cursor to the place I want to edit. If I
move the cursor first and start typing, the new text automatically
appears at the end of the original text.

Is there some code that I can add that will automatically put in a
space so that I can immediately move the cursor to the place within
the text that I want to begin editing? Or, better yet, is there a way
to activate a text field with data from a memo field and directly
start editing wherever I place the cursor?

This text control also has a macro assigned to "On Dirty" that
automatically updates the ChangeDate field to the current date (so
that the ChangeDate will always reflect the last time the Capability
field was changed). Could this have anything to do with it?


--
Using M2, Opera's revolutionary e-mail client: http://www.opera.com/m2/
Nov 12 '05 #2
I am using Access 2002 with Service Pack 2. I started out with this
(i.e., no previous versions).
Nov 12 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
10446
by: Shyguy | last post by:
I want to create two buttons on a form. One would allow the user to Copy the contents of the current records memo field, the other would allow them to print. I set up a report based on the memo field, and it works. But, it seems wrong since I had to create a huge text box to accommodate memo fields with a lot of text. Thanks for any help,...
2
2493
by: PMB | last post by:
Thank you in advance for any and all assistance. I'm trying to input data from strings to a memo field. I would like to know how to check first to see if there is text there currently and if so move to the end and input the new text. Also, would like to know if I can change the justification on each line of text as it's entered. i.e. ...
3
2803
by: BlackFireNova | last post by:
I am working on an Access 2002 Database. I created a new table and imported some notes data into it from an existing table. Now, when I try to create a List Box, and it displays the list of fields to select from, I can see every field in the new table EXCEPT the VNotes field, (which is the one I imported the existing Notes data into). Can...
4
22743
by: intl04 | last post by:
I have a memo field that is included in some Access reports I created. Is there some way for the memo field to display nicely formatted text, with line breaks between paragraphs? Or is it necessary to export the report? I tried exporting a report by using the .rtf rich-text format (the plain-text format was the only other word-processing...
1
2393
by: Steemer | last post by:
Okay, I checked with usual suspects and I'm still frustrated. ..txt file, fixed width. About 88 fields of varying length. All text fields. It will only let me add seperators to about the 410th position but there are 420 positions. What's going on?
4
5399
by: Mal | last post by:
I have an ACC 2000 database that has a strange behaviour I have a small table, with just a few fields... My report has very simple grouping and sorting, no code bar a NODATA event. I have a memo field When CAN GROW is set to NO everything works just fine. When CAN GROW is set to YES - watch out.... One record causes BIG
2
1558
by: David | last post by:
I have a table which is to hold 70 memo fields to contain notes on data changes to corresponding fields in a form. The problem is I dont want to have to create 70 forms to input notes into. Is it possible to have one form that somehow opens up the correct notes field to input the notes. I was thinking along the lines of having a button...
1
2093
by: sck10 | last post by:
Hello, I am pulling data from a SQL Server table. One field that is (varchar 4000) is used to show notes. I am using a FormView for showing and editing the data. When the form is in Item view, the text runs together. All the line breaks are missing. When I enter into Edit mode, the text is formatted as it was entered (line breaks). ...
4
1730
by: Bob Alston | last post by:
My client insists that the printed copy of text entered into a memo field have EXACTLY the same layout as it appears on the screen. I found I had to eliminate the vertical scroll bar. Then I copied the memo field from the form to the report. I verified that the font and font size (MS Sans serif 8) were the same. However, the text shows...
0
7896
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
0
8328
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
1
7936
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
0
6581
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
1
5701
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes...
0
5375
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
0
3820
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
0
3845
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2334
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.