LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default Compile error: Method or data member not found

Hi,

I have developed a spreadsheet for Excel 97/2002. The spreadsheet includes a
number of controls including a combo box (id cmbCompanyCode). This
spreadsheet has been rolled out to about 2,500 users without many problems
(except 1 user (there is always one!)).

I have recieved the message "Compile error: Method or data member not found"
when the code "If (Sheet2.cmbCompanyCode.ListIndex 0) Then" is run in the
following code block...

Private Sub Workbook_Open()

' Get the company codes and hold them in an array...
PopulateCompanyCodes

' Show / Hide the upload button...
Sheet2.btnUploadIntoSAP.Visible =
DefaultProfitCentreFileExists(Range("DefaultProfit CentreIdsPath").Value)

If (Sheet2.cmbCompanyCode.ListIndex 0) Then
' Set the company code from the drop down list selection...
Range("CompanyCode").Value =
arrCompanyCodes(Sheet2.cmbCompanyCode.ListIndex - 1).CompanyCode
Else
Range("CompanyCode").Value = ""
End If

End Sub

When I logged onto this machine and broke into the VBA I tried to use the
immediate window to check whether Sheet2.cmbCompanyCode exists but the
intellisense did not pick up cmbCompanyCode.

My gut feeling is that something relating to COM is screwed up thus the
combo box is not accessible but I have no idea how to fix it.

I have tried the following...
1. Refreshed the copy of the spreadsheet just in case the file is corrupt.
2. Copied the file onto another machine to see if the same problem can be
reproduced - no luck
3. Checked the references inside the vb project - exactly matched to another
machine that works okay.
4. Crawled the web any only really found a MAC converstion problem with
ActiveX controls.
5. Removed the registry settings from
HKEY_CURRENT_USER\Software\Microsoft\Office\10.0\E xcel and had Excel rebuild
them (getting desperate!).

Any help is greatly appreciated,

Thanks

Oliver Bullock
 
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
Compile error: Method or data member not found Brian Day Excel Worksheet Functions 0 July 22nd 07 03:20 AM
Compile Error Method or data member not found ExcelMonkey Excel Programming 1 October 4th 05 10:41 PM
Compile Error: Method or data member not found Nick S[_4_] Excel Programming 0 November 16th 04 04:43 PM
Compile Error: Method or data member not found Nick S[_3_] Excel Programming 2 November 16th 04 02:38 PM
Compile Error: Method or data member not found Nick S[_2_] Excel Programming 1 November 16th 04 11:41 AM


All times are GMT +1. The time now is 08:30 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"