A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » General Discussion
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

having one field display when another field changes



 
 
Thread Tools Display Modes
  #1  
Old June 2nd, 2010, 04:19 AM posted to microsoft.public.access
Norm
external usenet poster
 
Posts: 149
Default having one field display when another field changes

I have a field CHSTAT that updates in the original database I want a new
field that will display something different as the CHSTAT updates and changes
ie. CHSTAT = "10" new field = "Printed"......CHSTAT = 20 new field=
"Located"

Cheers!!
  #2  
Old June 2nd, 2010, 01:59 PM posted to microsoft.public.access
John Spencer
external usenet poster
 
Posts: 7,815
Default having one field display when another field changes

In tables and fields you should have a table that has a field that has the
CHSTAT values and a field that has the equivalent text values.

Then you join that table to the current table in a query on the CHSTAT values.

If you want to do this on a form, you could use a combobox to select the
values. The source of the combobox would be your current CHTSTAT field. The
combobox's row source would be a query on the new table. The combobox could
display the numeric value and then your form could have a separate text
control to display the other information. The source for the text control
would be something like
=[Name Of Combobox].Column(1)


John Spencer
Access MVP 2002-2005, 2007-2010
The Hilltop Institute
University of Maryland Baltimore County

Norm wrote:
I have a field CHSTAT that updates in the original database I want a new
field that will display something different as the CHSTAT updates and changes
ie. CHSTAT = "10" new field = "Printed"......CHSTAT = 20 new field=
"Located"

Cheers!!

  #3  
Old June 2nd, 2010, 02:24 PM posted to microsoft.public.access
Al Campagna[_2_]
external usenet poster
 
Posts: 1,462
Default having one field display when another field changes

Norm,
You dpn't say how many different Chstat values there may be, but if more
than 5 or so, it would be a candidate for a combo box, (ex. cboChstat)
based against a table of preset values. Ex. tblChstat...
Chstat Desc
10 Printed
20 Located... etc
Bind cboChstat to your Chstat field of your table, and use the combo to
select a Chstat value. An unbound text control on the form, with a
ControlSource
of...
=cboChstat.Colunm(1)
will always display the contents of the 2nd column in cboChstat. (combo
columns are numbered left to right 0, 1, 2, 3, etc.)
No need to save Desc... it can always be re-related to from the Chstat
value
in any subsequent query, form, or report.
--
hth
Al Campagna
Microsoft Access MVP 2007-2009
http://home.comcast.net/~cccsolutions/index.html

"Find a job that you love... and you'll never work a day in your life."

"Norm" wrote in message
...
I have a field CHSTAT that updates in the original database I want a new
field that will display something different as the CHSTAT updates and
changes
ie. CHSTAT = "10" new field = "Printed"......CHSTAT = 20 new field=
"Located"

Cheers!!



  #4  
Old June 2nd, 2010, 03:24 PM posted to microsoft.public.access
Norm
external usenet poster
 
Posts: 149
Default having one field display when another field changes

Thank you for your replies...what I forgot to mention is that the data comes
from a table that is linked to an AS400 system and not entered on a form...I
was hoping it could be along the lines of a conditional format in Excel

"Al Campagna" wrote:

Norm,
You dpn't say how many different Chstat values there may be, but if more
than 5 or so, it would be a candidate for a combo box, (ex. cboChstat)
based against a table of preset values. Ex. tblChstat...
Chstat Desc
10 Printed
20 Located... etc
Bind cboChstat to your Chstat field of your table, and use the combo to
select a Chstat value. An unbound text control on the form, with a
ControlSource
of...
=cboChstat.Colunm(1)
will always display the contents of the 2nd column in cboChstat. (combo
columns are numbered left to right 0, 1, 2, 3, etc.)
No need to save Desc... it can always be re-related to from the Chstat
value
in any subsequent query, form, or report.
--
hth
Al Campagna
Microsoft Access MVP 2007-2009
http://home.comcast.net/~cccsolutions/index.html

"Find a job that you love... and you'll never work a day in your life."

"Norm" wrote in message
...
I have a field CHSTAT that updates in the original database I want a new
field that will display something different as the CHSTAT updates and
changes
ie. CHSTAT = "10" new field = "Printed"......CHSTAT = 20 new field=
"Located"

Cheers!!



.

  #5  
Old June 2nd, 2010, 06:17 PM posted to microsoft.public.access
John Spencer
external usenet poster
 
Posts: 7,815
Default having one field display when another field changes

Well you could build a complex calculated field in a query.

Switch(ChStat=10,"Printed",ChStat=20,"Located",ChS tat=30,"Destroyed")


John Spencer
Access MVP 2002-2005, 2007-2010
The Hilltop Institute
University of Maryland Baltimore County

Norm wrote:
Thank you for your replies...what I forgot to mention is that the data comes
from a table that is linked to an AS400 system and not entered on a form...I
was hoping it could be along the lines of a conditional format in Excel

"Al Campagna" wrote:

Norm,
You dpn't say how many different Chstat values there may be, but if more
than 5 or so, it would be a candidate for a combo box, (ex. cboChstat)
based against a table of preset values. Ex. tblChstat...
Chstat Desc
10 Printed
20 Located... etc
Bind cboChstat to your Chstat field of your table, and use the combo to
select a Chstat value. An unbound text control on the form, with a
ControlSource
of...
=cboChstat.Colunm(1)
will always display the contents of the 2nd column in cboChstat. (combo
columns are numbered left to right 0, 1, 2, 3, etc.)
No need to save Desc... it can always be re-related to from the Chstat
value
in any subsequent query, form, or report.
--
hth
Al Campagna
Microsoft Access MVP 2007-2009
http://home.comcast.net/~cccsolutions/index.html

"Find a job that you love... and you'll never work a day in your life."

"Norm" wrote in message
...
I have a field CHSTAT that updates in the original database I want a new
field that will display something different as the CHSTAT updates and
changes
ie. CHSTAT = "10" new field = "Printed"......CHSTAT = 20 new field=
"Located"

Cheers!!


.

 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 03:21 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.