Any Ideas Will Help (1 Viewer)

Lex

Registered User.
Local time
Today, 15:56
Joined
Jan 7, 2003
Messages
11
I am not sure if this is even possible. I have a table in my database that contains specifications numbers i.e. the length of product "A" is 150 inches (Length Field) and the width is 8" (Width field), There are about 100 different products total.

Well my problem I have run into is that I want to enter in the actual readings in a new table (in form view) but if I enter a value say for length that is not within a 1/4" from the standard to require me to enter a comment in another field.

I have been racking my brain for about two months, trying to figure a way around this with no luck.

Maybe someone has a better idea.
 

WitchCraft

Registered User.
Local time
Today, 21:56
Joined
Jan 6, 2003
Messages
11
Your question is unclear.

Well my problem I have run into is that I want to enter in the actual readings in a new table (in form view) but if I enter a value say for length that is not within a 1/4" from the standard to require me to enter a comment in another field.

how about a little math?

something like

item :[______! !] (combo colum 0 and 1 are hidden, 1 is size, 2 is item name)

size :[________] comment:[________] (text fields)

'with comment invisible until you enter a size.

'declare public var
dim booleanOversize


'on the afterupdate of the size text do :


if cint(txtSize.value) > combo.column(1, combo.listindex)+0.25 or cint(txtSize.value) < combo.column(1, combo.listindex)-0.25 then
txtComment.visible=true
booleanOverSize=true
else
txtComment.visible=false
endif


'on the submit event check if it is filled

if booleanOversize then
if isnull(txtComment) then
msgbox "error"
exitsub
else
if txtComment=""" then
msgbox "error"
exitsub
endif
endif


voila
 

Lex

Registered User.
Local time
Today, 15:56
Joined
Jan 7, 2003
Messages
11
To Help Clarify I have Two tables and a form


Table A "specs"

Fields in table A

Product Code - Product Name - Product Finish - Length - Width - (ect total of 36 fields) and (110 different records)

Table B "Data Entry"

Fields in table B

Name - Date - Product Name - Product Finish - Length - Width - (ect total of 42 fields) and (3 different records "I said it was a new table")

Form A "Data Entry" is the same as Table B just in form view

as i enter data in to the form and i come to a number field i wish to be able to compare the value I enter on the field to something like...

=between ([length].[table A] - 0.25) and ([length].[table a] + 0.25)

if not then requiered to enter comment in field 40


I think the problem is when i enter a value in the field it doesnt know which one of the records it applies too.

But I will try the hidden colunm trick Witchcraft, and thank you
I hope i clarified myself
 

Users who are viewing this thread

Top Bottom