From: DJM2290 on
How do I get a control to update in a form without closing the form and
re-opening it? It used to work fine before I converted the DB to 2007.
Basically, a user keys in an item number, and I would like the item
description control to populate after they move out of the item control
field. The source for the form is a select query. Any help would be
appreciated.
From: Dirk Goldgar on
"DJM2290" <DJM2290(a)discussions.microsoft.com> wrote in message
news:C3EE101D-A3C1-4E8F-8D9D-2D357A415638(a)microsoft.com...
> How do I get a control to update in a form without closing the form and
> re-opening it? It used to work fine before I converted the DB to 2007.
> Basically, a user keys in an item number, and I would like the item
> description control to populate after they move out of the item control
> field. The source for the form is a select query. Any help would be
> appreciated.


The only thing that has change in this regard between Access 2003 (or
earlier) and Access 2007 is that VBA code doesn't run in Access 2007 unless
you explicitly enable it or put the database in a trusted location (as
established in the Trust Center settings).

Could that be the problem? Is the description being set by VBA code?

--
Dirk Goldgar, MS Access MVP
Access tips: www.datagnostics.com/tips.html

(please reply to the newsgroup)

From: DJM2290 on
It is not set by VBA code...the control source for the "description" field is
just "SKU Desc" which is a field in the source query.

"Dirk Goldgar" wrote:

> "DJM2290" <DJM2290(a)discussions.microsoft.com> wrote in message
> news:C3EE101D-A3C1-4E8F-8D9D-2D357A415638(a)microsoft.com...
> > How do I get a control to update in a form without closing the form and
> > re-opening it? It used to work fine before I converted the DB to 2007.
> > Basically, a user keys in an item number, and I would like the item
> > description control to populate after they move out of the item control
> > field. The source for the form is a select query. Any help would be
> > appreciated.
>
>
> The only thing that has change in this regard between Access 2003 (or
> earlier) and Access 2007 is that VBA code doesn't run in Access 2007 unless
> you explicitly enable it or put the database in a trusted location (as
> established in the Trust Center settings).
>
> Could that be the problem? Is the description being set by VBA code?
>
> --
> Dirk Goldgar, MS Access MVP
> Access tips: www.datagnostics.com/tips.html
>
> (please reply to the newsgroup)
>
> .
>
From: Dirk Goldgar on
"DJM2290" <DJM2290(a)discussions.microsoft.com> wrote in message
news:19BCAB12-3F40-4245-9AB5-FE3CE1AA12EA(a)microsoft.com...
> It is not set by VBA code...the control source for the "description" field
> is
> just "SKU Desc" which is a field in the source query.

Please post the SQL of the form's recordsource, and the name, type, and
Control Source properties of each relevant control. If a control is a combo
box, please also post its Row Source, Bound Column, and Column Count
properties.

--
Dirk Goldgar, MS Access MVP
Access tips: www.datagnostics.com/tips.html

(please reply to the newsgroup)

From: DJM2290 on
Below is the SQL from the source...the relevant controls are as follows..

Name: SKU #
Type: Text Box
Countrol Source: SKU #

Name: SKU Description
Type: Text Box
Countrol Source: SKU Desc

There is a combo box, but I don't think it is relevant to the problem.
Name: Ad Date
Control Source: Ad Date
Row Source: Ad Dates
Bound Column: 1
Column Count :1

SELECT [Ad Detail].[Ad Date], [Ad Detail].Division,
INTREPIDD_SKUMSTR.SRS_DEPT AS Dept, INTREPIDD_SKUMSTR.SRS_CLASS AS Class, [Ad
Detail].[SKU #], [Ad Detail].[Placeholder Dept], INTREPIDD_SKUMSTR.SM_DESC AS
[SKU Desc], [Ad Detail].[Placeholder Description], [Ad Detail].[Placeholder
Cost (per unit)], [Ad Detail].[Include for 12 Week Meeting (type Y if yes)],
INTREPIDD_SKUMSTR.SM_LAST_COST AS [Last Cost], [Ad Detail].Status, [Ad
Detail].[Current Retail], [Ad Detail].[Event Retail], [Ad Detail].[Comp
Retail], [Ad Detail].[# Stores], [Ad Detail].[Baseline Units], [Ad
Detail].[Unit Sales Forecast], [Ad Detail]![Event Retail]*[Ad Detail]![Unit
Sales Forecast] AS [Sales Forecast $], [Ad Detail].[Ad Prep], [Ad
Detail]![Unit Sales Forecast]/[Ad Detail]![Ad Prep] AS [Ad Sell Thru], [Ad
Detail].[Basis for Projection], [Ad Detail].Comments, ([Ad Detail]![Current
Retail]-[Ad Detail]![Event Retail])*[Ad Detail]![Unit Sales Forecast] AS
[Mkdn Forecast $]
FROM ([Ad Detail] LEFT JOIN INTREPIDD_SKUMSTR ON [Ad Detail].[SKU #] =
INTREPIDD_SKUMSTR.SRS_SKU) LEFT JOIN INTREPIDD_DEPTTBL ON
INTREPIDD_SKUMSTR.SRS_DEPT = INTREPIDD_DEPTTBL.SRS_DEPT
WHERE ((([Ad Detail].[Ad Date])=[Which Ad Date? Format must be mmddyy]) AND
(([Ad Detail].Division)=[What Division?]))
ORDER BY [Ad Detail].[Ad Date], [Ad Detail].Division,
INTREPIDD_SKUMSTR.SRS_DEPT, INTREPIDD_SKUMSTR.SRS_CLASS, [Ad Detail].[SKU #];

"Dirk Goldgar" wrote:

> "DJM2290" <DJM2290(a)discussions.microsoft.com> wrote in message
> news:19BCAB12-3F40-4245-9AB5-FE3CE1AA12EA(a)microsoft.com...
> > It is not set by VBA code...the control source for the "description" field
> > is
> > just "SKU Desc" which is a field in the source query.
>
> Please post the SQL of the form's recordsource, and the name, type, and
> Control Source properties of each relevant control. If a control is a combo
> box, please also post its Row Source, Bound Column, and Column Count
> properties.
>
> --
> Dirk Goldgar, MS Access MVP
> Access tips: www.datagnostics.com/tips.html
>
> (please reply to the newsgroup)
>