Problem With Multi-condition Invisible Field

May 2, 2006

Hi.
I am using Access 97.
I have a problem with multi-conditional field showing or not.

Specifically:
I have 2 fields which can either be null, 0, or have a numeric value. These need to stay invisible to staff.
There are 2 other fields, also invisble in their properties setting, which need to become visible if both of the previous fields do not conain a value greater than or equal to 1.
Because these 4 fields are invisible by default, I put the following code in the settings for the 1st visible field in the form. I also tried it with when the form opens.
But it doesn't work or I get debug problems.

If (TOTAL___WAGE_RECORDS_E = 0) And (TOTAL___WAGE_RECORDS_E Is Null) And (TOTAL___WAGE_RECORDS_E_OS = 0) And (TOTAL___WAGE_RECORDS_E_OS Is Null) Then
Me!EMP_QUART_AFTER_EXIT_QUART.Visible = True
Me!EMP_QUART_AFTER_EXIT_QUART.Dropdown
End If

Please help.
Thanks!

Russ

View Replies


ADVERTISEMENT

Modules & VBA :: Loop For Labels Invisible / Not Invisible

Nov 8, 2013

I'm trying to get some labels and eventually text boxes to become visible on an input of a qty in a text box, but I can't get my syntax right.Here's what I have so far.

Private Sub More_qty_AfterUpdate()
Dim count As Integer
Dim pumplbl As String
For count = 1 To [More qty].Value
pumplbl = "pumplbl" & count
pumplbl.Visible = True

Next count

End Sub

View 3 Replies View Related

Invisible Field In Report?

Sep 30, 2014

[URL] making text boxes visible or invisible on a report depending upon criteria selected on a criteria form.

* I have a form [Frm_REPORT_Parameter_01] which has is a criteria selection menu related to a report. Among other criteria, is a combo box [CboGrade] which has the following options to select from "All", Excellent", "Good", "Fair", and "Poor"

* I have a report [FacilityIdentityReportDR]

* On this report, I have a trext field [TxtConditionHdr] that I want to make visible or invisible depending on what is selected in the form as criteria.

* I have a query [QryRPTFacilityIdentityRating01d]

The form criteria feeds the query that is the source for the report and the VBA coding behind the command button of the form is below. I have bolded my vba coding attempt to make the text field visible or invisible.:

Private Sub Command22_Click()
Dim strCrit1 As String
Dim strCrit2 As String
Dim strCrit3 As String
Dim strCrit4 As String

[code]....

View 8 Replies View Related

Visible / Invisible Text Field

Jan 19, 2006

on a report that has 2 pages, how can I make a text box in the bottom of the report page 1 invisible, but visible on page 2

you help will be much appreciated

Jabez

View 7 Replies View Related

Forms :: Make A Field On Form Invisible

Mar 24, 2015

I have a main form that has 2 subforms. I have a field on both forms that I have marked as "Visible="No". Both are text box controls and I have made sure that both the label and the text box itself are marked "Visible="No". In the first subform, it works correctly, while on the second one, it still displays.

View 2 Replies View Related

Field Visible Or Invisible Based Off Of Combo Box

Jul 16, 2014

Form name: TestForm
Combobox name: cboName
Names in combobox: Rick, John, Sarah
Feilds: Feild1 Feild2 Feild3

EDIT: The names in the combobox are coming from their own table, they were not manually put into the combobox.

Here is some pseudocode for what I kind of want to do...

[open TestForm]

if cboName = Rick
Field1.Visible = true
Field2.Visible = false
Field3.Visible = false
if cboName = John
Field1.Visible = false
Field2.Visible = true
Field3.Visible = false
if cboName = Sarah
Field1.Visible = false
Field2.Visible = false
Field3.Visible = true

View 14 Replies View Related

Reports :: Make Fields Invisible In Detail Or Field Header?

Aug 20, 2013

Is there a simple way, or special event, that can be used to turn off the visibility of fields when they are in the detail or in a created header for a field?

I tried using the report's Load event, but this kept giving me errors. Are any of the events in the detail able to allow this?

View 7 Replies View Related

Setting Some Text As Visible Or Invisible In A Tabular Form Wrt Boolean Field

May 3, 2006

Hi there,

I know there have been a good number of questions about visibility in forms already but I couldn't find a solution to my problem (or maybe I just didn't get it).

Basically, I have a tabular form (more than one record displayed at once) and one the field is of the Yes/No type. For each record, I'd like to have a text box that displays 'pending', set as visible if the field value is 'Yes' and set as invisible if the field value is 'No'.
The table is as follows:
id : auto-number
Flag: Yes/No [Yes]

If I use the following code on the Flag button:
Private Sub Flag_AfterUpdate()
Me.pending2.Visible = Me.Flag.Value
End Sub

all the 'pending' text boxes appear and disappear together (instead of just the relevant one).
I thought of using another text box, with the same data source ('Flag') but which would set itself to visible or invisible wrt to its own value but I couldn't find a way to do it.

Any suggestions ?
Thanks in advance !
and many thanks already for the forum and the contributions - it's been extremely helpful, esp. for a beginner.

View 2 Replies View Related

Making Form Buttons Visible/Invisible Depending On The Contents Of A Field

Oct 23, 2004

I am trying to make a button on a form visible and invisible dependant on the contents of a field in my form, any ideas?

View 3 Replies View Related

Adding Value To A Field When Condition Is Met

May 19, 2015

I need for a valued to be changed in a row after it checks for how many rows have another value, counting how many and that number making it the amount field.

Example:
Fields- Name sponsor amount

I want access to show how many people have been sponsored by Gabriel... So if 3 where sponsored by Gabriel show 3 to the amount field for Gabriel row! Any way to do this or an easier way?

I for it to check it every time a user is added incase the user added is sponsored by Gabriel add it automatically!

View 14 Replies View Related

Adding One Field Of New Record Automically According To The Condition

Feb 21, 2008

hi all,

I am doing one project using access. I 've made two forms. In one form, lets say, it contains two common buttons. Both buttons will load the same second form and will add new record to the same table. When I click first button, it will load second form with all fields blank and one field of record will autofill one value,lets say "a" to the table.That field shouldn't be appeared in the second form,just want to fill automatically. Then the other fields of new records will be filled by the user input from the second form.
Also, when I click second button, it will do similarly but only the autofill value will be different from the first one.
Does anyone know how to make it?
If don't understand what I am saying, I can explain it again.
Any help will be grateful for me.

View 5 Replies View Related

Forms :: Update Value In A Field Based On A Condition

Jan 25, 2015

I have a calculated field in the form footer which adds up the number of boxes that have been ticked for the received field

=Sum(IIf([Recieved]=Yes,1,0))

If the ticks equal to 3 then I want to update the status field in another table to "Active".I am trying this VBA code but it won't work.

Code:

If Text9 = "3" And custNumber = tblCustomers.custNumber Then
tblCustomers.Status = "Active"

View 3 Replies View Related

Queries :: Condition Format A Date Field

Aug 9, 2015

condition formatting a date field in access.The query used for this field produces a date or "NA" based on the formula below. so when the date shows up as "NA" then i have set the condition formatting of the cell to grey and this works works well. but when it shows up with a date it doesnt format to a grey.the formatting pane has these two expressions

1. Q_Induction_Date = "NA" then grey the cell

2. Q_Induction_Date < DATE() then grey the cell and this DOESNT work. i have also tried the function Now() and that doesnt work either.

Formula i use in the query is

Q_Induction_Date: IIf([y].[INDUCTION_NA]=-1,"NA",IIf(IsNull([induction_date]),"NA",Format([induction_date],"dd/mm/yyyy")))

View 4 Replies View Related

Reports :: Change Text Of A Field To Blue Color If A Certain Condition Is Met

Oct 8, 2014

I have a report which I would like to change the text of a field blue if a certain condition is met. What I want to happen on this report is if a specific field has an "Active" - then it will be in Blue text, otherwise it is in black text.

I have gone into the report ->in the Details section -> put a procedure in the On Format event. The code I have been trying is:

-----
If Analysis_Status = Active Then
Me.Analysis_Status.ForeColor = vbBlue
Else
Me.Analysis_Status.ForeColor = vbBlack
End If
End Sub
----

View 6 Replies View Related

Forms :: Condition A Field To Locked On 1 Record Of Continuous Form Subfile

Jun 1, 2015

Access 2002 . Can I condition a field to 'locked' on just one record of a continuous form subfile, based on the contents of a 2nd field in same record?

View 14 Replies View Related

Multi-field Index

Dec 29, 2005

I am trying to set a multiple field index on a table. I would like to use 3 fields. One is a text field, the other two are date fields. The text field and one date field will always have a value. The other date field can either have a value or no value. The index will work if I only use the text field and date field that always have values. If I try to add the third field, it will not find a duplicate record. Can I not include a field that may have a null value?

View 5 Replies View Related

Multi Field Validation

May 25, 2005

Found some great code, else where that perhaps someone else can use.

Each required fields tag property - change to required
Dim blnContinue As Boolean
Dim ctl As Control
blnContinue = True
For Each ctl In Me.Controls
If ctl.Tag = "Required" Then
If IsNull(ctl) Then
MsgBox "Required Information Missing", vbCritical + vbOKOnly + vbDefaultButton1, "You must fill in the x xx xxx xxxx fields"
Cancel = True
ctl.SetFocus
Exit For
End If
End If
Next ctl
Set ctl = Nothing
End Sub

View 1 Replies View Related

Default Value For Multi-value Field

Aug 12, 2014

I have created a multivalue field based off of URL... I am getting my values from a different table from within the database. My issue is that I tried to create a default value for the lookup field but it made another selection within the lookup field.

Example:

Reference Table Values are:

Name 1
Name 2

Field referencing table with my defined default value:
Name 1
Name 2
Name 1

View 1 Replies View Related

Multi Record/Query/Multi Table/Going Crazy Issues

Sep 7, 2007

I have spent the last couple of days trying to figure out how to make this work.

I have three tables.

tblIntakeMain
[IntakeMainID]

tblIncidentDetails
[IncidentdeatailsID]

tblPersonnel
[PersonnelID]

On the main form I use subforms to link tblIncidentDetails and tblPersonnel to tblIntakeMain. Both subforms can, and do, have many entries. This all works fine. What is not working is the search form I am using.

I am using Gromits most excellent Search Form. The problem is when I create a query, qSearch, to bring together the three tables I get a multiple records which makes the searches very confusing and near useless. Is there anyway around this? Is there something I am missing? Is there another search method I could use that would work in a similar way as Gromits? Please help before the Prozac runs out and I lose my mind--what little it left.

View 5 Replies View Related

Multi-table, Multi-criteria: Avoid Repeating Records

Apr 10, 2008

Hi everyone. Apologies if this has come up before, but the search terms I've tried here and on google keep turning up the wrong information.

At work I manage a large database with many tables. It stores data for participants in a research study. Each table stores the data for a different test, so one participant may have multiple records. Primary keys for these tables are defined by a combination of the participant and date of test fields. (Everything is dependent upon a table that stores the static info for participants, so the database is normalized.)

I want to be able to make a table that lists target participants and dates, and then create a query that looks at this table and pulls all the available data from various tables for those individuals that was recorded within one year of the target dates.

I've successfully made queries that meet these criteria while pulling data from only one table. The problem I'm having is that when I try to pull from multiple tables, each with it's own date field that needs to be used as a criterion, I end up excluding almost all the data, because most of the target participants do not have all the requested data within the target dates.

I've tried being inclusive with my criteria (using ORs), but then I end up with tons of data that I don't want and I need to filter through it, which defeats the purpose of the query.

Any advice on handling this issue, or do I basically just need to create a separate query for each table?

I'm sorry if this is too vague, but it's illegal for me to upload any of my own dataset. I could probably come up with an example if it's helpful, though.

Thanks!

View 7 Replies View Related

Access Query Multi Field Help?

Sep 7, 2006

I have a database... 1 table...40 fields..

I currently have a query set up as a basic a LIKE search for each field and I have to do 40 each time..

Is there a way of being able to do 1 query and have it search all 40 fields?

So my field headings are
Part No
Description
barcode..
Album name
Singer/Group
and so on...

I since some of the albums are compliations I require to search all the fields...

Any ideas?

View 6 Replies View Related

Tables :: Multi-field Unique Key

Feb 8, 2015

I have 4 fields in a table that when combined must be unique.I know you can setup multiple fields as a combined key, but I don't really need these to be the key (I will auto number a unique key). I just need to make sure the same combination of codes is not entered twice.Do I set this up as multiple key fields anyway?

View 1 Replies View Related

Forms :: Subform With A Multi-value Field

Jul 1, 2013

Every time I mentioned multi-value fields I get the same input, don't use them. So I am trying to replace this field with a junction table. This will have multiple records for each record in the original subform. The only problem is that the original subform is set to continuous view and now I get the error that "you can't view a form as a continuous form if it contains a subform".

View 4 Replies View Related

Queries :: Union (all) Does Not Like Multi-Value Field?

May 14, 2013

I have got a db and that has 10+ ref tables, and i need to show everything from those tables in one, and these tables includes Attachment field. I have tried union but did not work.

How can i achieve this?

View 4 Replies View Related

Validation Rule In Multi Value Field

Oct 14, 2014

I created a field in access 2010 called OptionalSubjects . It is a multi value field where a user can select multiple values from the combo box, the selection are ID from a query. Now i want to limit the user to only two selection from the multiple values available and not less than two. So the field is either NULL or two selection only. How can I achieve this in validation rule or vba.

View 3 Replies View Related

Multi-Value Field Does Not Submit Selection On OK

Sep 2, 2014

I know many are opposed to multi-valued fields, but in this case it works out nicely for my purposes.. I pick a couple things from a table to put into a field in a separate table via multi-value lookup, and when I hit ok, nothing happens. Literally. Tried the enter button, tried a mess of different keyboard mashing, and nothing. URL....

Row Source:
SELECT [Cage Codes].[CageCode], [Cage Codes].[Company], [Cage Codes].[Division] FROM [Cage Codes] ORDER BY [CageCode];

View 4 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved