+ Reply to Thread
Results 1 to 4 of 4

Opening files using Open Text Enterprise Connect VBA library

  1. #1
    Registered User
    Join Date
    03-27-2024
    Location
    Glasgow, UK
    MS-Off Ver
    Office 365
    Posts
    2

    Opening files using Open Text Enterprise Connect VBA library

    Hello all just joined - 1st post

    I've been using macros in Excel files held in EDRMS/ Opentext for some years which basically go to - via "Workbooks.Open Filename ........ " etc - open other Excel files kept in Opentext to copy data from & paste it into my original file containing the macro, for further manipulation.

    We've had a recent upgrade to Opentext and "Workbooks.Open Filename ..... " no longer works and we've been advised to use a different method to open the other file, as follows -
    Please Login or Register  to view this content.
    Administrator's note: Please take the time to review our rules. There aren't many, and they are all important. Our guidelines recommend code tags. I have added them for you this time because you are a new member. --6StringJazzer


    - the above breaks & displays the end/ debug dialog box on screen when it executes "oitem.open". "Workbooks(2).Activate" is highlighted in yellow. As soon as I press debug the new file opens and the macro can be restarted with F5.

    Any advice on how to resolve this gratefully received. Thanks in advance.
    Last edited by 6StringJazzer; 03-27-2024 at 09:20 AM.

  2. #2
    Administrator 6StringJazzer's Avatar
    Join Date
    01-27-2010
    Location
    Tysons Corner, VA, USA
    MS-Off Ver
    MS365 Family 64-bit
    Posts
    24,721

    Re: Excel VBA & OpenText

    What is the error number and error message?

    I have clarified the title just a bit.
    Jeff
    | | |會 |會 |會 |會 | |:| | |會 |會
    Read the rules
    Use code tags to [code]enclose your code![/code]

  3. #3
    Registered User
    Join Date
    03-27-2024
    Location
    Glasgow, UK
    MS-Off Ver
    Office 365
    Posts
    2

    Re: Excel VBA & OpenText

    Run-time error'9':

    Subscript out of range



    it's as if the macro hasn't finished executing the "oitem.Open (oContext)" line before it moves on to activating the newly opening/ opened workbook

  4. #4
    Administrator 6StringJazzer's Avatar
    Join Date
    01-27-2010
    Location
    Tysons Corner, VA, USA
    MS-Off Ver
    MS365 Family 64-bit
    Posts
    24,721

    Re: Opening files using Open Text Enterprise Connect VBA library

    Yes, there is no second workbook open at the time this line is executed. I am not familiar with that particular API but generally a sub call is synchronous--it should not return until the file is open. (The exception to that are things like OS calls that run an external process.)

    EDIT: This is a wild guess but maybe try a delay. This one waits 5 seconds:
    Please Login or Register  to view this content.
    I am curious as to why Workbooks.Open would not work. A workbook is a workbook. Are the workbooks not in the Windows file system?

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Workbooks.opentext and Excel column limit..need workaround
    By enphynity in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 08-12-2013, 07:58 AM
  2. user select for "workbooks.opentext" excel feature
    By karl1985 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 08-27-2010, 07:26 AM
  3. [SOLVED] opentext
    By neia in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 05-08-2006, 11:35 AM
  4. OpenText
    By Mike Archer in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 02-13-2006, 05:25 PM
  5. Calling Excel/Opentext method via ActiveX in a service application
    By Salar Madadi in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 01-30-2006, 07:35 PM
  6. [SOLVED] migration issue - OpenText method crashes Excel.
    By Michael in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 01-09-2006, 12:15 PM
  7. Problem with OpenText in Excel 2000 (date format)
    By sorin in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 09-13-2005, 01:05 PM
  8. [SOLVED] opentext method of excel workbook object
    By Kislay in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 05-11-2005, 11:06 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1