Allen Browne的审计跟踪 - 更改NetworkUsername()函数 [英] Allen Browne's audit trail - change NetworkUsername() function

查看:62
本文介绍了Allen Browne的审计跟踪 - 更改NetworkUsername()函数的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



我在Access方面的知识非常有限但我已经成功地为我的部门建立了一个非常好的数据库,基于来自像这样的论坛的专家的帮助和帮助。 />

一些背景知识:这个数据库将在一个共同的计算机上使用,在团队成员之间共享。因此,我已经创建了一个登录屏幕,供用户在使用数据库之前登录。以下是我登录表单中的代码:

展开 | 选择 | Wrap | 行号

解决方案

格式正确的问题来自新用户。多么令人耳目一新。


我首先将已验证用户的名称存储在会话级变量中。最新版本的Access具有这些功能,并且它们会持续超出项目崩溃或停止的程度。


从那里开始,这是更改日志记录过程中任何引用的简单案例引用该变量而不是使用NetworkUserName()。


如果您需要更多帮助来实现这一点,请告诉我们。我现在正忙着,但下次看的时候会有更多的时间。


欢迎来到字节: - )


Hi NeoPa ,


感谢您的热烈欢迎。我已经阅读了Bytes中的几十个主题并以某种方式了解了如何最好地接近论坛:)


无论如何,你猜对了。我确实需要进一步的帮助。我不太明白你对会话级变量的意思。


我的猜测是我必须相应地从审计跟踪模块更改第4-31行;但我不知道该怎么做。


我会耐心等待你有时间回复。


谢谢!


我认为Neopa正在引用较新的临时变量。 ACC2007 / 2010中提供的集合。


此链接有一个非常基本的解释和使用示例:
功能提示:最大限度地利用Access 2007和2010中的TempVars


这里很酷的是你可以在没有函数调用的情况下从存储的查询中引用它们!


如果我要离开,Neopa会很快纠正我...


如果您还需要更多帮助我们知道。

Hi,
My knowledge in Access is very limited but I have managed to build a pretty good-wroking database for my department based on help and assistance of experts from forums like this one.

A bit of background: This database will be used on a common computer, shared amongst the team members. Hence, I''ve created a login screen for users to login before using the database. Below is the code from my login form:

Expand|Select|Wrap|Line Numbers

解决方案

A properly formatted question from a new user. How refreshing.

I''d start by storing the name of the validated user in a session-level variable. Recent versions of Access have these, and they persist beyond the point at which the project crashes or stops.

From there, it''s a simple case of changing any references in your logging procedures to reference that variable instead of using NetworkUserName().

Let us know if you need more help implementing this. I''m rushing at the moment, but will have more time when next I look.

Welcome to Bytes :-)


Hi NeoPa,

Thanks for the warm welcome. I''ve read through dozens of threads in Bytes and somehow learned how''s best to approach the forum :)

Anyways, you guessed right. I do need further help on this. I dont quite understand by what you meant with "session-level variable".

My guess is I would have to change Line 4-31 accordingly from the audit trail module; but I have no idea how to do this.

I''ll be patient and wait till you have some time to reply.

Thanks!


I think that Neopa is refering to the newer "temporary variable" collection that is available in ACC2007/2010.

This link has a VERY basic explanation and example of useage:
Power Tip: Maximize the use of TempVars in Access 2007 and 2010

The cool thing here is that you can reference these from the stored queries without a function call!

Neopa will be along shortly to correct me if I''m off...

If you need still more help let us know.


这篇关于Allen Browne的审计跟踪 - 更改NetworkUsername()函数的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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