Hi All,
I am stuck on a problem and hope someone can help me out. I have 8 users who will be using a form [Frm_main]. For the users to access their accounts I use the SendKeys function, the user click on their name to access their records. Each user has over 300 accounts and it is a growing list.
On my main form [Frm_main] whose record source is a query based on [Tbl_detail], I have a button on the main form which open a pop up form [Frm_review], the source for this form is a query based on [Tbl_detail]. The pop up form only display records that needs to be reviewed for today. On the pop up form [Frm_review] I have a button [Filter] when a user clicks on those records are filtered on the main form. The problem I have is when the user click on it a screen pop’s up asking to enter user. When I enter the user the records are filtered on the main form. Is there a way I can program the button so that it does not ask for a user. The code below is for the [Filter] button.
Private Sub Filter_Click()
Dim code As String
code = "[ReviewDate]= Date()"
DoCmd.OpenForm "Frm_main", acNormal, , code
DoCmd.Close acForm, Me.Name
End Sub
Everything I’ve read on the internet pretty much say I should stay away from using SendKeys. Any advice or suggestion I would greatly appreciate, thank you!
1 2206
Hi All,
I am not sure if anyone was looking into this but I wanted to let everyone know that I decided to change my approach. Dealing with sendkeys is to much problem. I decided to change the RecordSource for each user and it is working great. Here is the code I use in case someone else has the same problem, it is simple.
Private Sub LogginT_Click()
Dim SQL As String
SQL = "SELECT * FROM Tbl_detail WHERE ((Tbl_detail.Us er)='Tom');"
DoCmd.OpenForm "Frm_main", acNormal
Forms! Frm_main.Record Source = SQL
End Sub
Sign in to post your reply or Sign up for a free account.
Similar topics |
by: Robert Neville |
last post by:
I would like to add filter functionality to my database whether
through the Main form or the subform. This question may be
rudimentary, yet I have not less experience with filtering data
outside from queries. Let me just add that Allen Browne excellent
article about this subject may not apply to this scenario on an
elementary level. (Here's the link to the article; Filter a Form on a
Field in a Subform -...
|
by: Andante.in.Blue |
last post by:
Hi everyone! I was wondering if there is a away to use Access 97's
build in filter-by-form function but restrict its effect to just the
subform.
I have a parent form that shows the major divisions of the company,
and a subform that is linked so that it displays all the jobs within
the division in the parent form. I also want the ability to filter
the subform, so the users can pick out a bunch of common jobs easily.
I did this using a...
|
by: Richard |
last post by:
Hi,
I have a form that take some time to load due to many comboboxes and at
least 8 subforms.
When I filter or sort the main form I get an error message and then Access
shuts down. They ask if I want to send the error report to Microsoft. Has
anybody seen this type of error message and what can I do to prevent it from
happening. Am I doing something illegal in my code? It used to work but I
have added conditional formatting to a subform...
|
by: dhowell |
last post by:
In reading some of the posts on this group, it appears as though it is
not strait forward at all to filter a form, which has subforms, by
criteria which are either on subforms or span more than one
subform.....
This MSDN article however makes it sound as simple as clicking "Filter
by Form", entering the search criterial in the form and/or it's
subforms, then just clicking "Apply Filter"......
...
|
by: David Kanter |
last post by:
Hi,
I am relatively inexperienced with VB.Net, but I am familiar with many
concepts from programming; I have some basic level of competence with C/C++
and Perl, but I just started using VB this morning.
I am trying to write an .exe file that is essentially a script. It will
open an application, send it some commands via the keyboard, then wait for
the results and close the application.
| |
by: theBman |
last post by:
I have 2 tables. One master, one child using Access 2003 (PC)
Have 2 forms. The main form is continuous while the sub is datasheet.
I can filter on the main form and the subform filters with it. No problem.
My goal is to be able to filter on the subform and have the main form filtered with it. Thought it would be simple but I for a week solid I have not been able to solve this on my own. I have review a zillion websites and still...
|
by: neonspark |
last post by:
I'm buidling some simple macro functionality for my app so the users can record a sequence of keyboard inputs and replay them reliably via some menu.
Originally, I used:
protected override bool ProcessCmdKey(ref Message msg, Keys keyData)
To map "Keys" objects to their string constant, and stored them on a string Queue as they were happening. Then (after resetting the form), I simulate replaying of these actions by flushing the queued...
|
by: franc sutherland |
last post by:
Hello,
I am using Access 2003. I have a query which shows a list of club
meetings sorted by date. This query is displayed in continuous forms,
in a subform. I would like to select a month on the main form which
is then used to filter the results for the meeting dates, perhaps by
using monthname(month()).
I have struggled to find the syntax which will allow me to use the
AfterUpdate Event on the combo box to apply and turn on the...
|
by: Whizzo |
last post by:
Hi folks;
I spent a little while some time ago building a touchscreen data entry interface into an Access 2003 form. I'm not too experienced in VBA at all so I was quite happy when I came up with a reasonably elegant solution, especially given that there's multiple text boxes involved. Each of the "keys" on the screen keyboard is a cmd button with its letter as a nice big caption on the front. The Mouse Down event triggers a bit of code:
...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
| |
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| | |