473,410 Members | 1,908 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,410 software developers and data experts.

Migrating Excel 2000 VBA to Excel 2003

I have an issue with excel VBA proc created under Excel-2000 VBA-6.0 (and working well) and the same VBA proc migrated to Excel-2003 VBA-6.3

For example on keyword "Mid"

Rty = Mid(Cells(n, m + 10), 3, 1)

VBA says : Compile error - Can't find project or library

and it's the same for Right, Left etc.

May be a library is missing !!

Is somebody can help.

Thanks in advance,

Jeff
Mar 13 '08 #1
5 2327
kadghar
1,295 Expert 1GB
I have an issue with excel VBA proc created under Excel-2000 VBA-6.0 (and working well) and the same VBA proc migrated to Excel-2003 VBA-6.3

For example on keyword "Mid"

Rty = Mid(Cells(n, m + 10), 3, 1)

VBA says : Compile error - Can't find project or library

and it's the same for Right, Left etc.

May be a library is missing !!

Is somebody can help.

Thanks in advance,

Jeff
i dont know why some newer versions of VB has the substring property, instead of those functions. (but i think that wasnt changed in VBA, so may be the error is because you're actually missing a library), try using the substring property, that strings might have.
Mar 13 '08 #2
Killer42
8,435 Expert 8TB
I'm using VBA 6.3 in Excel 2003 at work, and "out of the box" it certainly supports the Mid, Left and Right functions. If I hit "references" it shows
  • Visual Basic for Applications
  • Microsoft Excel 11.0 Object Library
  • OLE Automation
  • Microsoft Office 11.0 Object Library
One would tend to expect this sort of thing to live in the VBA library, if any.

Are we absolutely certain that it's the Mid() function which is the problem, and not something else that's being referenced there? And when editing this code, does it show the usual suggested syntax when you enter the "(" after "Mid"?
Mar 14 '08 #3
i dont know why some newer versions of VB has the substring property, instead of those functions. (but i think that wasnt changed in VBA, so may be the error is because you're actually missing a library), try using the substring property, that strings might have.

Thanks for your anwser "Kadghar". I have checked libraries needed and All necessary libraries are there.!!!
I found a solution by creating a new excel workbook under Execl-2003 and importing VBA sources from original xls file.
All is ok now...
Mar 14 '08 #4
I'm using VBA 6.3 in Excel 2003 at work, and "out of the box" it certainly supports the Mid, Left and Right functions. If I hit "references" it shows
  • Visual Basic for Applications
  • Microsoft Excel 11.0 Object Library
  • OLE Automation
  • Microsoft Office 11.0 Object Library
One would tend to expect this sort of thing to live in the VBA library, if any.

Are we absolutely certain that it's the Mid() function which is the problem, and not something else that's being referenced there? And when editing this code, does it show the usual suggested syntax when you enter the "(" after "Mid"?

Thanks also "Killer42" You can see what I did reading my reply to "Kadghar"
Mar 14 '08 #5
Killer42
8,435 Expert 8TB
Seems strange you needed to go to such lengths, but I'm glad to hear you got it sorted out.
Mar 17 '08 #6

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

Similar topics

3
by: Dean Bortell | last post by:
This code runs fine on win xp and office xp: string sheetPassword = "Senior1993"; string sheetToOpen = "NewRpt1c.xls"; Excel.Application excelApp = new Excel.Application();...
1
by: Benjamin | last post by:
I am making a Windows EXE (.NET Visual Basic Windows Application). I would like to make it possible to open Excel Worksheets from my EXE. This should work independent of Excel version on client...
17
by: Mansi | last post by:
I need to do some research on how to use excel automation from c#. Does anyone know of any good books related to this subject? Thanks. Mansi
6
by: Shai Levi | last post by:
Hi, I'm trying to migrate native c++ class to managed c++ class. The native class header definition looks as: class NativeClass { public: typedef void (CbFunc1)(int n,void* p);
3
by: Atley | last post by:
I am trying to create a new spreadsheet in Excel using VB.net 2003. This application has to be useable by a range of users running anywhere from Excel 2000 to Excel XP to Excel 2003. My dev...
11
by: Neil | last post by:
We are running SQL 7, using Access 2000 as a front end. Our network person is wanting to migrate to Windows 2003 (we're currently on Windows 2000), and wants to know if we should migrate to SQL...
4
by: snare88 | last post by:
I have a question regarding a VB.NET 2003 application which was built on a Windows XP machine with Office 2002 installed. The software does some interfacing with Microsoft Excel. I now want to...
2
by: smtwtfs007 | last post by:
Guys, I am having problems with Excel 2000 to Excel 2003 dll in production. I am having version 2003 in my PC and I used the below code change to open password protected excel files in my...
4
by: =?Utf-8?B?THluZXJz?= | last post by:
Hello All, We have a VB.NET application writen using VS 2003. This application apens an excel file from a vendor, reads the data and performs whatever functions it needs. We recently upgraded our...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.