如何在子窗体控件中对记录进行排序? [英] How to sort records in a subform control?

查看:112
本文介绍了如何在子窗体控件中对记录进行排序?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我创建了两种形式:frmBrowseNegsMainform和

frmBrowseNegsSubform。我首先在

上放置一个子窗体控件。子窗体

控件的SourceObject属性当然是frmBrowseNegsSubform。


我想执行升序或降序
$ b

子窗体控件的数据表视图中显示的7列中的任何一列上的$ b。我没有成功。


在子窗体控件中排序是否有些棘手?

I have created two forms: frmBrowseNegsMainform and
frmBrowseNegsSubform. I put a subform control on the
first of these. The SourceObject property for the subform
control is, of course, frmBrowseNegsSubform.

I would like to perform an ascending or descending sort
on any of the 7 columns shown in datasheet view in the
subform control. I''ve been unsuccessful.

Is there something tricky about sorting in subform controls?

推荐答案

使用命令按钮为列标题和每个

按钮的Click事件,将OrderByOn属性设置为True,将OrderBy属性设置为名称

下的字段按钮并重新查询表单。


注意:您也可以使用标签,因为它们有一个Click事件,但是按钮会生成

看起来它们可以被点击。


-

PC数据表

您的资源获取Access,Excel和Word应用程序的帮助
re ****** @ pcdatasheet.com
www.pcdatasheet.com

" MLH" < CR ** @ NorthState.net>在消息中写道

news:br ******************************** @ 4ax.com ...
Use command buttons for the column headings and in the Click event of each
button, set the OrderByOn property to True, the OrderBy property to the name of
the field under the button and requery the form.

Note: You can use labels also because they have a Click event but buttons make
it look like they can be clicked.

--
PC Datasheet
Your Resource For Help With Access, Excel And Word Applications
re******@pcdatasheet.com
www.pcdatasheet.com
"MLH" <CR**@NorthState.net> wrote in message
news:br********************************@4ax.com...
我创建了两种形式:frmBrowseNegsMainform和
frmBrowseNegsSubform。我在第一个上面放了一个子窗体控件。子窗体
控件的SourceObject属性当然是frmBrowseNegsSubform。

我想在数据表视图中显示的7列中的任何一列上执行升序或降序

子窗体控件中。我没有成功。

在子窗体控件中排序是否有些麻烦?
I have created two forms: frmBrowseNegsMainform and
frmBrowseNegsSubform. I put a subform control on the
first of these. The SourceObject property for the subform
control is, of course, frmBrowseNegsSubform.

I would like to perform an ascending or descending sort
on any of the 7 columns shown in datasheet view in the
subform control. I''ve been unsuccessful.

Is there something tricky about sorting in subform controls?



我忽略了提到这个问题在Access 2.0中,它支持

没有OrderBy或OrderByOn属性。请原谅。


xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx xxxxxxxxxxxxxxxxxxxx


On Sun,2004年7月25日00:11:49 GMT,PC数据表 < no **** @ nospam.spam>

写道:
I neglected to mention the problem is in Access 2.0, which supports
no OrderBy or OrderByOn properties. Please excuse.

xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx xxxxxxxxxxxxxxxxxxxx

On Sun, 25 Jul 2004 00:11:49 GMT, "PC Datasheet" <no****@nospam.spam>
wrote:
使用命令按钮作为列标题和每个,将OrderByOn属性设置为True,将OrderBy属性设置为按钮下方字段的名称,并重新查询表单。

注意:您也可以使用标签,因为它们有一个Click事件,但按钮使它看起来好像可以点击。
Use command buttons for the column headings and in the Click event of each
button, set the OrderByOn property to True, the OrderBy property to the name of
the field under the button and requery the form.

Note: You can use labels also because they have a Click event but buttons make
it look like they can be clicked.








" ; MLH" < CR ** @ NorthState.net>在消息中写道

news:7i ******************************** @ 4ax.com ...

"MLH" <CR**@NorthState.net> wrote in message
news:7i********************************@4ax.com...
我忽略了问题在Access 2.0中,它支持
没有OrderBy或OrderByOn属性。请原谅。
I neglected to mention the problem is in Access 2.0, which supports
no OrderBy or OrderByOn properties. Please excuse.




这很有趣。你原谅了!



That''s pretty funny. You''re excused!


这篇关于如何在子窗体控件中对记录进行排序?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆