473,406 Members | 2,620 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,406 software developers and data experts.

Auto filling a text box on form close not working

Hi Everyone. I have a text box Text1 that needs to be auto filled from text box Text2 on form close. I've tried adding "Me.Text1.Value = Me.Text2.Value" to the code under form close, but I get an error. Is there another way to do this? Text1 is bound to a table so I can't use a formula as the control to accomplish it (as far as I know, but I'm awful at this stuff).
Aug 19 '15 #1

✓ answered by Seth Schrock

Try reading this article. It should help you out. Referring to Items on a Subform

7 1026
Seth Schrock
2,965 Expert 2GB
Try it in the form's UnLoad event. I don't think that you can edit any control value in the OnClose event.
Aug 19 '15 #2
I only have On Enter and On Exit as events for my form. It's a subform.
Aug 19 '15 #3
Seth Schrock
2,965 Expert 2GB
Then you can do it on the parent form and just reference the controls appropriately.
Aug 19 '15 #4
How do I reference them? Because I was trying that and when I went to start typing, it couldn't find them, and when I just manually typed the name in, it ended up erroring out.
Aug 19 '15 #5
Seth Schrock
2,965 Expert 2GB
Try reading this article. It should help you out. Referring to Items on a Subform
Aug 19 '15 #6
OK, I see what I have to do now, thank you again, you are SUPER helpful!
Aug 19 '15 #7
Seth Schrock
2,965 Expert 2GB
Glad it worked for you. Good luck on your project.
Aug 19 '15 #8

Sign in to post your reply or Sign up for a free account.

Similar topics

4
by: Scott Castillo | last post by:
Does anybody know how to auto-submit a form in PHP without Javascript? For instance, submit form variables to self, validate the data in PHP on same page, then, if no errors, auto-submit the data...
1
by: Jules Winfield | last post by:
My WinForms application can have any number of top level forms open at a given time. If the user selects File|Exit, all of the forms are closed. The loop to close the forms looks something like this:...
6
by: Robert C | last post by:
I have 2 forms, an unbound which calls a bound form via a command button. Both forms have a textbox called TDate. The name of the calling form is SelectionFrm. When I set the DefaultValue...
0
by: Gilgamesh | last post by:
Hi there, I'm trying to implement auto-soloing text on a windows form to display news to the user. I would like to give the user the ability to stop scrolling of the text, and then resume. Is...
1
by: rocksoft | last post by:
Hi, i have devloping web application in Asp.net and c#, i have used ajax to achieve the auto complete text box, my company using visual studio 2003, ajax auto complete text box...
4
by: DeanO | last post by:
I want info from one form text box to auto fill another form text box when the second box gets the focus. I tried an Expression did not work and I tried this code "Me!txtIncidentNumber =...
0
by: gobblegob | last post by:
Well i cannont remember where i picked this code up, but i have seen it asked for in many forums, Many times so i thought i'd add it here (Since this is my favourite forum). Auto scroll text in...
10
by: laredotornado | last post by:
Hi, I'm using php 5. Does anyone have any code or a function that auto submits a form that contains a single INPUT, of type = file? Thanks, - Dave
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
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,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
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...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
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,...

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.