Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 29
Default Unable to run macro in Office 2007

Hi,
I have one macro which runs in Excel 2003 but dosent run in Office 2007.
This macro also runs in compatibility mode excel but dosent work in 2007
macro enable excel. Please find below is the code. Is there any reference
which we need to setup.

This macro is to get the data from database.

Please find below is the code and where I am getting the error. Error I am
getting is "Runtime error 424, Object required". Please help me in this.

Sub Get()
Dim i1 As Integer
Dim str1 As String
i1 = 2
While [querylist].Cells(i1, 1) < "" --This is the place where I am
getting error in Excel 2007
CreateQuery (i1)
i1 = i1 + 1
Wend

Worksheets("Sheet1").Select
ActiveWorkbook.Save
End Sub

Thanks,
Mahesh
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2,718
Default Unable to run macro in Office 2007

I'd try:

While Range("querylist").Cells(i1, 1).Value < ""

--
Jim
"Mahesh" wrote in message
...
Hi,
I have one macro which runs in Excel 2003 but dosent run in Office
2007.
This macro also runs in compatibility mode excel but dosent work in 2007
macro enable excel. Please find below is the code. Is there any reference
which we need to setup.

This macro is to get the data from database.

Please find below is the code and where I am getting the error. Error I am
getting is "Runtime error 424, Object required". Please help me in this.

Sub Get()
Dim i1 As Integer
Dim str1 As String
i1 = 2
While [querylist].Cells(i1, 1) < "" --This is the place where I am
getting error in Excel 2007
CreateQuery (i1)
i1 = i1 + 1
Wend

Worksheets("Sheet1").Select
ActiveWorkbook.Save
End Sub

Thanks,
Mahesh



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
Unable to open Office 2007 files using Office 2002 XP GildaBB Excel Discussion (Misc queries) 2 July 20th 07 04:08 AM
Unable to open files after installing Office 2007 refresh !!! rkisling Excel Discussion (Misc queries) 2 October 5th 06 02:43 AM
Where in Office 2007 can I record a macro? Graeme Excel Worksheet Functions 1 August 15th 06 03:07 PM
Performance not upto Office 2003 standards in Office 2007 Mangal Singh Excel Discussion (Misc queries) 11 May 30th 06 12:57 AM
Unable to access the Office Online Web site in Office 2003, Excel Marcy S Excel Discussion (Misc queries) 2 March 21st 06 09:56 PM


All times are GMT +1. The time now is 02:52 AM.

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

About Us

"It's about Microsoft Excel"