Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Activate method of OLEObject failed


Hi Forum

1. I implemented a worksheet with several Text Boxes from Controls
Toolbox.

2. To navigate around the Text Boxes , used a Bob Phillips
recommendation (thanks again Bob) that worked very well.


Code:
--------------------
How to jump between TextBoxes

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

Here is a way

Private Sub TextBox1_KeyDown(ByVal KeyCode As MSForms.ReturnInteger, _
ByVal Shift As Integer)
Dim bBackwards As Boolean


Select Case KeyCode
Case vbKeyTab, vbKeyReturn, vbKeyDown, vbKeyUp
Application.ScreenUpdating = False
bBackwards = CBool(Shift And 1) Or (KeyCode = vbKeyUp)
'Excel 97 must select cell before activating another control.
If Application.Version < 9 Then Sheet1.Range("A1").Select
If bBackwards Then
TextBox3.Activate
Else
TextBox2.Activate
End If
Application.ScreenUpdating = True
End Select
End Sub
--------------------


3. My problems began when i "shared" the worksheet, everything works
well except when i tried to navigate using the enter, tab or arrows for
which i coded.
In that cases i receive the "run time error 1004" Activate method of
OLEObject class failed.

4. Could not see where the trouble araises because the "shared feature"
that prevents me from seeing the VBA code.

Could you give some directions or strategies on how to proceed to avoid
this error.

As allways thanks for your advice.

Regards

Jose Luis


--
jose luis
------------------------------------------------------------------------
jose luis's Profile: http://www.excelforum.com/member.php...o&userid=13312
View this thread: http://www.excelforum.com/showthread...hreadid=376198

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Method 'Copy' of object'_Worksheet failed q2w3e4r Excel Worksheet Functions 1 February 7th 07 01:17 PM
Run-time error : method failed Joris Adriaenssens Excel Programming 4 June 11th 04 05:07 PM
Copypicture method failed Kamal[_5_] Excel Programming 2 April 22nd 04 11:31 AM
Calculation Method Failed Martiin Excel Programming 2 December 1st 03 01:37 PM
Method ~ of Object ~ Failed. Joan Excel Programming 5 August 26th 03 08:13 PM


All times are GMT +1. The time now is 06:43 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"