+ Reply to Thread
Results 1 to 7 of 7

call a sub from an xls file on the network

  1. #1
    Forum Contributor
    Join Date
    09-19-2004
    Posts
    252

    call a sub from an xls file on the network

    I'm trying to put some visual basic out on the network drive at work so I created a book and called it Macro.xls. I then saved the code within that book and saved it out on my network. I'm now trying to run that code by calling the sub and don't know how to do that. This isn't working, any ideas?
    Please Login or Register  to view this content.
    Last edited by VBA Noob; 10-02-2008 at 05:06 PM.

  2. #2
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,258
    Hello DKY,

    Try this...
    Please Login or Register  to view this content.
    Sincerely,
    Leith Ross

  3. #3
    Forum Contributor
    Join Date
    09-19-2004
    Posts
    252
    I get the following error when I try to run that code
    Cannot run the macro 'DESCRIPTION_CLEANER_UPPER'. The macro may not be available in this workbook or all macros may be disabled.
    I know that it's the right path (because it opens the xls file) and that the sub named "DESCRIPTION_CLEANER_UPPER" is in there, I copied and pasted both the path and the name just to make sure and it still doesn't work.

  4. #4
    Forum Contributor
    Join Date
    09-19-2004
    Posts
    252
    Here's the exact code I'm using
    Please Login or Register  to view this content.
    and here's the code that it's referring to
    Please Login or Register  to view this content.
    I know that the Macro.xls file is opening up so the path is correct and I know that the 'referring to' code is in the Modules section of the Macros.xls. Could this be a 2007 thing?

  5. #5
    Forum Contributor
    Join Date
    09-19-2004
    Posts
    252
    I couldn't find a "prefix dropdown" so:

    ############## SOLVED ################

  6. #6
    Forum Contributor VBA Noob's Avatar
    Join Date
    04-25-2006
    Location
    London, England
    MS-Off Ver
    xl03 & xl 07(Jan 09)
    Posts
    11,988
    DKY,

    Care to share the solution you found from the cross posts on two other excel forums and also add the links as per forum rules below

    VBA Noob
    Last edited by VBA Noob; 10-02-2008 at 05:48 PM.
    _________________________________________


    Credo Elvem ipsum etian vivere
    _________________________________________
    A message for cross posters

    Please remember to wrap code.

    Forum Rules

    Please add to your signature if you found this link helpful. Excel links !!!

  7. #7
    Forum Contributor
    Join Date
    09-19-2004
    Posts
    252
    In all my years in forums (even doing forum support for Ikonboard a few years back) I've never heard of cross posting so I'd like to start out by asking forgiveness.

    The final solution (for me) was to put the file Macro.xls on a network drive and then make it read-only in the file's properties. From there I put a shortcut in the 'XLSTART' folder so that it started up everytime I started Excel. At that point when I go to run a macro my DESCRIPTION_CLEANER_UPPER macro is available and I don't need another macro to point to it.

    Thanks for all of your help guys, I don't know where I would be without that support.

    Other forums I posted in:
    http://www.xtremevbtalk.com/showthread.php?p=1306578
    http://www.mrexcel.com/forum/showthread.php?p=1701261
    http://www.excelforum.com/excel-prog...e-network.html

+ 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. Access data from a delimited file
    By jonlemur in forum Excel General
    Replies: 1
    Last Post: 11-11-2007, 07:52 AM
  2. variable file reference
    By johndough185 in forum Excel General
    Replies: 5
    Last Post: 11-01-2007, 09:48 AM
  3. Conditional saving in a given directory, with always changing file name
    By hunsnowboarder in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 08-24-2007, 12:26 PM
  4. Reference filename in formula
    By middlectom in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 08-21-2007, 07:37 PM
  5. Finding next empty row in another worksheet
    By spyrule in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 10-13-2006, 10:56 AM

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