Files opening with a number appended

Hi all,

Hope you can help.  I have a Macro in an excel file that looks for and
opens another named excel file based on some variables.  For example a
new spreadsheet is opened today called 100305 (based on the date), the
macro will then look for a file from the previous week (030305), open
it, look for a certain value and copy it into the new sheet.

However from time to time I'm finding that when the macro opens the
previous file it appends a '1' to the end of the name (eg 0303051) and
therefore my macro fails as it can't reference the file properly in
order to find the required value.

I can't find any reason why Excel is adding the 1 to the end and any
help would be much appreciated.

Cheers

Rich May
0
rmay (11)
3/10/2005 5:10:55 PM
excel 39879 articles. 2 followers. Follow

1 Replies
433 Views

Similar Articles

[PageSpeed] 33

When you see that additional 1, do you see an extension (.xls), too?

It sounds like the workbook is being opened as a template.  (Kind of like when
you see book1, book2, book3, when you create new workbooks.)

Rich May wrote:
> 
> Hi all,
> 
> Hope you can help.  I have a Macro in an excel file that looks for and
> opens another named excel file based on some variables.  For example a
> new spreadsheet is opened today called 100305 (based on the date), the
> macro will then look for a file from the previous week (030305), open
> it, look for a certain value and copy it into the new sheet.
> 
> However from time to time I'm finding that when the macro opens the
> previous file it appends a '1' to the end of the name (eg 0303051) and
> therefore my macro fails as it can't reference the file properly in
> order to find the required value.
> 
> I can't find any reason why Excel is adding the 1 to the end and any
> help would be much appreciated.
> 
> Cheers
> 
> Rich May

-- 

Dave Peterson
0
ec357201 (5290)
3/10/2005 5:18:18 PM
Reply:

Similar Artilces:

Font with Monospaced Numbers
Can someone recommmend a readily available sans serif font, similar to Arial, that has monospaced numbers, so that a column of numbers will line up. When I use Arial in an Excel worksheet, the "1" occupies a narrow space, and causes a column of numbers to misalign. I don't want a totally monospaced font (I have one of those). Only the numbers, not text/letters should be monospaced. Thanks for your help. Fred Holmes Try using Courier. HTH Jason Atlanta, GA >-----Original Message----- >Can someone recommmend a readily available sans serif font, similar to >Arial, ...

msnpst files
All: Does anyone have any tips on opening an MSN local folder -- .msnpst -- with Outlook? I can open regular .pst files but Outlook won't recognize the .msnpst files that MSN mail creates. Thanks, John you need to add an account using the msn connector then try closing outlook and replacing the new pst it creates with the old one by renaming the pst's. -- Diane Poremsky [MVP - Outlook] Author, Teach Yourself Outlook 2003 in 24 Hours Coauthor, OneNote 2003 for Windows (Visual QuickStart Guide) Author, Google and Other Search Engines (Visual QuickStart Guide) Outlook Tips: htt...

How can a hyperlink be opened by pressing Enter.
In Excel 2003 after inserting a hyperlink to open a picture file stored in the local drive the user needs to be able to open the file by pressing Enter on the cell that contains the hyperlink rather than by clicking on it with the mouse. This feature is enable in Excel 2000 but it the not work in 2003. (the file type or location does not matter). In short, how can a hyperlink be opened by pressing Enter in Excel 2003. Thank you in advance for your help, Carolina I think that this went away in xl2002. You could send a message to mswish@microsoft.com asking for this to come back. Carol...

Special Random Numbers' Distribution
How to insert random numbers between 1-50 in cells A1:A10, with a condition of using a number once only, i.e. no number repeating. -- Thanx & Best Regards, Faraz! Check out http://www.youtube.com/watch?v=SoK9kq-0uXg -- Jacob "Faraz A. Qureshi" wrote: > How to insert random numbers between 1-50 in cells A1:A10, with a condition > of using a number once only, i.e. no number repeating. > -- > Thanx & Best Regards, > > Faraz! Unfortunately utube's blocked at our OFFICE! :-( -- Thanx & Best Regards, Faraz! &q...

bmp files in Excel Hyperlinks open with wrong program
I have a list of tools in Excel, and I have used Excel's hyperlinking feature to allow displaying a picture of the tool by clicking the link. They always open with Paint, regardless of what I do in the "Folder Options >> File Types" box. I have customized the .BMP file type by adding "Edit with Paint" and "Edit with PhotoEditor" entries to the default settings. Does Excel look for the entry actually labeled "Open" or does it just grab the first entry from the list? (in this case, "Edit with Paint" is first, because they are ...

Excel 2007 convert into tab delimeter text file with extra tab spa
Hi , Sub: I have excel 2007 trying to save as tab delimeted text file having an issue. I have saved my excel 2007 as separate Tab delimited Text files. I see extra tabs stored in the tab delimited text files. But when I do the same with excel 2003 it works fine there is not extra tabs stored in my tab delimited text file. My excel 2007 conveted to tab delimited text file looks like as shown below(Extra two tabs at the end of the each record). Data0<Tab>data1<Tab><Tab> Data2<Tab>data3<Tab><Tab> Appreciate your help in advance. Rega...

Word cannot complete the save due to a file permission error
Hi there, One of my corporate users is experiencing an odd issue producing an error message when attempting to save a Word 2007 document. 1. User has the pre-existing (not new) document open and clicks the save button. 2. In what seems to be a random occurrence, the document will bring up a "Save As" dialog box asking him where to save, as if Word forgot where the document is already saved! Odd thing is, it shows the proper location where the file already exists. 3. User will choose the same location and replace the file. Sometimes it will overwrite and save prope...

Item reorder number
The "item reorder number" is not a field included in the build of a new item. Therefore, there is no item reorder number on a PO for the item. It is especially painful when one deals with matrix items. Is it possible to include the field "item reorder number" in the new item wizard on the next upgrade? ---------------- This post is a suggestion for Microsoft, and Microsoft responds to the suggestions with the most votes. To vote for this suggestion, click the "I Agree" button in the message pane. If you do not see the button, follow this link to open th...

how do make a row non numbered?
Trying to make a row not have a numbered value on the left side. I don't know where you're goinng with this, but.... Those numbers are used for reference purposes by excel. If you'd like to display something different, maybe this will work for you: Use Col_A to display the "row numbers" you'd prefer. Then, Tools|Options|View tab|Uncheck: Row & Column Headers If you need to display the Column Headers, you'll could put them in Row_1. Does that help? *********** Regards, Ron XL2002, WinXP-Pro "Removing number value from a row" wrote: > Tryi...

Temporary Excel files.
Hi, does anyone know where Excel stores its temp files to managing multiple opened copies of the same workbook? Word stores its lock files in same directory of the opened document, but Excel? Thanks in advance for the answers. Alex On a single user (non-networked pc), excel will put a few files in your windows temp folder. But I think it does more than just that. (Just guessing!) When the workbook is on a network, excel/windows is smart enough to be able to tell that second person the the file is in use. If the only indicator were on the first user's temp file, then the seco...

Outlook 2000, large pst file slow to open or corrupt
Hi, this is a very frustratring problem I hope someone canhelp us with. I've established that the outlook.pst file is either too large of corrupt. I've run scanpst which found no problem, the pst file is 2gb! should this cause a problem? I can't reduce the size of the file, although is will open, it won't let me delete of move anything or even archive - reporting that it can;t access the pst file although I can open it and browse contacts and messages (it's very slow doing this though) How can I reduce the size of this file in another way? See if this info helps: http:...

Outlook 2007 long delay when attaching a file
Hi group, I have a long delay (about a minute) when attaching a file. Outlook freezes for a minute before Browse for a file dialog appears. Configuration: Windows 7 x64 BitLocker is enabled Domain joined computer Outlook 2007 SP2 Outlook uses Exchange Server 2007 Any ideas? BR, Mindaugas Do you have mapped drives? That will add a delay. -- Diane Poremsky [MVP - Outlook] Outlook Tips: http://www.outlook-tips.net/ Outlook & Exchange Solutions Center: http://www.slipstick.com/ Outlook Tips by email: mailto:dailytips-subscribe-request@lists.outlooktips.ne...

Saving files as JPG
Often when I save a logo and/or a flyer in publisher and then save it as a jpg for bi print jobs there is a LINE along the side of the piece ... any ideas of how to get rid of it or WHAT might cause it? This happens once in a while, never have figured out why. You can open the image in Paint; erase the line. Or crop it out when you use the image in Publisher. Do you get the line if you save the picture as a .png or .tif? -- Mary Sauer MVP http://msauer.mvps.org/ "Greetings&Salutations" <Greetings&Salutations@discussions.microsoft.com> wrote in messa...

Merge file pairs
I have several hundreds of pairs of files (file1 in one subfolder i paired to file1 in second subfolder) where I need to open the pair copy arange (columns a to e) from one file to the other, then save an close the files. Then loop on to the next pair in the list. Has anyon done this? Can you point me to examples? I've looked at several we sites (debruin, for ex.) but cannot find exactly what I need. Al suggestions welcome -- rroac ----------------------------------------------------------------------- rroach's Profile: http://www.excelforum.com/member.php?action=getinfo&userid=2...

Outlook doesn't open in the inbox work space. Open up in the Outlook today works
How do I make the Inbox as the default workspace in Outlook 2000 corporate mailbox. running on Win xp. ...

in Excel 2000 how do I convert text to numbers?
I imported files from Wells Fargo and I want to convert them from text to numbers...so far nothing is working! thanks Jo Dee One method...... Format all as General. Copy an empty cell(also formatted as General). Select range of numbers. Edit>Paste Special>Add>OK>Esc. One other method......... Select range of numbers and Data>Text to Columns>Finish Gord Dibben Excel MVP On Sun, 27 Feb 2005 11:53:06 -0800, Jo Dee <Jo Dee@discussions.microsoft.com> wrote: >I imported files from Wells Fargo and I want to convert them from text to >numbers...so far nothi...

Can't find the file in Excel unless I open it from Excel
Can't find the file in Excel unless I open it from Excel -------------------------------------------------------------------------- I have a stange problem that has just started. I am running Windows XP and Office XP. If I click on an Excel file in my folders in explorer, it will open Excel and an error message comes up telling me it can't find the file and to check the path and folder. Once I click out of the message the file sometimes is already open. I have no problems if I open Excel first then open a file - it is driving me crazy, please help. Tr...

Huge "empty" excel 97 file !!
I still have files of up to 4MB, after deleting the contents of a 16MB excel 97 file then saving !!! Details:- (1)If I select the whole worksheet (by clicking on the blank cell in the top left corner of the worksheet) (2)then I click on EDIT and then on DELETE. (3)repeat 1&2 for any other sheets (4)Then click on FILE, then SAVE AS a new name Windows explorer shows that the new file can be up to 4MB. This is very frustrating if I am trying to reduce the size a file so that it fits onto a floppy disc. This problem occurs with a number of my excel files. How can I get rid of this invis...

Password to open file
How do you make file only open after you enter a password? dcknie, file save as, tools, general options enter password to open, this is for excel 2003 its a little different in other versions but that should get you there -- Paul B Always backup your data before trying something new Please post any response to the newsgroups so others can benefit from it Feedback on answers is always appreciated! Using Excel 2002 & 2003 "dcknie" <dcknie@discussions.microsoft.com> wrote in message news:D21B2C37-1877-4357-A756-35470C31EDC7@microsoft.com... > How do you make file only...

Append Query 09-13-07
I have and excel spreadsheet I import into a table every week. I wrote this append query to append this table to a datasheet in access. It works except I want to only add the new rows where there is a new router. The impRouter is the key field. It should be in SQL NOT EQUALS TO??? query that appends all the records INSERT INTO _HSIImport ( impArea, impHeadend, impRouter, impDate ) SELECT [Port History9_1_2007].Area, [Port History9_1_2007].Headend, [Port History9_1_2007].[Element Name], ([#date#]) AS Expr1 FROM [Port History9_1_2007]; modified query to add only the new router records...

file
I have an excel file that an employee tried to save and somehow has an error message on it that it will not save because locked by another station. I have done everything from trying to find out who last used it to deleting it and starting over and nothing works. PLEASE HELP amy Maybe Debra Dalgleish has the answer: http://www.contextures.com/xlfaqApp.html#ReadOnly or http://www.contextures.com/xlfaqApp.html#AlreadyOpen amy wrote: > > I have an excel file that an employee tried to save and > somehow has an error message on it that it will not save > because locked by a...

Extremely slow file
I've been doing some ad-hoc analysis at work today and as a quick fix (and because I don't have the Access query skills) I ended up with 2 sheets: Sheet 1 - Contains 21,000 rows of data, 10 columns with the first column being a concatenation of 4 cells from each row Sheets 2 - Contains 10,000 rows with 7 VLOOKUPs in each row, but each vlookup is like the following: =VLOOKUP(A1&$B$1&$C$1&D1,data_range,9,false) Where the data_range is all 21,000 rows x 10 columnsrange in sheet2 Anyway, the file is simply too unwieldy to use. It takes an age to calculate the cells, apply ...

Import and Export files
I currently have Outlook 2002. I brought a new computer and installed the new edition of MS office and use outlook. I exporting a file from the new version, and want to import to my current work outlook 2002. Is there any way to do this, and Outlook 2002 will not reconize the newer version. Any Ideas or help, Thanks New version? which version? David "Gene" <gbarbato@eaglecondev.com> wrote in message news:40c301c3e421$38717840$a101280a@phx.gbl... > I currently have Outlook 2002. > > I brought a new computer and installed the new edition > of MS office and u...

xls file won't open
I have an Excel file which I'm no longer able to open as the system comes back with a message saying 'Not enough memory' The file size is 887kb, I think it was created in Excel 2000 with Win98, but may have been on a machine running XP Home when the problem occurred. I am able to open much larger files without problems, I have also tried opening it on several other machines which have XP Home and Pro, obviously these have newer versions of Excel. Has anyone got any ideas how I can recover my information please? Any help will be appreciated, and thanks in advance for any help yo...

Microsoft Word 2010 Beta doesnt recognise old word files immediate
I have just installed MS Word 2010 beta. Unfortunately, existing word documents created in MS Word 2002 are not immediately recognised by MS 2010. If I first open 2010 and go to file loaction the docs will open fine. However , if i double click on a pre-existing word doc it does not know what programme to use to open it. I have tried finding the winword file to open it but get this message... ".doc is not a valid Win32 application" Is there anyway to solve this issue as it is really inconvenient to have to open Word 2010 each time and manually find the location of ...