473,785 Members | 2,275 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Event procedure on 'unbound' textbox

31 New Member
I want to use temporary information from an unbound textbox, but i cant seem to run any code on an unbound textbox. Is this possible. I have it working with a bound "control" but cant seem to make it work with an unbound control.
Aug 21 '08 #1
8 3871
ADezii
8,834 Recognized Expert Expert
You can easily retrieve information from an 'Unbound' Text Box in the same fashion as a 'Bound' Text Box. The only difference is that, not to be redundant, it is not Bound to a Field.
Aug 21 '08 #2
Stewart Ross
2,545 Recognized Expert Moderator Specialist
Hi, and Welcome to Bytes.

You don't really provide us with much information here. Unbound controls can be accessed like any other and their contents can indeed be processed in code. But the values of unbound controls cannot be stored (as they are not bound to any underlying fields) so they are inherently volatile.

Unbound controls on a continuous form (or a datasheet view) also behave differently to bound controls, as the value of the control is not tied to each record. The set of controls displayed in a continuous form or datasheet view is really just one set, repeated on-screen for as many record rows as the screen can display. Unbound controls shown in such lists remain at whatever value they were last set to, showing on-screen as repeating the same contents for the whole list. Accessing the value of the unbound control in such circumstances is likely to yield disappointing results.

-Stewart
Aug 21 '08 #3
crazyhouse
31 New Member
Thanks for such fast responses. Here is what i have.

When i try to build an event for the unbound box, it doesnt automatically start the sub for me. So what i did was used the name of the unbound field (text35) in the line for the code so the code starts like this

Private Sub text35_afterUpd ate()

when i open the form i get this error

the LinkMasterField s property setting has produced this error:"Ambiguou s name detected: text35_afterupd ate'

I dont want the information to be bound to a field because i dont want the data stored, I appreciate any help that you can provide.
Aug 21 '08 #4
missinglinq
3,532 Recognized Expert Specialist
"Ambiguous name detected: text35_afterupd ate" usually means that you have two subs with this same name, which isn't allowed! Check your code to see if this is true.

Linq ;0)>
Aug 21 '08 #5
crazyhouse
31 New Member
thanks, sorry for the problems
Aug 21 '08 #6
ADezii
8,834 Recognized Expert Expert
thanks, sorry for the problems
It's not a problem, just try to be a little more clearer on what you are requesting. For starters:
When i try to build an event for the unbound box, it doesnt automatically start the sub for me.
What exactly do you mean by this statement?
Aug 21 '08 #7
missinglinq
3,532 Recognized Expert Specialist
Expand|Select|Wrap|Line Numbers
  1. Private Sub text35_afterUpdate()
The fact that the A in AfterUpdate isn't capitalized, your statement

When i try to build an event for the unbound box, it doesn't automatically start the sub for me.
and the fact that you apparently had more than one copy of this sub (hence the "ambiguous" error) makes me think that you are entering your code "freehand" which is to say typing all of the code, rather than selecting the control, going to Properties - Events, clicking on the desired event and going into the code window thru this route. If you're entering code without going thru this routine, it would explain a lot of your problems.

Linq ;0)>
Aug 21 '08 #8
crazyhouse
31 New Member
When i stated 'sorry for the problems' it was because i did have more than 1 event for the name. Once i got rid of the extra entries the code ran fine.
Aug 22 '08 #9

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

Similar topics

10
2324
by: MLH | last post by:
Would like to examine the value entered into a textbox on an A97 form during the BeforeUpdate event. The textbox may or may not have had an earlier entry in it prior to the latest value that is now in the process of being entered. What's the best way to refer to the value just typed that is about to update the textbox?
5
3342
by: Steve | last post by:
I have a datagrid in a WinForm. When the user edits an entry in the datagrid, after he leaves that field, I would like to do some cheking. What event fires when the user does that? I need to make sure that the value he modified does not create a dup value in my DB. Thank you for your help, Steve
0
2472
by: Matthew | last post by:
All, I have searched google and the newsgroups but can't find anything the same as what I am experiencing (though I may have missed something). I have controls (textboxes) within UserControls which are not behaving as I would expect. Specifically, if there is a command button external to the usercontrol which is activated by a shortcut key (eg Alt-B), the command button Click event handler code 'executes' even though the textbox set...
0
2440
by: Gary Shell | last post by:
I am experiencing some strange behavior between a UserControl's validating event and a treeview control. Initially, I thought it was related to an issue in the Knowledgebase article 810852 (http://support.microsoft.com/kb/810852), but then I realized that the hotfix mentioned was in .Net v1.1, which I am using. I took the sample from that article and recreated the situation I see in my application. (Code included below.) If you run the...
2
2161
by: Lenster | last post by:
Environment --------------- Visual Studio.NET 2003 Version 7.1.3088 ..NET Framework 1.1 Version 1.1.4322 SP1 XP Professional 5.1.2600 SP2 Build 2600 Problem Description ----------------------- I have an mdi parent form.
1
2059
by: Robert | last post by:
Every thing worked fine until all of a sudden, I get the following error whenever I try to do anything on one of my forms that calls an Event Procedure. I get the error as soon as the form opens because I have an OnLoad event. If I take that out the form will open but I will get the same error if I attempt anything else that will call and Event Procedure. I am not having any issues with any other forms. Error is: The expression On...
0
3012
by: colleen1980 | last post by:
Hi: There are two textboxs in my main form. One is bound and another is unbound. There is no entry in the unbound textbox as values come into automatically after entering some information in the subform. My question is how to i pass values from unbound textbox to bound textbox every time when the value change in unbound textbox i need to change the value in the bound textbox. When the form load there is already value in the bound textbox...
3
11278
by: Richard | last post by:
How is the result of query placed in a unbound textbox ? Suppose CriteriaLookups has columns TableName, KeyColumn, KeyValue, DataColumn Foo,x,11,xhat Bar,z,3,xyzzy And
6
3203
by: Jim Devenish | last post by:
I have an unbound form that displays all the days of the year as a calendar. It has 12 rows of text boxes with either 29,30 or 31 in each row. Text box names are of the form: display_01_01, display_01_02 ... display_12_31. This is used to display bookings of holiday properties and works well. I am now wishing to be able to highlight a range of dates by double clicking in one text box and then in another, highlighting all the dates...
0
9647
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 usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10357
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10162
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 captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10101
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 most users, this new feature is actually very convenient. If you want to control the update process,...
0
9959
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
7509
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 instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5396
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 the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5528
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
3665
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.