PC Review


Reply
Thread Tools Rate Thread

Disappearing data in sync'd forms

 
 
=?Utf-8?B?cHJvdG90eXBl?=
Guest
Posts: n/a
 
      25th May 2007
I have a small sized text box in a form called frmMain. This text box may or
may not contain a large amount of text. If the text box does contain alot of
text I want to open up a new form called frmLargeText that contains a larger
text box to allow the user to easily see and edit the large amount of text. I
also need the two forms to stay in sync. i.e. if the user moves to a new
record then both forms move to the same record. I thought I could do this by
setting the recordset of frmLargeText to equal the recordset of frmMain as
follows:

Dim frm as Form_frmLargeText
Dim rst As DAO.Recordset
Set rst = Me.Recordset
Set frm = New Form_frmLargeText
Set frm.Recordset = rst
frm.Visible = True

This all works fine untill the user edits the data in frmLargeText. Here's
what happens.
1) User edits text box in frmLargText
2) User switches back to frmMain and edits a diferent field but as soon as
the user types something this field the original text in the field disappears.

Both forms are set to Record Locks = Edited Records.

Why is the original text disapering? Is there a way to prevent the original
text from disappearing?

Thanks,
 
Reply With Quote
 
 
 
 
John W. Vinson
Guest
Posts: n/a
 
      26th May 2007
On Fri, 25 May 2007 12:01:02 -0700, prototype
<(E-Mail Removed)> wrote:

>I have a small sized text box in a form called frmMain. This text box may or
>may not contain a large amount of text. If the text box does contain alot of
>text I want to open up a new form called frmLargeText that contains a larger
>text box to allow the user to easily see and edit the large amount of text.


An alternative approach is to train the user to hit Shift-F2 to open the built
in Zoom box.

>I also need the two forms to stay in sync. i.e. if the user moves to a new
>record then both forms move to the same record. I thought I could do this by
>setting the recordset of frmLargeText to equal the recordset of frmMain as
>follows:
>
>Dim frm as Form_frmLargeText
>Dim rst As DAO.Recordset
>Set rst = Me.Recordset
>Set frm = New Form_frmLargeText
>Set frm.Recordset = rst
>frm.Visible = True
>
>This all works fine untill the user edits the data in frmLargeText. Here's
>what happens.
>1) User edits text box in frmLargText
>2) User switches back to frmMain and edits a diferent field but as soon as
>the user types something this field the original text in the field disappears.


>Both forms are set to Record Locks = Edited Records.
>
>Why is the original text disapering? Is there a way to prevent the original
>text from disappearing?


You now have two completely independent and unrelated recordset objects, one
for each form.

John W. Vinson [MVP]
 
Reply With Quote
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Constant old reminders showing up and disappearing every time i sync my pda. favian Microsoft Outlook Discussion 1 20th Aug 2007 07:30 AM
Disappearing Appointments When Exchange Sync =?Utf-8?B?Q2hhcmxlcw==?= Microsoft Outlook Calendar 0 5th Jun 2006 12:30 AM
data disappearing problem on the forms when navigate =?Utf-8?B?YzY3NjIyOA==?= Microsoft ASP .NET 4 2nd Feb 2006 03:01 AM
Disappearing Forms Fred Worthington Microsoft Access Forms 20 24th Jan 2004 06:46 PM
Record sync between forms (NOT master and sub-forms) Cindy Microsoft Access 2 9th Aug 2003 01:52 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 07:18 AM.