By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
459,518 Members | 1,211 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 459,518 IT Pros & Developers. It's quick & easy.

Selecting multiple records

dima69
Expert 100+
P: 181
Is it possible to select multiple records on datasheet via code ?
Using SelTop and SelHeight properties dosn't give the same result as selecting the records manually, since record selectors remain unselected.
Oct 4 '06 #1
Share this Question
Share on Google+
4 Replies


100+
P: 143
Not in datasheet view. Why do you need to select more than one record at a time?
Oct 4 '06 #2

dima69
Expert 100+
P: 181
Well, I need that, for example, to mark records I intend to delete or cut and paste. Another thing is to restore user selection after the focus has been moved to another control, i.e. commadn button.
Oct 5 '06 #3

PEB
Expert 100+
P: 1,418
PEB
Hi,
If you can do the selection using the keyboard, you can do it programatically with the procedure sendkeys!

See exemple:

Dim ReturnValue, I
ReturnValue = Shell("CALC.EXE", 1) ' Run Calculator.
AppActivate ReturnValue ' Activate the Calculator.
For I = 1 To 100 ' Set up counting loop.
SendKeys I & "{+}", True ' Send keystrokes to Calculator
Next I ' to add each value of I.
SendKeys "=", True ' Get grand total.
SendKeys "%{F4}", True ' Send ALT+F4 to close Calculator.
Oct 8 '06 #4

dima69
Expert 100+
P: 181
Hi,
If you can do the selection using the keyboard, you can do it programatically with the procedure sendkeys!
Thanks for the advice, but I'm trying to stay away from SendKeys precedure, whenever possible.
Oct 8 '06 #5

Post your reply

Sign in to post your reply or Sign up for a free account.