当我按添加新记录时无法添加数据到表单? [英] Can't add data to form when I press add new record?

查看:51
本文介绍了当我按添加新记录时无法添加数据到表单?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述




我已根据自己的特定查询创建了3种表格(声明,参数和证据),这些表格具有一对一的关系。在每个查询中,我可以编辑数据并在那里添加新记录没问题。


我的一个表格(索赔表)允许我添加新记录并在该记录中写入。但是,当我添加新记录时,参数和证据表格不允许我输入。


我想知道这是否是我在索赔中所做的链接表格,以发送与该声明相关的论据。同样的关系与论证 - 证据有关。我使用的代码如下(从使用关系的链接到表单向导):

Hi,

I''ve created 3 forms (claims, arguments and evidence) based on their own specific query which have one-to-one relationships. Within each query I can edit data and add new record no problem there.

One of my forms (the claim form) allows me to add a new record and write within that record. However, the argument and evidence form do not allow me to type when I add a new record.

I am wondering whether it''s the link I''ve made within the claim form to send you to the arguments related to that claim. And the same relationship is with the argument-evidence. The code I''ve used is below (from the link to form wizard using relationship):

展开 | 选择 | Wrap | 行号

推荐答案

LeighW:

我想知道这是否是我在索赔表,以便向您发送与该索赔相关的论据。
LeighW:
I am wondering whether it''s the link I''ve made within the claim form to send you to the arguments related to that claim.



帮助我们获取技术信息。详细说明你所指的是一般性的。否则问题,当被解释时,归结为:

我的表格有一两个问题。它们相似但不完全相同。我的问题是什么?


对于可以(有时)足够的愚蠢的简单问题,但你正在考虑你想要什么,并设计以满足需要。通常,您的问题可能需要支持从中工作的技术信息。这就是这样的事情。

To help we need technical information. Details of what it is that you''re referring to in general terms. Otherwise the question, when paraphrased, comes down to :
I have a problem or two with my forms. They are similar but not exactly the same. What''s my problem?

For stupidly easy questions that can (sometimes) suffice, but you''re thinking about what you want and designing to suit needs. Typically your questions are likely to need supporting technical information from which to work. It''s how such things work.


好的我会尝试让它更具技术性。


ClaimNo是在第一个查询和第二个查询中链接两个表的外键。通过这些查询,我创建了两个表单。在第一个表单上,我使用了命令按钮向导,选择了表单操作和表单操作。和开放表格这将打开第二个表单,我选择打开表单并查找要显示的特定数据。选择外键(ClaimNo)。这会过滤特定于该字段的数据。


代码为:

Ok I''ll try and make it more technical.

The "ClaimNo" is the foreign key which links the two tables within the first query and second query. With these queries I have created two forms. On the first form I used the command button wizard, selected "Form Operations" and "Open Form" this opens the second form and I chose "open form and find specific data to display" choosing the foreign key (ClaimNo). This filters the data specific to that that field.

The code for that is:

展开 | 选择 | Wrap | 行号


首先,采用命名约定(任何真正的)并将名称作为代码中使用的任何控件的名称始终是一个好主意。从现在起2个月,看看command20,你不知道哪个按钮是什么。名称可以是btn_OpenClaims,或cmd_OpenClaims或cmdOpenClaims。您使用哪种命名约定不太重要,但是对于您自己的使用,请使用一个!


现在您显示的2段代码只需打开一个表单并过滤任何现有记录即可匹配stLinkCriteria。使用表单创建的任何记录都不会自动链接以匹配stLinkCriteria。


我无法理解您的表单和数据是如何设置的。你在用什么领域?您声称它们是通过ArgCode链接的,但您的代码表明它们是由ClaimNo或Argument链接的。


您的应用程序的一般用途是什么?什么是主要/主要形式和表格?
First off, its always a good idea to adopt a naming convention (any really) and name as a minimum any controls you use in code. 2 months from now, looking at command20 gives you no idea which of teh buttons that is. A name could be btn_OpenClaims, or cmd_OpenClaims or cmdOpenClaims. Which naming convention you use is of lesser importance, but for your own sakes, please use one!

Now the 2 pieces of code you show simply open a form and filter any existing records to match the stLinkCriteria. Any records created with the form will NOT automatically be linked to match the stLinkCriteria.

I can''t understand how your form nor data is setup. What fields are you using? You claim they are linked through ArgCode, yet your code indiates they are linked by ClaimNo or Argument.

What is the general purpose of your application? Whats the main/primary form and table?


这篇关于当我按添加新记录时无法添加数据到表单?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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