one more bug in a2K7: form order by

A

Alain Bourgeois

I would like to report one (more) bug in access 2007.
If you have a continuous read-only form based on a simple query. Form's
OrderBy is empty.

On this form I have a button. In the onClick Event, in a macro, I have
[Forms]![formname].[OrderBy]="[queryname]![FieldName]"

In all access versions, clicking the button sorts the records in the form on
FieldName.
In access 2007, setting the orderBy property is ignored if no OrderBy value
is present in the form.

To correct this, I had to set an orderBy property in the form then save it.
It works afterwards.

Will this problem be corrected in service pack 2? (otherwise I will have to
check ~150 forms where this problem could happen).

Regards,
Alain
 
T

Tom van Stiphout

On Sun, 15 Mar 2009 16:58:56 +0100, "Alain Bourgeois"

After setting the OrderBy property, you also need to set OrderByOn
property to True.

-Tom.
Microsoft Access MVP
 
A

Alain Bourgeois

The question is:
Will this problem be corrected in service pack 2?

Tom van Stiphout said:
On Sun, 15 Mar 2009 16:58:56 +0100, "Alain Bourgeois"

After setting the OrderBy property, you also need to set OrderByOn
property to True.

-Tom.
Microsoft Access MVP

I would like to report one (more) bug in access 2007.
If you have a continuous read-only form based on a simple query. Form's
OrderBy is empty.

On this form I have a button. In the onClick Event, in a macro, I have
[Forms]![formname].[OrderBy]="[queryname]![FieldName]"

In all access versions, clicking the button sorts the records in the form
on
FieldName.
In access 2007, setting the orderBy property is ignored if no OrderBy
value
is present in the form.

To correct this, I had to set an orderBy property in the form then save
it.
It works afterwards.

Will this problem be corrected in service pack 2? (otherwise I will have
to
check ~150 forms where this problem could happen).

Regards,
Alain
 
T

Tom van Stiphout

On Sun, 15 Mar 2009 17:14:20 +0100, "Alain Bourgeois"

AFAIK the behavior has not changed. If you're currently not setting
OrderByOn then it was already set correctly or you got lucky. See
topic "How to: Change the Filter or Sort Order of a Form or Report" in
the A2007 help file. You may also want to search the KB at
search.microsoft.com for "Access OrderByOn".

-Tom.
Microsoft Access MVP

The question is:
Will this problem be corrected in service pack 2?

Tom van Stiphout said:
On Sun, 15 Mar 2009 16:58:56 +0100, "Alain Bourgeois"

After setting the OrderBy property, you also need to set OrderByOn
property to True.

-Tom.
Microsoft Access MVP

I would like to report one (more) bug in access 2007.
If you have a continuous read-only form based on a simple query. Form's
OrderBy is empty.

On this form I have a button. In the onClick Event, in a macro, I have
[Forms]![formname].[OrderBy]="[queryname]![FieldName]"

In all access versions, clicking the button sorts the records in the form
on
FieldName.
In access 2007, setting the orderBy property is ignored if no OrderBy
value
is present in the form.

To correct this, I had to set an orderBy property in the form then save
it.
It works afterwards.

Will this problem be corrected in service pack 2? (otherwise I will have
to
check ~150 forms where this problem could happen).

Regards,
Alain
 
H

huangda ½ú½­ÐË´ï»úе

Alain Bourgeois said:
I would like to report one (more) bug in access 2007.
If you have a continuous read-only form based on a simple query. Form's
OrderBy is empty.

On this form I have a button. In the onClick Event, in a macro, I have
[Forms]![formname].[OrderBy]="[queryname]![FieldName]"

In all access versions, clicking the button sorts the records in the form
on FieldName.
In access 2007, setting the orderBy property is ignored if no OrderBy
value is present in the form.

To correct this, I had to set an orderBy property in the form then save
it. It works afterwards.

Will this problem be corrected in service pack 2? (otherwise I will have
to check ~150 forms where this problem could happen).

Regards,
Alain
 
D

david

In Access 97, setting the OrderBy value in code does
not set the OrderByOn property: you have to use code for
that too, or right click on the form and select "Apply Filter"

(david)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top