Making One Field Or Another Mandatory To Fill

Nov 4, 2011

I have a form where I would like one of two fields mandatory to fill.I have an encryption password field and a pen drive password field. I would it so when the user tries to close the form, one of these two fields has to be filled in.

View Replies


ADVERTISEMENT

Making Form Fill Whole Screen

Jan 27, 2005

I am working on a project at school and need the form to fill the whole screen with no task bars has anyone got any quiries plz

View 1 Replies View Related

Mandatory Field

Apr 3, 2006

Hi

I have a form where data is entered and outcomes are entered. Any ideas how i can make the outcome field mandatory before someone moves on to the next record?

Thanks

Ben

View 4 Replies View Related

Mandatory Field

May 4, 2006

I have Form where we have 4 text boxes and out of which atleast one should be checked before closing the form, if not selected user should get the prompt to do so via message box and once selected at least one box form should be able to be saved, they can select multiple text box values but none should be blan or also no body should be able to skip by pressing space bar either !

Can someone post the coding solution please.

View 1 Replies View Related

Modules & VBA :: Mandatory Data Entry In Field Before Moving To Another Field

Aug 22, 2014

I have a form that users will use to add new records (customers).

There is a field named VAT_Registration_no

First of all i want some code to check for duplicates in that field only,before entering the next field.If the record exists i want to show a msgbox and set focus to the vat_registration_no field. Also I want the same thing to happen if the vat_registration_no field is empty.here is what i have tried:

Private Sub VAT_registration_no_AfterUpdate()
Dim btest As Boolean
If VAT_registration_no = "" Or IsNull(Me.VAT_registration_no) Then
MsgBox "Please enter a Vat Registration No.", vbOKOnly, "error"
Me.VAT_registration_no.SetFocus
Else
btest = True
End If
End Sub

and to all other fields:

Private Sub textfield_Enter()
If Not btest Then
Me.textfield.SetFocus
End If
End Sub

If I just press enter to go straight to the second field I dont get a msg. If I write something and delete it and press enter i get the msg but when I press ok the cursor goes to the next field. I want it to go to the vat_registration_no field again. And I also want this to happen even if dont write something and then delete it.

View 3 Replies View Related

Mandatory Entry In Field

Dec 15, 2006

hello,

I would like to force entry to a txtbox via code.
the txt is named txtssn and would like that if data is not entered a message will advice users to complete the entry and the mouse cursor should go back to that txtssn.

Is this possible? Thanks.

View 2 Replies View Related

Forms :: Mandatory Entry Message If Field Blank

May 11, 2014

How to have a message appear if the "Symbol_Stock" field is blank.

View 14 Replies View Related

Forms :: Can A Field Auto-fill From Previous Entry In Separate Field

Mar 21, 2013

I've just returned to work after kids and started managing a large Access database related to health, back-tracking over many years.

Currently in filling a form we physically enter:
Apples 2.2
red apple 2.4
red apple cut 2.45
Oranges 5.6
Cucumbers 8.5

Is it possible to get field 2 to automatically fill with a number code due to the text typed in field 1?

FWIW, I'm confident at more basic Access e.g making follow on default value = Dlast("field""table") type stuff but the more complex stuff I haven't touched since Uni over a decade ago and you will need to be gentle while I blow away the cobwebs

View 3 Replies View Related

Making Join Between Numeric Field And Text Field

Dec 23, 2006

I would like to make a join between two field in 2 different tables:

1.) Table with number field for Purchase Order number
2.) Table with text field for customers PO ref (where normally above PO number is entered)

When I link the both I get an error/warning message that the "types in the expression don't match"

Can anyone help me to overcome this problem ??

Thanks

View 3 Replies View Related

Tables :: Automatically Fill Field Based On Keywords In Another Field

Dec 3, 2013

I'm trying to complete a database.

It is to manage details of pupils with additional support needs, and plan for the extra arrangements the school will provide for assessments.

It has 2 Tables

tbl-PupilDetails
-ScottishCandidateNumber primary key (Unique number which identifies pupils to the exams board)
-Forename
-Surname
-DOB
-YearGroup
-Class
-NatureOfNeed (memo)
-EvidenceOfNeed (memo)

tbl-SubjectLevelArrangement
-ID Primary key, Autonumber
-Pupil foreign key to tblPupilDetails
-Subject
-Faculty
-Level
-Arrangement

I currently use forms for adding new pupils, and updating pupil subjects/arrangements/levels.

I also have forms to search for specific pupils, and to create lists for faculty heads showing which pupils are taking subjects within their faculty and the arrangements we expect to provide.

I use the forms to run queries, which can then output to reports for printing.

Where I am currently having an issue is the faculty field in the tbl-SubjectLevelArrangements. (If I didn't have to report to faculty heads I would just leave it out, but management will insist.)

Currently I have a form with dropdowns for adding subject, faculty, level and arrangement manually. This is acceptable for the subject, level and arrangement because they are completely interchangeable and dynamic throughout the academic year as pupils may drop down a level, or change the type of arrangement they require.

However as faculties are inextricably linked to subjects, I want to remove the possibility of human error. i.e. when a user (me) chooses either geography, history, or RE, then the faculty will always be Humanities, likewise if the user chooses French, German, or Spanish, then the faculty can only be Modern Languages etc.

I'm convinced there must be a very simple way to ensure that the faculty field prefills based on the limited keywords available in the subject field, but I just cannot figure it out.

View 6 Replies View Related

General :: 2 Field Look Up To Auto Fill Another Field On Form

Jan 2, 2013

Is it possible to look up 2 field to auto fill another field on my form?

Field 1 is "RiskLetter" this is autofill with "Risk" is user input.

I need to lookup RiskLetter and Risk and autofill from "Number" field. This to stop incorrect data being inputted.

So I need to look at the "Risk" & "RiskLetter" to come up with a "Number"

Would it be possible to use a Dlookup to look at RiskLetter and Risk to give me the score.

View 14 Replies View Related

Forms :: Data From One Field To Fill In Field In Subform

Nov 26, 2013

I am doing this all as a bound form

My main form got a field named 'PersonID'.

My subform also got a field called 'PersonID'

The subform 'PersonID' populates however the mainform 'PersonID' does not.

I just need to write code, or maybe do something that will copy the number from subform and paste it in the mainform field, maybe at the click of my save button.

View 8 Replies View Related

Making A Field Required Based On Value Of Another Field

Jun 18, 2015

I am trying to do something that I would think is very simple but I'm having a hard time with it. I have a form that consists of questions that the user is needed to answer. It displays the question, a combobox where the User can select 'Yes' or 'No', and a textbox where the user can input their comments. What I would like to do it the following: if the user selects 'Yes' as an answer, I want the corresponding comments box to be required.

View 10 Replies View Related

Two Problems With Mandatory Fields In Forms

Jun 14, 2005

Hi,

I am experiencing a few problems with mandatory fields in my forms. I use different forms which all base on the same table - therefore I can not use the "Required"-flag in the table definitions.

What I managed to do by now:
I put this statement into the OnExit-Event:
=IIf([FMNO] Is Null,MsgBox("Please enter the FMNO",48,"Error Message"),"")

This provides me with an errormessage in case the field is null.
When I exit the field, I receive the errormessage but the cursor moves to the next field. How can I make sure that the cursor stays in the field where the error occurs?


My next problem:
When I try to use this syntax on a text-field (e.g. "NAME") it doesn't work.

Has anybody any suggestions?

Your help is very much appreciated, I'm getting more and more desperate on this issue.

View 2 Replies View Related

Forms :: Conditional Mandatory Fields

Mar 20, 2013

Basically I have a form which records primary and secondary reasons for people writing off money, and in the secondary reasons I have an option for 'other', in case any of the other options aren't applicable. There is also a comments section on the form which is optional.

My issue is, I want the comments section to become mandatory if the 'other' option has been selected. I don't want it mandatory all the time, and I don't want it disabled if 'other' isn't selected, but I need to force people to write at least something in there if they have selected other.

I tried variations on code I found from other places but was unable to get this to function, and I am not sure if this can be done with validation or something like that.

View 14 Replies View Related

Lookup 2 Field To Auto Fill Another Field?

Dec 30, 2012

Is it possible to look up 2 field to auto fill another field?

Field 1 is "Exposure" this autofill with "Probability" is user input.

I need to lookup Exposure and Probability and autofill a score in to "Risk Rating". This to stop incorrect data being inputted.

I have a table with all the results combination in it.

Would it be possible to use a Dlookup to look at Exposure and Probability to give me the score

I tried a Combox with autofill. But the power to be would like it done without user input.

View 11 Replies View Related

Forms :: Creating Mandatory Fields In A Database?

Jun 18, 2013

I have a table, which when i first set it up i decided that a couple of the fields had to be mandatory.

So, i set the "Required" property of the field to "Yes" (at table level - which is probably poor practice?)

I now have a form that allows a user at the front end to enter items in the table.

If they complete all the fields on the form i have used macro builder to save the record, present a nice message and move to a New Record. (3 elements in all)

However, if they try to save the record having not completed the "Required" fields then they get an error message instructing them the field is required, but then the macro crashes.

So what's the best way to approach Mandatory fields? Is it best to leave the "Required" property at table level set to No and then have something at form level which checks they have entered a value in the field? (i'm guessing this is probably the correct approach)

I tried removing the table level condition from the [Field] and adding this as the first argument of the macro builder which saves my record:

Code:

IF [Field] = "" Then
MessageBox "You Must Complete Mandatory Fields"
Stop Macro
End If

But my macro still completes and saves the record...

View 6 Replies View Related

Forms :: Highlight Mandatory Controls On A Form Tab

May 15, 2013

I am trying to provide a visual highlight for users of a multi tabbed form. I do a check as users go from tab and tab and i.e. on exit event and I would like to highlight all mandatory fields that have been left incomplete.

I did a test with one control and it worked as expected with the after update event of the specific control.

I then altered the code to add another control, but it does not work as expected. It only highlights one control and not the other. I just recently started using vba, I adapt the code to fit multiple controls and make it work as expected.

Private Sub Ctl2_frm_tab1_Exit(Cancel As Integer)
If (Len(Form_2.cmb_arName& "") = 0 Or IsNull(Form_2.cmb_arName)) Or _
(Len(Form_2.cmb_val & "") = 0 Or IsNull(Form_2.cmb_val)) Then
Cancel = True
MsgBox "Please complete the highlighted control", vbCritical + vbOKOnly

[Code] .....

View 3 Replies View Related

Yes/No Field Making Me Crazy

Nov 14, 2007

I posted this in the wrong thread yesterday

I just started learning Access and I have created a database with 53 records, 3 tables and 1 Split form. I creared a new yes/no field and I am attempting to display "Completed" in green for yes and "Not Completed" in red for no. I used the correct code in the format field:

"Not Completed "[Red];" Completed "[Green]

This worked for different field before I created the split form but now I cannot get the new field to display anything but check boxes regardless of what code I use. It won't even let me use the default yes/no, true/false or on/off options.

I've been studying this for about 2 weeks and I've figured out quite a bit but this one thing is really iritating me....

Help
Any comments would be appreciated
John

View 3 Replies View Related

Fill A Field With The Same Value

Apr 1, 2005

Hello,

I'm new to access and i need help in filling a certain field with the same value.
In fact i have data representing one quarter of data and i need to add a column called "Quarter" in which i paste the same value: the current quarter : "Q4".

How can i do that?
I think this is a real simple issue.

Thanks in advance for your help.
Regards
sam

View 1 Replies View Related

Making Text Field Larger

May 1, 2006

I have a field that is in text format that is used as a discussion box. This limits the user to 250 characters because of Access limitations. I have tried the memo format but that will not allow me to query off of that field. How can I have this discussion field with unlimited text capability and also be able to query off of it? Any help is greatly appreciated. Thanks!

View 5 Replies View Related

Making Data In A Field A Certain Lenght

Jun 10, 2007

I have a number in a column that can be up to 10 characters long. where it is not the full 10 characters i want to be able to insert zeros at the front.
IE
12345678
to
0012345678

I would like to be able to do this in an append query. Is there a function that allows me to do this?

Cheers

View 4 Replies View Related

Field Focus And Making MDE Files

Mar 8, 2005

When I insert this code:

Private Sub Phone_Click()
Me.Phone.SelStart = 0
End Sub

Access will no longer make an MDE file. I was trying to make it so when the Phone field was clicked in the focus would be at the beginning of the field.

If I remove these lines, an MDE is possible again. I have tried it at the beginning and at the end. Any thoughts?

View 7 Replies View Related

Making Label With More Than One Field Per Line

Dec 16, 2012

I previously used an older Access version under XP, but I switched to Windows 7 (64-bit) and Access V10. In general, most everything appears to work as expected, but I can't be sure because I have not gotten past the "previously simple" task of making a simple label !!!!

When I construct a LABEL layout, if I use ONLY one field per line, everything appears to work OK.When I put MORE than one field per line, the additional lines are "accepted", but when I click "finished" to preview the finished labels, I get an #error on every line that has more than one field, but the lines with only one field print out as expected.If I then go into the DESIGN mode, each line with more than one field displays:

=Trim([field-x] & " " & [field-z]), where the " " is related to the space I place between field-x and field-z.

During this process I also get a box with the message "Enter Parameter Value", and below that is the text, "Trim", with a box in which to insert some kind of "parameter". I have absolutely no clew what to put into the "box", and no where in the 812 page, "The Missing Manual" is the question answered.I have wasted approximately five hours trying to solve this issue, including google searches for potential answers, some of which seem reasonable, but do not work when implemented. At this point I am ready to trash ACCESS and move on to some other process.

View 5 Replies View Related

Auto Fill Yes/No Field

Mar 7, 2006

hi. this might be simple for others but i'm new with access. how can i automatically fill a YES/NO field referring to a Text field. which means, if the field is EMPTY, it will automatically say "No or False" in the Yes/No field, or vice versa.

thank you people of great minds and kind heart. more power to you all.

View 6 Replies View Related

Automatically Fill In Field

Aug 12, 2005

Hi everybody,

I have a table that has 4 columns as shown below:

(*It really isn't code, I just couldn't figure out how else to keep the columns in place!)



-------------------------------------------------------------------
Store Name Invoice Number Customer Name Customer Address
Store1 1 Bob PO Box 55
Store1 2 Joe PO Box 789
Store2 3 Chris PO Box 1254
-------------------------------------------------------------------
On my input form, for entering a new invoice, when you select the customer name, I want the form to automatically fill in the correct address in the "Customer Address" field.

I think there has to be a way to do this because there is only ever going to be one address for every customer. And the same customers will be comming back very often.

Does anyone have any ideas?

-Chris

View 14 Replies View Related







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