Rabu, 23 Mei 2012

RE: [MS_AccessPros] Datasheet view - data entry mode

 

Actually John, I've rethought this. I have users who need to add a lot of data, and so 'm having the subform datasheet view have a before update do this:
Me.controlname = replace(replace(me.controlname,vbcrlf,""),vbtab,"")

For all the controls. I'm going to deploy that this morning and see how it works.

Liz Ravenwood
Database Developer / Programmer
Super First Class Products
B/E Aerospace
O: 1.520.239.4808
www.beaerospace.com

-----Original Message-----
From: MS_Access_Professionals@yahoogroups.com [mailto:MS_Access_Professionals@yahoogroups.com] On Behalf Of John Viescas
Sent: Tuesday, May 22, 2012 10:24 PM
To: MS_Access_Professionals@yahoogroups.com
Subject: RE: [MS_AccessPros] Datasheet view - data entry mode

Liz-

Sorry, I should have checked which one to use. You need to use KeyDown:

http://msdn.microsoft.com/en-us/library/bb214818(v=office.12)

Look for KeyCode = 22 and (Shift And acCtrlMask) <> 0. Set KeyCode = 0 to kill
the keystroke.

John Viescas, author
Microsoft Office Access 2010 Inside Out
Microsoft Office Access 2007 Inside Out
Building Microsoft Access Applications
Microsoft Office Access 2003 Inside Out
SQL Queries for Mere Mortals
http://www.viescas.com/
(Paris, France)

---------------------------------

From: MS_Access_Professionals@yahoogroups.com
[mailto:MS_Access_Professionals@yahoogroups.com] On Behalf Of Liz Ravenwood
Sent: Wednesday, May 23, 2012 12:29 AM
To: 'MS_Access_Professionals@yahoogroups.com'
Subject: RE: [MS_AccessPros] Datasheet view - data entry mode

John, will this do it?

Private Sub Form_KeyPress(KeyAscii As Integer)
If KeyAscii = 22 Then
KeyAscii = 0
MsgBox ("Pasting is not allowed")
End If
End Sub

Liz Ravenwood
Database Developer / Programmer
Super First Class Products
B/E Aerospace
O: 1.520.239.4808
www.beaerospace.com

-----Original Message-----
From: MS_Access_Professionals@yahoogroups.com
[mailto:MS_Access_Professionals@yahoogroups.com] On Behalf Of John Viescas
Sent: Tuesday, May 22, 2012 2:00 PM
To: MS_Access_Professionals@yahoogroups.com
Subject: RE: [MS_AccessPros] Datasheet view - data entry mode

Liz-

Yes. Those events exist for the form and all editable controls. To trap at the
form level, set Key Preview to Yes for the form.

John Viescas, author

Microsoft Office Access 2010 Inside Out

Microsoft Office Access 2007 Inside Out

Building Microsoft Access Applications

Microsoft Office Access 2003 Inside Out

SQL Queries for Mere Mortals

<http://www.viescas.com/> http://www.viescas.com/

(Paris, France)

From: MS_Access_Professionals@yahoogroups.com
[mailto:MS_Access_Professionals@yahoogroups.com] On Behalf Of Liz Ravenwood
Sent: Tuesday, May 22, 2012 10:29 PM
To: 'MS_Access_Professionals@yahoogroups.com'
Subject: RE: [MS_AccessPros] Datasheet view - data entry mode

So those are events then John? I'm in Access 2007.

Liz Ravenwood
Database Developer / Programmer
Super First Class Products
B/E Aerospace
O: 1.520.239.4808
www.beaerospace.com

-----Original Message-----
From: MS_Access_Professionals@yahoogroups.com
<mailto:MS_Access_Professionals%40yahoogroups.com>
[mailto:MS_Access_Professionals@yahoogroups.com
<mailto:MS_Access_Professionals%40yahoogroups.com> ] On Behalf Of John Viescas
Sent: Tuesday, May 22, 2012 1:16 PM
To: MS_Access_Professionals@yahoogroups.com
<mailto:MS_Access_Professionals%40yahoogroups.com>
Subject: RE: [MS_AccessPros] Datasheet view - data entry mode

Liz-

Kill the Ribbon or Menus (depending on version) and trap the CTRL+V and CTRL+C
keys in Key Down or Key Press.

John Viescas, author

Microsoft Office Access 2010 Inside Out

Microsoft Office Access 2007 Inside Out

Building Microsoft Access Applications

Microsoft Office Access 2003 Inside Out

SQL Queries for Mere Mortals

<http://www.viescas.com/> http://www.viescas.com/

(Paris, France)

From: MS_Access_Professionals@yahoogroups.com
<mailto:MS_Access_Professionals%40yahoogroups.com>
[mailto:MS_Access_Professionals@yahoogroups.com
<mailto:MS_Access_Professionals%40yahoogroups.com> ] On Behalf Of Liz Ravenwood
Sent: Tuesday, May 22, 2012 10:00 PM
To: 'MS_Access_Professionals@yahoogroups.com
<mailto:%27MS_Access_Professionals%40yahoogroups.com> '
Subject: RE: [MS_AccessPros] Datasheet view - data entry mode

So... I assumed too quickly.

We've been analyzing it, and the copy/paste could have happened simultaneously.
I saw too many weird things like the data had lost it's fk - which would have
happened if he had done it, but then it appeared and they were all wrong, and
then funky data showed up in weird places. This... while the database was
disabled to all users.

I have a question. How can I disable copy/paste in to a datasheet?

Liz Ravenwood
Database Developer / Programmer
Super First Class Products
B/E Aerospace
O: 1.520.239.4808
www.beaerospace.com

-----Original Message-----
From: MS_Access_Professionals@yahoogroups.com
<mailto:MS_Access_Professionals%40yahoogroups.com>
<mailto:MS_Access_Professionals%40yahoogroups.com>
[mailto:MS_Access_Professionals@yahoogroups.com
<mailto:MS_Access_Professionals%40yahoogroups.com>
<mailto:MS_Access_Professionals%40yahoogroups.com> ] On Behalf Of John Viescas
Sent: Tuesday, May 22, 2012 12:40 PM
To: MS_Access_Professionals@yahoogroups.com
<mailto:MS_Access_Professionals%40yahoogroups.com>
<mailto:MS_Access_Professionals%40yahoogroups.com>
Subject: RE: [MS_AccessPros] Datasheet view - data entry mode

A pox on his house!

John Viescas, author

Microsoft Office Access 2010 Inside Out

Microsoft Office Access 2007 Inside Out

Building Microsoft Access Applications

Microsoft Office Access 2003 Inside Out

SQL Queries for Mere Mortals

<http://www.viescas.com/> http://www.viescas.com/

(Paris, France)

From: MS_Access_Professionals@yahoogroups.com
<mailto:MS_Access_Professionals%40yahoogroups.com>
<mailto:MS_Access_Professionals%40yahoogroups.com>
[mailto:MS_Access_Professionals@yahoogroups.com
<mailto:MS_Access_Professionals%40yahoogroups.com>
<mailto:MS_Access_Professionals%40yahoogroups.com> ] On Behalf Of Liz Ravenwood
Sent: Tuesday, May 22, 2012 9:20 PM
To: 'MS_Access_Professionals@yahoogroups.com
<mailto:%27MS_Access_Professionals%40yahoogroups.com>
<mailto:%27MS_Access_Professionals%40yahoogroups.com> '
Subject: RE: [MS_AccessPros] Datasheet view - data entry mode

Yes. It has worked for years. I just checked and he did indeed have the table
opened.

Liz Ravenwood
Database Developer / Programmer
Super First Class Products
B/E Aerospace
O: 1.520.239.4808
www.beaerospace.com

-----Original Message-----
From: MS_Access_Professionals@yahoogroups.com
<mailto:MS_Access_Professionals%40yahoogroups.com>
<mailto:MS_Access_Professionals%40yahoogroups.com>
<mailto:MS_Access_Professionals%40yahoogroups.com>
[mailto:MS_Access_Professionals@yahoogroups.com
<mailto:MS_Access_Professionals%40yahoogroups.com>
<mailto:MS_Access_Professionals%40yahoogroups.com>
<mailto:MS_Access_Professionals%40yahoogroups.com> ] On Behalf Of John Viescas
Sent: Tuesday, May 22, 2012 11:57 AM
To: MS_Access_Professionals@yahoogroups.com
<mailto:MS_Access_Professionals%40yahoogroups.com>
<mailto:MS_Access_Professionals%40yahoogroups.com>
<mailto:MS_Access_Professionals%40yahoogroups.com>
Subject: RE: [MS_AccessPros] Datasheet view - data entry mode

Liz-

I assume the Datasheet form is bound to something, right? Is the user "pasting"
into some sort of working table, then your code copies the data where it
belongs? There's no way that could have affected your main data table.

John Viescas, author

Microsoft Office Access 2010 Inside Out

Microsoft Office Access 2007 Inside Out

Building Microsoft Access Applications

Microsoft Office Access 2003 Inside Out

SQL Queries for Mere Mortals

<http://www.viescas.com/> http://www.viescas.com/

(Paris, France)

From: MS_Access_Professionals@yahoogroups.com
<mailto:MS_Access_Professionals%40yahoogroups.com>
<mailto:MS_Access_Professionals%40yahoogroups.com>
<mailto:MS_Access_Professionals%40yahoogroups.com>
[mailto:MS_Access_Professionals@yahoogroups.com
<mailto:MS_Access_Professionals%40yahoogroups.com>
<mailto:MS_Access_Professionals%40yahoogroups.com>
<mailto:MS_Access_Professionals%40yahoogroups.com> ] On Behalf Of Liz Ravenwood
Sent: Tuesday, May 22, 2012 8:42 PM
To: 'MS_Access_Professionals@yahoogroups.com
<mailto:%27MS_Access_Professionals%40yahoogroups.com>
<mailto:%27MS_Access_Professionals%40yahoogroups.com>
<mailto:%27MS_Access_Professionals%40yahoogroups.com> '
Subject: [MS_AccessPros] Datasheet view - data entry mode

Hey folks, having an irritating time here...

I have a little button that allows a user to open up a form datasheet view data
entry mode so that they can paste data in to the form, and then I have an event
that upon exit of the form, the data gets appended in to the database as the
subform data. (don't ask me the rationale at this point as I'm in a crisis)

A user called up and for some reason had fat fingered all over the place, and
said that the datasheet view had more items because of what he had copied from
his spreadsheet. So I had him delete and try to start over. He said he still had
problems and will have to come visit me after lunch. He said he deleted all the
records he had pasted and expressed worry that he was doing damage. I figured it
was okay - data entry mode and all... should have been what he pasted.

A 2nd user shows me a screen with the kanji that indicates corruption, and we
discover that many records have been deleted from that table.

I'm thinking it's just coincidence, right? There is no way in hell that an
acformds data entry could backdoor delete a bunch of table records, and if so,
it would have deleted all of them?

UNLESS - he found access to the table, and he shouldn't unless he has the
password to the non-run time version that actually can get him to the tables!

CRAP. Now I have to wait for corp IT to restore the file.

Liz Ravenwood
Database Developer / Programmer
Super First Class Products
B/E Aerospace
O: 1.520.239.4808
www.beaerospace.com

This email (and all attachments) is for the sole use of the intended
recipient(s) and may contain privileged and/or proprietary information. Any
unauthorized review, use, disclosure or distribution is prohibited. If you are
not the intended recipient, please contact the sender by reply e-mail and
destroy all copies of the original message.

[Non-text portions of this message have been removed]

------------------------------------

Yahoo! Groups Links

This email (and all attachments) is for the sole use of the intended
recipient(s) and may contain privileged and/or proprietary information. Any
unauthorized review, use, disclosure or distribution is prohibited. If you are
not the intended recipient, please contact the sender by reply e-mail and
destroy all copies of the original message.

[Non-text portions of this message have been removed]

------------------------------------

Yahoo! Groups Links

This email (and all attachments) is for the sole use of the intended
recipient(s) and may contain privileged and/or proprietary information. Any
unauthorized review, use, disclosure or distribution is prohibited. If you are
not the intended recipient, please contact the sender by reply e-mail and
destroy all copies of the original message.

[Non-text portions of this message have been removed]

------------------------------------

Yahoo! Groups Links

This email (and all attachments) is for the sole use of the intended
recipient(s) and may contain privileged and/or proprietary information. Any
unauthorized review, use, disclosure or distribution is prohibited. If you are
not the intended recipient, please contact the sender by reply e-mail and
destroy all copies of the original message.

[Non-text portions of this message have been removed]

------------------------------------

Yahoo! Groups Links

This email (and all attachments) is for the sole use of the intended
recipient(s) and may contain privileged and/or proprietary information. Any
unauthorized review, use, disclosure or distribution is prohibited. If you are
not the intended recipient, please contact the sender by reply e-mail and
destroy all copies of the original message.

------------------------------------

Yahoo! Groups Links

This email (and all attachments) is for the sole use of the intended recipient(s) and may contain privileged and/or proprietary information. Any unauthorized review, use, disclosure or distribution is prohibited. If you are not the intended recipient, please contact the sender by reply e-mail and destroy all copies of the original message.

__._,_.___
Recent Activity:
.

__,_._,___

Tidak ada komentar:

Posting Komentar