473,320 Members | 1,848 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,320 software developers and data experts.

Going through the field list !

I have a form displaying a table in continuous view.

There is a combo-box in the footer containing the list of fields in the
table.

When the user selects a field from the combo-box, I would like to
change the back-color for the "selected" field to say "X" and set the
back-color of all the other fields to say "Y".

Could anyone please post some code showing me how to do this. I've gone
crazy trying to get this to work.

Thx & Best Rgds,
Prakash.

Nov 13 '05 #1
1 1509
On 6 Oct 2005 07:52:26 -0700, pr*************@gmail.com wrote:
I have a form displaying a table in continuous view.

There is a combo-box in the footer containing the list of fields in the
table.

When the user selects a field from the combo-box, I would like to
change the back-color for the "selected" field to say "X" and set the
back-color of all the other fields to say "Y".

Could anyone please post some code showing me how to do this. I've gone
crazy trying to get this to work.

Thx & Best Rgds,
Prakash.


Code the Combo Box AfterUpdate event

Dim c As Control
For Each c In Controls
' Reset all controls to the original backcolor
If TypeOf c Is TextBox Or TypeOf c is ComboBox Then
c.BackColor = vbWhite ' or whatever color you want
End If
Next
' Set the backcolor of the field selected in the combo box
Me(ComboName).BackColor = vbBlue ' or whatever color you want
--
Fred
Please respond only to this newsgroup.
I do not reply to personal e-mail
Nov 13 '05 #2

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

Similar topics

2
by: G.Gerard | last post by:
Hello Does anyone know how to get an entire memo field to be displayed in a combo box drop down list? Example - if the memo field contains the following : This is a test to see if
1
by: Jonathan | last post by:
I have belatedly discovered an odd problem. I created a new memo field called "IntellectualAccessNotes" in a replicated table . I put it into a form and people have been entering data into it and...
1
by: Don Leverton | last post by:
Hi Folks, I have been given a CD with approx 130 .xls files (bean-counters!) that I would like to import and merge to ONE table (tblTradeshow). The XL files are *similarly*, but not...
2
by: Rooksarii | last post by:
Hello folks, Let me first apologize for any impropper terminology I may use as I am presently trying to broaden my Office knowledge by diving into Access head on. My specific problem is this....
8
by: AA Arens | last post by:
Hi I do have a products table and products-parts table in my Access 2003 database and log all services into a form. I do have at least the following two combo boxes on my form: - Choose...
1
by: ebernedo | last post by:
Hey guys, I have two main questions First off (pictures are kind of blurry) I have this table http://i197.photobucket.com/albums/aa109/ebernedo/DiscTable.jpg And thats my database I use my...
8
by: gurmet | last post by:
I have two tables; 1. Called "Courses" that contains two fields "Course ID" and "Course Name". 2. Called "Sessions" that contains a field called "Course ID". Then I have a form with a...
12
by: jayjayplane | last post by:
Thanks everybody here answered my last data field validation question about the alert of future date. Here I get another question, sorry, I am really an Access newbie... The question is : I...
1
DebadattaMishra
by: DebadattaMishra | last post by:
Introduction In case of rich applications, you must have observed that a text field behaves like a dynamic combo box. When the user enters some characters in the text field, a popup will come up...
0
by: DolphinDB | last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation. Take...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
0
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

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.