Excel 2003 :: VBA To Unzip And Download Files

Nov 7, 2011

I have code with downloads files from our work intranet site. When the files download the are zipped up. Is there a code which will unzip and open these excel files?

I'm using Excel 2003.

View 2 Replies


ADVERTISEMENT

Unzip Zip Files

Aug 21, 2005

Is there a way from excel that i could unzip files then rename those files and then rezip these files to the original zip file using a macro?

View 9 Replies View Related

Unzip Then Delete Or Overwrite Files

Aug 21, 2010

I've struggled to find the code to unzip files using VBA but I finally found it and it works (using Shell).

The problem is that I want to unzip all zip files in a folder but my zip files contain 3 files:

1 csv file that I want to keep and 1 xml and 1 txt file that I want to delete.

I can't just unzip everything and deal with the txt and xml later because the xml and txt files all have the same name. So if I don't do anything, I have a series of overwriting messages prompting me to click yes or no. So what I want is either to delete xml and txt one by one after they are created or get rid of the overwriting prompt. I've tried to put a kill or delete file just after the unzip command but it doesn't work - it's telling me that the txt file doesn't exist (should I add some sort of refreshing command ?) and I couldn't find anything on google about overwriting text or xml files.

View 5 Replies View Related

Zip Unzip Files Without 3rd Party Zip Program

Dec 7, 2007

Does anyone have a way to make Excel Zip and/or Unzip Files using only Windows Native Functionality?

I know I can use command line zip utilities like Winzip or Winrar. But I'm trying to make some scripts that will be shared among other users, and would like to NOT require users to install extra software to make it work.

I know windows has the built in capability to zip unzip files through the windows GUI, so there must be a way to do it with command lines from VBA code...

P.S. At the moment I am mostly concerned with UNzipping.

View 9 Replies View Related

Unzip Winrar Files Using VBA Code

Jul 7, 2006

I'm using:- Open "file name" For Input As #1 to read and manipulate files. However, I've hit a problem with how to open and read zipped files (winrar).

View 3 Replies View Related

Excel 2003 :: Error Message When Trying To Open XLS Files?

Oct 20, 2013

I'm using 2003 (I know!) version & I can't open excel files directly by clicking on them. I get an "error in sending command" message. I can circumvent problem by opening Excel & then opening the relevant file, but this sometimes causes me problems.

View 4 Replies View Related

Using Sendkeys And Loop To Download Files

Jul 7, 2012

I have created some code that directs me to a web page, and i use send keys to navigate my way to the input field. In this input field I am trying to put a cell value in a range use send keys to download the file, and the repeat the process for the next cell.

Here is my code so far, it does everything right up until pasting the copied cell into the input section of the web page - the issue is it is pasting nothing

VB:
Shell "C:Program FilesMozilla Firefoxfirefox.exe " & "https://website.com", vbMaximizedFocus
Application.Wait Now + TimeValue("00:00:05")
SendKeys "{TAB}"
' Input username

[Code] .....

View 9 Replies View Related

Excel 2003 :: Saving Files Generated By External Application

Jul 23, 2013

I have the following code which edits an excel file and saves it in a different format, I think want the code to take this newly saved file and open it in an external application (Softplot) and then save it through this new application.

VB:
Sub FormatMacro1a(ws As Worksheet)
ws.Copy
Rows(1).Delete
Columns("D:E").Cut Destination:=Columns("J:K")
Columns("F:K").Cut Destination:=Columns("D:I")
Range("E1:E201").Value = "0"

[Code] .....

As it stands I have the file saving in a new format and I can open a specific file in softplot through VBA however where I am getting stuck is opening my newly saved file and then saving it.

I have tried the following :

VB:
Path = "C:Program FilesSoftPlot-8softplot.exe"
File = "ActiveWorkbook"

View 3 Replies View Related

Excel 2003 :: Printing Multiple Files With Explorer But Asks To Save Changes?

Dec 7, 2012

When selecting multiple excel files in explorer, you can right click and choose to print the selected documents. All documents gets opened and printed but the files stay open and you have to manually click on YES or NO to save the changes.

Is there a way not to see this window appear. So documents get opened and printed and closes itself without asking anything. Maybe it can be done with an option in the preferences. I'm not sure.

By the way the documents where created with excel vba just in case it's relevant. Also the version of Excel is an older version, I think it was Excel XP or 2002/2003.

View 1 Replies View Related

Excel 2003 :: Copy And Move Files To Create Backups For 7 Or 8 Years

Aug 30, 2012

Using Excel Office 2003.

I have been using VBA to copy and move files to create backups for 7 or 8 years now, and it works great. However, recently I have been working on a way to use SD cards for the backups and the FileCopy command is much slower than using Windows Explorer.

I am looking for some alternate command lines that might do the job faster. I would like to know what Explorer is using.

View 8 Replies View Related

Excel 2003 :: Deleting Rows For Multiple Files In Separate Workbook

Sep 10, 2012

I'm new to this forum and to VBA

First-off, I'm using Excel 2003 SP3.

The setup: A software application I regularly use produces csv data files (in this case approx 300 files). These I have converted to xls format using a separate macro. The files are in one folder and named as follows eg

G1 18800.xls
G1 18802.xls
G2 18975.xls
G3 19881.xls
G3 19990.xls
G5 19990.xls
etc

The files contain the following data:

DATE TIME VALUE STEPS EXCL ACCEL
01-Oct-03 08:00 0 0 FALSE 0
01-Oct-03 08:01 0 0 FALSE 0
01-Oct-03 08:02 0 0 FALSE 0
01-Oct-03 08:03 0 0 FALSE 0
01-Oct-03 08:04 757 20 FALSE 0.18
01-Oct-03 08:05 1714 32 FALSE 0.44
01-Oct-03 08:06 1524 32 FALSE 0.39
01-Oct-03 08:07 1665 45 FALSE 0.47
01-Oct-03 08:08 1644 42 FALSE 0.46
01-Oct-03 08:09 263 8 FALSE 0.06
etc

I then created a macro using code I sourced from the internet, and included some addtional commands (filename, copy/paste). See below. This macro opens the all the xls data files in the folder and copies the relevant data to an analysis workbook [Analysis sheet, Results sheet, Master sheet] ie the data is copied from the data file and pasted into the Analysis worksheet. Then the results are copied from the Results sheet to the Master sheet. So far so everything works.

My problem is this: I'm stumped at how to delete rows from the xls data files before running the analysis workbook and macro. In other words, after converting the csv files to xls format I need to clean the xls data files.

I have a separate xls file with criteria data in two columns:

FileName Date
G1 18800 06-Oct-03
G1 18801 02-Oct-03
G1 18801 03-Oct-03
G1 18801 05-Oct-03
G2 18795 14-Oct-03
G2 18795 15-Oct-03
G2 18795 16-Oct-03
G2 18795 17-Oct-03
etc

The rows in a particular data file, with dates that are not present in the Criteria workbook must be deleted. This to be done for every data file in the folder. Also, I need to exclude rows for specific time periods eg 12H00AM - 04H00AM from all the files irrespective of date.

the code needed [should a separate macro be run or can code be placed within the present macro?]. I've tried looking for something similar on the internet, but my requirements seem too customized to be able to adapt the code that I found. And of course this is waaaay above my present skill level!

Option Explicit

Sub CopyPaste()

'This code opens up data files (xls) in a specified folder and copies data A1:G17281 to an Analysis workbook (Analysis sheet).

'The data from the Results sheet is then copied to the Master sheet.

Dim wkbDest As Workbook
Dim wksDest As Worksheet
Dim wkbSource As Workbook
Dim wksSource As Worksheet
Dim MyPath As String
Dim MyFile As String

[Code]...

View 9 Replies View Related

Opening 2003 Files From Word 2003

Jan 8, 2010

how to write a code where i can open Excel2003 file from Word2003 and delete data from Sheet1 and then close the excel2003.

All this is done from Word file.

View 9 Replies View Related

Excel 2003 :: Extract Variable Rows Of Cells From Files In A Folder To Existing File In Folder

Mar 15, 2013

I need a macro in a workbook to look at all the files in the same folder that have "*att*.xls" in the name and determine and copy from the range A15:W515 only the rows that have data in at least columns A, C and D. Each file will vary as to how many rows there will be and there are more than the files with "*att*.xls" in the folder. The data will be on the only worksheet in each file and the worksheet is named "G2WAttendee_xls" the data from all the files need to be copied to the file called "Consolidated webinar reports.xls" (I am using Excel 2003) and to a sheet called "Attendance Data" and added to the end of the last paste.

At the start of the macro the current file "Consolidated webinar report.xls" should be saved to a sub folder of the current directory and have the date saved added to the name. The sub folder is called "Completed reports". The data in the original file on worksheet "Attendance Data" should be deleted.

At the end of the process all the files that have had data copied from them should be moved to the sub folder "Attendance reports consolidated" (This could be done as each file is closed if that is easier).

I have headings in row 1 of the "Attendance Data" worksheet that match the headings in the various files in the folder (which will always be in row 14 of the individual "*att*.xls" files).

The folder with all the files and the "Consolidated webinar report.xls" file is at path "Z:P and S MEvaluationsWebinar series 2012-13TB".

View 9 Replies View Related

Download Data From SAP To Excel?

Dec 7, 2006

how to download data from SAP to excel?

View 8 Replies View Related

How To Download Pictures From Excel

May 16, 2012

I know how to insert pictures into Excel, but how do I download them from Excel into my computer.

View 1 Replies View Related

Download Images From URLs In Excel File?

May 12, 2014

I have an excel file which contains 9 columns. Column A contains an article number i.e 12345 . Column B contains name of the product. Columns C and D contain Description and Specifications respectively. Columns E,F,G,H and I contain URL:s of images.

I want to do following.

1. Download all the images in a folder on my harddisk.

2. Copy the text in column C and place it under the text in column D.

note that I am a novice at excel and have never used macros/Javascript/VBA/etc

View 2 Replies View Related

Excel Macro And Download Dialog Box In IE11

Apr 19, 2014

Back in IE8, when you tried to download a file, it'd pop up a little box asking if you wanted to download or save the file. Macros in Excel could work through it using code like 'hWnd = FindWindow("#32770", "File Download")' to get the box and interact with it.

IE11 now has an obnoxious little ribbon that appears at the bottom of the window instead of the box, so FindWindow comes up blank.

There are a number of files including .xls, xlsx, and .csv, and there isn't a static link directly to the files, so I can't just put the link in workbooks.open. Also, to get some of the files, there are logins and forms to fill in with dates and the like. I can get through all of that stuff and click the button to download, but it's that open/close button that's stumped me.

Any way to get an Excel macro to interact with that Open/Save ribbon in IE11?

View 1 Replies View Related

VBA - Download Excel File From Internet And Then Extract Data Out Of It

Dec 20, 2012

I'm trying to download an Excel file from the internet and then extract data out of it. The problem is that I don't get any errors, yet the file downloaded is only 1kb in size. The extraction bit works, but the file is empty. The actual file is size 350KB.

Code:
Sub ExtractDataTest()

Dim FileNum As Long
Dim FileData() As Byte
Dim MyFile As String
Dim WHTTP As Object

On Error Resume Next

[Code] ....

View 1 Replies View Related

VBA - Get / Download Excel File From Server And Copy Contents Into New Worksheet

Dec 20, 2012

For some reason the following Macro won't work:

Code:
Sub ExtractDataTest()
Dim FilePath$, Row&, Column&, Address$
'change constants & FilePath below to suit
'***************************************
Const FileName$ = "Dxo.xlsx"
Const SheetName$ = "Open"

[Code] .......

I get a run-time error '52' on line ("Bad file name or number"):

Code:
If Dir(FilePath & FileName) = Empty Then

And when location is 'C:' it works and I don't get an error.

View 2 Replies View Related

Convert Files To 2003 Format

Feb 24, 2009

I've been asked to change a massive batch of Excel 2007 files to 2003 format (to send to a client who doesn't have the newer version). Apart from going into these files (there's over 500 of 'em ), can anyone suggest a means of doing this? I know that Microsoft has a Migration Manager tool, but it appears this only converts the other way around.

View 2 Replies View Related

VBA Automate Unzip With SecureZip

Aug 4, 2012

I'm trying to automate unzipping many .gz files on a monthly basis. Previously I used a macro a coworker wrote to do the unzipping using winzip (think he may have used some code snippets from this forum for it - seems like several sites have similar code shown in different postings). But now my office has switched over to pkware's SecureZIP, I can no longer use winzip, and my coworker has moved on. Can I manipulate that old code to work with SecureZIP somehow?

View 1 Replies View Related

Unzip File Automatically Without Search?

Aug 8, 2014

I have a macro that saves zip files automatically from outlook every day and saves over those zip files (which I want). But now I need to unzip those files and save their csv files in a different folder. I will be saving over the same csv files everyday.

(I have 5 zip files saved and named and each file contains just 1 csv file)

I have had a look at Ron de Bruin's code but he requires you to open the and search for the zip file. I would like this to unzip and save automatically without having to use "Application.Getopen".

View 1 Replies View Related

Convert All CSV Files In A Folder To Excel Files?

Apr 8, 2014

I is it possible to convert all comma separated text files in a single folder in to excel files. But the requirement is to have 2 sheets in each new file. first to be the full file - with all columns, and in the second sheet to keep only colum A B D G H K L M O P R S T V W from the first sheet. The second sheet name must be the same as the first one but without the first "wlist_" in the name.

One more thing. The third column in the second is called "COUL". there are short letters for colors in french

can they be converted with the sort in English like it goes:

NO = B
BA = W
RG = R
SO = P
JA = Y
BE = L
VE = GY
GR = G
VI = V
MA = BR
BJ = TA
OR = O

Here is a link to the both CSV and an example excel file with the end result. In this example i haven`t change the shorts for the colors. It takes me too much time with the find and replace function. And at the moment i`m really pushed from time.

[URL]

View 9 Replies View Related

Excel 2003 :: Copy Hyperlink From Excel To Outlook?

Apr 19, 2010

I have an Excel 2003 file that contains hyperlinks to OneNote notebooks on a Sharepoint site. An Excel macro looks for these links and determines the full hyperlink address which is then assigned to a variable. An Outlook message is generated which includes the hyperlinks.

The hyperlinks work in the Excel file. I can also copy them from OneNote and manually paste them into an Outlook message and they work. However, when I obtain their full address and transfer that to the email through code, the links do not work. The hyperlink address from OneNote starts with "onenote:http" which is not recognized as a link.

If I can do this manually, there must be a way to do this with vba. Are there characters I need to include in the OneNote hyperlink address to make this work? Is there another way to transfer the working link from Excel to Outlook?

View 3 Replies View Related

Adjust Macro From Excel 2003 To Excel 2010?

Apr 1, 2014

I am trying to adjust the below macro so that it will work in Excel 2010.

Sub OpenAndProcess()
Dim fs As FileSearch
Dim I As Integer

[Code]....

View 3 Replies View Related

VBA Open All Text Files In Excel In Folder And Save Them As Excel File

Dec 7, 2013

I have some daily text files in a folder (so about 30 of them each month), which in the end of month, I need to open them up in excel, format them so that I can use the information for my analysis.

I would like to create a macro, to quickly open them all up at once and save them each individually in .xls or .xlsm format.

I am new to VBA and after some research online, I was able to have the files open with the following code. but now I don't know how to proceed further to save them one by one with the same name but in .xls or .xlsm format.

Sub Opentxtfiles()
Dim MyFolder As String
Dim myfile As String

[Code].....

View 2 Replies View Related

Unzip Code - Works Without Variables, Breaks With Variables...

Feb 5, 2009

Unzip Code - Works without Variables, Breaks with Variables.... This has been driving me bananas...

I have the

View 2 Replies View Related

Excel 2003 :: Alt + F11 Key Not Working?

Feb 21, 2012

when I use the above key stoke nothing happens in excel. It won't get me into vba editor??

using Dell laptopInspiron N4010 and office 2003

View 2 Replies View Related

Excel 2003 :: Hiding 0 Using ABS

Mar 27, 2012

I am using the formula ABS(D6-G6) when these cells are empty I get a 0 result, how can I get rid of this?

Using 2003

View 6 Replies View Related

Excel 2003 :: Group And Outline

May 14, 2013

In Excel 2003 I have Manually Grouped a number of rows. (Data>Group and Outline>Group).

If I use the buttons with the numbers 1, 2, 3 (indicating an outlining level) to collapse or expand the outline I receive the Error Message: "Cannot shift objects off sheet."

If I use the collapse button (-) or expand (+) button the data collapses and expands as I would expect.

I am aware of the normal issues surrounding objects and outlining and have ensured that I have changed the properties of all my of the objects in the sheet to "Move and size with cells". There are no comments in the grouped rows.

View 4 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved