M
Mick Ruthven
I have an Access 2002 application that's been running for years. One feature
is a button on a form that copies the string contents of a control to the
clipboard. This morning it stopped working and gives this instead:
Run-time error '2046' - The command or action 'Copy' isn't available now.
Here is the code. It stopped on the "acCmdCopy" line. CtrlName is a variable
that contains the name of the control (I checked and it does contain it),
and the control contains the string to be copied (I checked that too). I
also tried "DoCmd.DoMenuItem A_FORMBAR, A_EDITMENU, A_COPY" and got the same
error.
DoCmd.GoToControl CtrlName
DoCmd.RunCommand acCmdCopy
Any ideas? This function has worked for years, including just a few days
ago, and I've not changed anything regarding Access other than creating a
new Access Project using SQL Server, but that should have nothing to do with
this standalone Access app. It's on a Win XP SP1 system.
Thanks,
Mick Ruthven
is a button on a form that copies the string contents of a control to the
clipboard. This morning it stopped working and gives this instead:
Run-time error '2046' - The command or action 'Copy' isn't available now.
Here is the code. It stopped on the "acCmdCopy" line. CtrlName is a variable
that contains the name of the control (I checked and it does contain it),
and the control contains the string to be copied (I checked that too). I
also tried "DoCmd.DoMenuItem A_FORMBAR, A_EDITMENU, A_COPY" and got the same
error.
DoCmd.GoToControl CtrlName
DoCmd.RunCommand acCmdCopy
Any ideas? This function has worked for years, including just a few days
ago, and I've not changed anything regarding Access other than creating a
new Access Project using SQL Server, but that should have nothing to do with
this standalone Access app. It's on a Win XP SP1 system.
Thanks,
Mick Ruthven