473,796 Members | 2,654 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Activate textbox on mouse over, Showing linked data

daoxx
32 New Member
Hi

Question#1
Is it possible to show a textbox (linked to a field) when the mouse pointer goes over a checkbox, and hiding it when the pointer goes away, and at the same time allowing the user to handle it like a regular textbox? If so, how?

Question#2
What is the best way of showing data that is linked to other data?

Example:
Paul's ID is 1. If I select Paul in a combo box, how can I make a textbox get Paul's ID from the table People?
If I would select another person, that person's ID would show then.


Thank you so much.
Mar 24 '08 #1
9 3250
FishVal
2,653 Recognized Expert Specialist
Question#1
Is it possible to show a textbox (linked to a field) when the mouse pointer goes over a checkbox, and hiding it when the pointer goes away, and at the same time allowing the user to handle it like a regular textbox? If so, how?
Using the MouseMove Property

Question#2
What is the best way of showing data that is linked to other data?

Example:
Paul's ID is 1. If I select Paul in a combo box, how can I make a textbox get Paul's ID from the table People?
If I would select another person, that person's ID would show then.


Thank you so much.
You should use multicolumn combobox.
For your particular case it will look like the following
RowSource="SELE CT People.ID, People.Name FROM People;"
ColumnCount=2
BoundColumn=1
ColumnWidths=0; 1

Combobox will display name (2nd column), while its value saved to underlying table will be ID (1st column).

Regards,
Fish
Mar 25 '08 #2
daoxx
32 New Member
Sorry for my late response, but still thank you so much, Fish!

However, about #2, is it possible to show both fields in the combo box before clicking it?

Thanks again
Mar 30 '08 #3
FishVal
2,653 Recognized Expert Specialist
Sorry for my late response, but still thank you so much, Fish!

However, about #2, is it possible to show both fields in the combo box before clicking it?

Thanks again
Hi, daoxx.

Sorry for delay.
You may make both fields visible in combobox by concatenating them in RowSource query.

Example:
tbl.fld1 - field bound to combobox control
tbl.fld2 - field expected to appear in combobox together with tbl.fld1 separated with " | "
Expand|Select|Wrap|Line Numbers
  1. SELECT tbl.fld1, tbl.fld1 & ' | ' & tbl.fld2 AS fld12 FROM tbl;
  2.  
Combobox properties values are the same as in my previous post.

Regards,
Fish.
Apr 3 '08 #4
daoxx
32 New Member
I didn't get it, I've tried that and it shows me the same, but the fld1 shows up twice.
What is fld12?

Example:
tbl.fld1 - field bound to combobox control
tbl.fld2 - field expected to appear in combobox together with tbl.fld1 separated with " | "
Expand|Select|Wrap|Line Numbers
  1. SELECT tbl.fld1, tbl.fld1 & ' | ' & tbl.fld2 AS fld12 FROM tbl;
  2.  
Apr 3 '08 #5
FishVal
2,653 Recognized Expert Specialist
I didn't get it, I've tried that and it shows me the same, but the fld1 shows up twice.
Post the value of your combobox RowSource, ColumnCount, ColumnWidths and BoundColumn properties.
What is fld12?
[fld12] is just a name (BTW optional) to refer to the field obtained by fld1 / string constant / fld2 concatenation.
Apr 3 '08 #6
daoxx
32 New Member
Ok, the values are:
Expand|Select|Wrap|Line Numbers
  1. RowSource="SELECT Motoristas.ID_Mot, Motoristas.Nome FROM Motoristas;"
  2. ColumnCount=2
  3. ColumnWidths=1,085cm;2,514cm
  4. BoundColumn=1
PS: Please note the names are in my language so that they remain exactly the same, in case it has anything to do with the problem (Table Motoristas has ID_Mot as an ID field, and Nome as a name field).

Post the value of your combobox RowSource, ColumnCount, ColumnWidths and BoundColumn properties.

[fld12] is just a name (BTW optional) to refer to the field obtained by fld1 / string constant / fld2 concatenation.
Apr 5 '08 #7
FishVal
2,653 Recognized Expert Specialist
Try the following:
Expand|Select|Wrap|Line Numbers
  1. RowSource="SELECT Motoristas.ID_Mot, Motoristas.Nome & ' (ID: ' & Motoristas.ID_Mot & ')' AS txtNameAndID FROM Motoristas;"
  2. ColumnCount=2
  3. ColumnWidths=0cm;2,514cm
  4. BoundColumn=1
Regards,
Fish.
Apr 5 '08 #8
daoxx
32 New Member
Thanks! Works perfectly.

Try the following:
Expand|Select|Wrap|Line Numbers
  1. RowSource="SELECT Motoristas.ID_Mot, Motoristas.Nome & ' (ID: ' & Motoristas.ID_Mot & ')' AS txtNameAndID FROM Motoristas;"
  2. ColumnCount=2
  3. ColumnWidths=0cm;2,514cm
  4. BoundColumn=1
Regards,
Fish.
Apr 7 '08 #9
FishVal
2,653 Recognized Expert Specialist
You are welcome.
Good luck.
Apr 7 '08 #10

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

Similar topics

10
3581
by: Alex | last post by:
could someone please point me to a site with an explanation or give me a *very* simple example of a div that would open right below a textbox on a page. I've seen lots of examples out there. Unfortunately I don't have time right now to dig through that code to extract the basic functionality. The one implementation that really hits the spot can be found here: http://www.eworldui.net/CustomControls/CalendarPopupDemo.aspx look at the...
2
19876
by: Mamatha | last post by:
Hi I want to add an icon to the textbox's text. I don't know how to display icon in textbox in VB.NET. If any one knows please let me know. Thanks in advance. Mamatha
3
63443
by: Tom | last post by:
I have a picturebox on my VB.NET form. The picturebox size mode is set to stretched. I then load an image into that form and display it. As the user moves the mouse over the form, I want to get and display (in the status bar) the image coordinates of the mouse location. However, if I use the picturebox's MouseMove event, I am getting the coordinates of the mouse over the PICTUREBOX, not the actual image underneath that (which is stretched)....
8
30419
by: John | last post by:
Hi, I am developing an application using VB.Net and hope that the textbox can process features which are similar to auto-complete features in Window. For example, when user types "ap" in a textbox and the data associated to the textbox contains ("apple", "applet", "application"......), the application will suggest "apple" to the user to select and user can either select the suggestion or continue to type another word he disires. How...
2
4877
by: melanieab | last post by:
Hi, Is there an easy way to say, on textboxHover, if the text inside the box isn't completely visible, have a popup tool come up showing the complete contents of the box? I'm guessing I need to know if there's a way to determine the number of pixels that some generic text takes up. Also, is there a way to extract the pixel length from textbox.Size (to save some time looking values up)? Thanks so much!!! Mel
3
5418
by: Patrick [MSFT] | last post by:
Let me preface this with the goal I'm trying to achieve is mimic a feature of another language (Dexterity used by Microsoft Dynamics) and so while a filling a drop down list is a workable solution I'd rather do it like Microsoft Dynamics does and use separate textbox and lookup button. What I have is, simply, is a C# winform, a textbox and a pushbutton. On the textbox, on the validating event of the textbox I check my customer table...
0
1701
by: andytsummers | last post by:
Hi I have tried to implement drag and drop by using the following code but I have several problems. 1. When you put your mouse over selected text the cursor is still the i-beam and therefore does not show that the text can be dragged 2. When pressing the mouse button to start a drag the selected text changes - I know this is cause the code does not initiate the dodragdrop until the mouse leaves the control but if I change this then you...
10
10482
daoxx
by: daoxx | last post by:
Hello I've searched, posted and solved this (Thanks for helping!), but now it came back to bite me in the *ss. I have a Yes/No field that is represented by a check box in my form1. I want to show another field (textbox) when the mouse pointer goes over the checkbox, and make it not visible when the mouse moves away from it. My problem is that when I make the textbox diseappear, if the user set focus on it and moves the mouse away, Access...
2
8716
by: CGatto | last post by:
Hi, I have Windows Form with several User Controls embedded within. Only one user control is visible at any one time. The user moves through the various user controls by clicking Previous and Next buttons. What I want to happen is for the individual user controls to have the ability to set focus to a specific textbox control when the user control becomes active. Normally I would handle this sort of thing via a form's activate event,...
0
9527
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10453
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
10223
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
10172
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
10003
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...
0
9050
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 launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
6785
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 into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
1
4115
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
3
2924
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.