Sendkeys

Jul 6, 2005

I have an update query (thanks nofriends ) that I execute from VB code when closing a form. As you know, you get prompted if you really want to run the update, and then if you want to continue after it tells you how many rows are updated.

I used Sendkeys "{Enter}", True and Sendkeys "{Enter}

In both cases the action of the enter key was not automatically executed. Any ideas on what I am doing wrong?

Thanks again,

Beagles

View Replies


ADVERTISEMENT

Can A Memo Field In Different Records Be Combined Without SendKeys

Jan 4, 2008

I have a problem that is Vista related. My business partner has just purchased a laptop with Vista and one of the problem areas is SendKeys. I don't have Vista and he is away at the moment so we only have part time communication so I am trying a few solutions in the hope of getting the problem fixed.

He is getting a message along the line of.....Access needs to be reinstalled because SendKeys is not available.....he does not has his MSOffice with him so that can't be tried at the moment, although everything else is working OK.

There are a few macros involved but I have converted then into VB Module and that works OK for me on XP, although it does not carry out all instructions but it basically works. But it will be a few days before he can try what I have sent him.

Note: I just notice that my conversion to VB module is not doing the SendKeys. No messages etc it is if the section covering SendKeys was not there. The example below was done with XP and macro. The SendKeys and the various other actions are all in the module. Edit...All is OK....my conversion of the macros to a module worked:D

So I would like to try another possible solution and that being to avoid SendKeys.

The situation involves a file note entry system. Each file note creates a different record and in each record there is a memo field with the file note that was made and of course time and date.

There is another table that holds one record for each person that has a file note made. Whether one file note is made or a 100 file notes there is only record.......The record is created when the first file note is made and the table will not accept duplicates on the persons ID number.

When a file note is made the system then opens the record in the other table and adds with SendKeys to the entry in the memo field on the "one record only table"

A form opened on the "one record" looks like this and as you can see the contents of the memo field from the "many records" have been combined into one. Can I do this without using SendKeys

5/01/2008 11:34:51 AM Test 1 The quick brown fox jumped over the lazy dog

5/01/2008 11:35:21 AM Now is the time for all good men to come to the aid of the party

5/01/2008 11:35:50 AM Why did John have to buy a computer with Vista?

Aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa

bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb

5/01/2008 11:37:38 AM zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz zzzzzzzzzzzzzzz
zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz
xxxxxxxxxxxxxxxxxxxxxxxxxxxx

View 14 Replies View Related

Modules & VBA :: ASCII And Sendkeys - Put Full Stop In The Field

Jan 15, 2015

I have a Combo box which contains a set of numbers divided by "."

e.g.: 1.342567.24433

When looking for a certain code, I would like to use the number pad to enter the first few e.g. 1.34 to move to the Position. In Previous Versions of Access I had a function on the key

If KeyAscii = 44 Then
DoCmd.CancelEvent 'stop the comma keypress being updated
SendKeys ".", True 'put a full stop in the field
End If

This worked fine, but in Access 7 and up, it turns off the number lock.

Is there an alternative to sendkeys to achieve the above or a way of directly turning the number lock on again?

View 3 Replies View Related

Modules & VBA :: SendKeys After Every 5 Minutes To Stop Screen Saver To Occur

Mar 3, 2015

I am writing the following piece of code to be called again and again after 30 min. But I need to do invisible mouse move to stop screen saver occurring so i want to sendkeys after every 5 minutes. The Sub abc is in module and everything works except stopping screensaver from occurring.

Code:
Private Sub UserForm_Initialize()
'Update the Barcodes printed today
Call CommandButton1_Click
'Update batches to be scanned / batches scanned today
Call CommandButton3_Click

[Code] ....

View 14 Replies View Related

SendKeys Or Macro For "Right-click And Paste"

Dec 17, 2004

In short, my goal is to automate the function that Generates a Report, saves it as an Adobe PDF file using a "selected" file name. The selected file name is the name of the project (which is included as a datafield) in my primary tabel ( a linked Excel table). There maybe an easier way than the path I have chosen, if so please let me know.

The following provides a little more detail as to what I've done and what my problem is:

As noted above, my primary table is a linked table (Excel). There is datafield in that table that has the project code (and this is the name I want my PDF file to be). As a result, I created a new query in Access to query this project code. As a result, in my Generate Report macro, I open this query and then use the SendKey function to copy the datacell (i.e., project name) so I use this later to paste. My macro proceeds with opening my Primary Report and then "print" the file. Since I've selected Adobe PDF as my default printer, it will print to a file. As a result, the "Save PDF File as" menu pops up and the file name (Access name of the Report) is highlighted. However, my SendKey command to paste the project name does not work. When the "Save PDF File as" menu is up, the primary menu (ie., that has File, Edit, View, etc.) is inactive and my sendkey command will not process. However, at this point the mouse is still active and I can manually right-click the mouse and select paste for it to work.

The question is --- is there a way to perform the right-click and paste in a Macro or SendKey function. I don't see a SendKey command that invokes the right-click.

View 4 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved