473,546 Members | 2,239 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Visible field question

22 New Member
I have fields that are set to be visible or not visible based on the value of another field. These results are displayed in a continuous subform. It works fine except that it only displays the visibility results for the first entry in the sbuform! If the field is set to Yes, all results display for yes, but will change to No when I click on that record (and changes all records to reflect "No". How can I make the records reflect the correct visible fields when it loads per record. Here is the code I am using...

In the On Current event for the subform I have this...

Private Sub Form_Current()

If Me!Algorithm = -1 Then
Me![Reqt AYES].Visible = True
Me![Units AYES].Visible = True
Me![Driver].Visible = True
Else
Me![Reqt AYES].Visible = False
Me![Units AYES].Visible = False
Me![Driver].Visible = False
End If

If Me!Algorithm = 0 Then
Me![Reqt ANO].Visible = True
Me![Units ANO].Visible = True

Else
Me![Reqt ANO].Visible = False
Me![Units ANO].Visible = False

End If
End Sub

Please help! I am not very experienced with codes so maybe I am just missing something?
Oct 23 '06 #1
2 1852
MMcCarthy
14,534 Recognized Expert Moderator MVP
You can't do what you want to do. The only conditional formatting options offered by access are to change the colour, font or enabled property of the control that the condition is on. In other words you could disable Algorithm but you cannot affect other controls based on the value in Algorithm.
Oct 23 '06 #2
aharding
22 New Member
darn...thanks for letting me know
Oct 23 '06 #3

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

Similar topics

5
5536
by: Lyn | last post by:
Hi, I have a form which contains a number of subforms in different pages of a tab control. In the detail section of each subform, I list records related to the main form record, but from different tables. In the footer section of the subform I have a Notes text box and three buttons (Add, Update, Delete). The latter each open a separate...
6
19237
by: kingphillip | last post by:
Can someone help me with some code to make a text box and lable visible only if the field in the table has something in it? Thanks
1
1997
by: tony | last post by:
Hello!! I have an application that consist of several windows forms. Lets call these A,B and C for simplicity. I have one main meny where the user can choose window form A or B or C. When a user bring up a window for the first time I create an instance otherwise I just set visible = true. When a user brings up a window form for example...
2
3386
by: sarah | last post by:
Hi there Hope someone can help - this is driving me mad. I have been able to complete this using Access 97 but not Access 2003. I would like to make a field enabled after the previous field has been completed. i.e. If field "Invitation Accepted" = Yes then activate the field "NoOfTickets". I have tried the following but it always comes...
4
2660
by: Jimmy Stewart | last post by:
I have a calculated control "ContactInfo" on my form ... ="Attn: " & In the OnCurrent event for the form I have the following code... If Me.Contact Is Null Then Me.ContactInfo.Visible = False End If The idea is, that if there is no contact listed (I have the contact field on the form with visible property set to no) then this line will...
6
5108
by: Robert | last post by:
Quick question about the visible property on a form control. I have a label that displays a message if a certain criteria is met. By default the label is visible. I want access to compare a calculated field on a tab page with a control on the main part of the form: If Me.CalculatedControl = Me.MainFormControl Then Me.MessageLabel.Visible =...
1
3339
by: pdm | last post by:
hoi access, I have a subreport and with the id of inheritance of OOP I like to reuse this subreport in other main reports and hide some fields. First, is this possible and second what is the correct syntax. I tried many combinations but error on syntax. first I create a MainReportFeedMainReports with only one subReport where 5 fields are...
1
2996
by: feeman | last post by:
I have a form in access 2000 with a combo box containing names, this is linked to a sub form by the name index. on the sub form is a button that when pressed automatically enters the date into the date field. Now my problem is that when someone comes in and finds their name and presses the sign in button it is no longer visible so they can...
4
7799
by: thecheyenne | last post by:
Hi there everybody; Fresh from reading my Access VBA for Dummies, I'd like to update my database about activities on a school outing. Here's what I'd like to achieve. The school outing costs money - nothing's for free these days. The prices for the individual activities are stored in tbl.prices; in this table, there are 3 fields: PriceID,...
0
7694
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. ...
0
7947
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...
1
7461
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...
0
6026
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...
0
5080
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...
0
3491
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...
0
3470
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
1921
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
1
1046
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.