如何添加新的记录子窗体 [英] How to add new record to subform

查看:1017
本文介绍了如何添加新的记录子窗体的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我最近买了在帮助时,从组合中选择的价值,强调的是记录访问子窗体数据表,现在我试图做一个相关的任务。

I recently got help on When select value from combo, highlight that record in Access subform datasheet and now I'm trying to do a related task.

我怎样才能让子窗体给我从一个按钮在主窗体上的数据输入一个新行?

How can I make the subform give me a new row for data entry from a button on the main form?

试图找到这里,没有运气的方法: HTTP:/ /www.access-programmers.co.uk/forums/showthread.php?t=26537

Tried the method found here with no luck: http://www.access-programmers.co.uk/forums/showthread.php?t=26537

编辑:不知道它的问题,但我的表子窗体应该是更新链接表到SQL Server。

Not sure if it matters, but the table my subform is supposed to update is a linked table to SQL Server.

推荐答案

请首先确认您的记录源是可更新的通过打开表或查询中,你的子窗体记录源的基础,并确保您可以编辑和添加新记录。如果没有,那么它可能是你的SQL Server链接表丢失了一个独特的indentifier。要创建一个,只需删除链接表,并重新连接。重新链接后的MS Access应该提示您指定一个唯一索引(可能需要多个领域,使之真正独一无二的)。然后重试。

Please first make sure your recordsource is updateable by opening the table or query in which your subform recordsource is based, and ensure that you can edit and add new records. If not, then it's possible that your SQL Server linked table is missing a unique indentifier. To create one, simply delete the linked table, and relink it. Upon relinking, MS Access should prompt you to specify a unique index (may take more than one field to make it truly unique). Then try again.

这篇关于如何添加新的记录子窗体的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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