Updating Local Excel File Through The Internet?

Apr 14, 2014

30 people in different countries use a sophisticated VBA Excel file on their local PCs, let's call it myexcelfile.xls. This file contains no custom data, as all data is stored in myexcelfile_backup.xls.

The biggest challenge with this set up is that whenever there is a newer release or bugfix of myexcelfile.xls, I need to send it out per email to 30 people and hope they replace it with my updated version.

Note that newer versions can replace older versions without any data loss, as all data is stored in the backup file.

Idea: with tools like WGET or BITSADMIN, I was thinking of creating a batch file, that would simply download the latest version from a FTP server, and replace the older version with the newly downloaded one.

Constraints: I shouldn't be using any software that is not native to Windows 7the files can sit in different folders on these 30 computers, therefore the update mechanism would have to identify the path they are in.the update mechanism would have to close the file first before running the update. Question: What is the best way to go about this? A DOS Batch file? Or another excel file that is just the "updater", meaning, it's only purpose is to download the new file from the web and overwrite the old file?

View 1 Replies


ADVERTISEMENT

Not Able To Open Excel File Downloaded From Internet / Mail

Jun 27, 2013

I am not able to open any excel file which comes as attachment with mail.It shows the message "file is corrupt ".

However , once it is open from other computer, I can view the same in LAN system.

View 2 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

Updating Access Database With Excel File

Jan 24, 2014

I've been trying to make this work for hours and hours and am finally giving up. Most of this code was found on the internet and I've attempted to make it work for my project but I keep getting errors. I use VBA with Excel quite often but never with Access before. Currently I am getting an "Object doesn't support this property or method" error at rs.Findfirst.

I have an excel worksheet that mimics the access table with five fields, an ID field, lastName, FirstName, DeptID (int), Email. I want to search the Access table for a match on the email field, and if it doesn't find the match, to add a new record using values typed into the excel sheet.

Code:
Sub UpdateDB()
Dim cn As Object
Dim rs As Object

[Code]....

View 2 Replies View Related

Download And Save Picture From Url Into Local File

Jan 28, 2010

I have a program operating in excel 2007 that extracts a picture from a URL and puts it into a PPT slide. I now discover that PPT 2007 doesn't allow this.

So my intent now is to download the jpg into a local file and then import into the PPT.

This is from a couple of sites:
[url]
[url]

At the top of the code:

Option Explicit

Private Declare Function URLDownloadToFile Lib "urlmon" Alias "URLDownloadToFileA" _
(ByVal pCaller As Long, _
ByVal szURL As String, _
ByVal szFileName As String, _
ByVal dwReserved As Long, _
ByVal lpfnCB As Long) As Long

in the excel cell if a URL picture needs to be inserted it starts with the prefix "picture=" then the http address.

This did not work.

So I then copied the code from the websites into a module (changing the destination file and URL to mine of course) and called the procedure and still nothing.

View 7 Replies View Related

Open URL Or Local Html File With Command Button?

Jan 16, 2010

What is the code to open a URL or local html file with a command button?

View 4 Replies View Related

Send A File By Email Versus To A Local Desktop

Jul 13, 2007


Case "TD"
strfilename = "\TomsblackibmTomsProposals" & strfilename

I would like to send this file by email if possible instead of to his computer. The user recently went from a desktop "in the office" to a laptop "all over the place".

Sub Save_and_SaveSalesman()


Dim strPath As String, strPath2 As String, CurrPath As String

Dim WB1 As Workbook
Dim WB2 As Workbook

Set WB1 = ActiveWorkbook

'First thing, save my work
WB1.Save

CurrPath = WB1.Path

'ASSUMING THAT C6 and O3 are BOTH in WB1
'move this line HERE: only do this once, and concatenate in the Select..Case later
'doing thsi inside the Select..Case pulls values from WB2, which might cause errors.............................

View 9 Replies View Related

Dynamic Hyperlink To File Names Found On Local Drive?

Mar 31, 2014

I want to list file names from a directory and sub directories and hyperlink them. I have been able to list the file names onto an excel sheet, but I cannot get it to hyperlink to the file.

'Force the explicit delcaration of variables
Option Explicit
Sub ListFiles()

[Code]....

View 1 Replies View Related

Works As A File Errors In Internet Explorer?

Mar 28, 2012

I have some code I'm running that works flawlessly when running it in excel. The problem arises when the generic user opens the file via a website I have running, if they chose to run the file in internet explorer rather than saving the file I get the following error:

runtime '1004' error
application-defined or object-defined error

The problem occurs in this code:

Code:
If Not Intersect(Target, Range("B2")) Is Nothing Then
Load UserForm1
UserForm1.Show vbModeless

[Code]....

I have similar code for refreshing specific pages with the "RefreshAll" being changed to "RefreshTower1" for example and I run into the same error.

View 1 Replies View Related

Visual Basic Code - Open Local PDF At Specific Anchor From Excel?

Aug 8, 2012

I want to create a series of hyperlinks in excel to pdf's stored on a local drive/CD as a kind of database. This much I can do with a nifty bit of code I saw someone put up here as follows;

Sub Run_Local_PDF()
MyPath = "C:Program FilesAdobeReader 9.0ReaderAcroRd32.exe"
myFile = "C:Documents and SettingsmynameDesktoppdffilename.pdf"
Shell MyPath & " " & myFile, vbNormalFocus
End Sub

Which works great and is sitting snug in a module. However, the document I am linking to has various anchors in it which exisit as sectionheaders. One of which is "Contents".

Is there a quick way I can alter my exisitng VB code to open at one of these anchors?

View 2 Replies View Related

Download Zip File From Internet Explorer And Save It Into C Drive Using VBA Codes

May 21, 2014

How to download the zip file from internet explorer and save it into c: using VBA codes.

I have tried many codes from the internet but none of them are working. i am facing problem for the popup box. the macro which i have found was not supporting to it.

Please find the source data from my web page.

[Code] ....

View 3 Replies View Related

Can Retrieve Data From Internet Using Excel / VBA

Oct 27, 2012

I have a list of zip codes in excel, which I need to pass to store website and retrieve all the store locations in that area..

For example:

[URL] .... "choose my store on the left"

or [URL] ....

Is it possible to do this in Excel/ VBA?

View 3 Replies View Related

Publish Excel To Internet Web Page

Feb 3, 2010

I have this spreadsheet that I use regularly and that others also view (not edit) and to facilitate viewing, I would like it to go on the net.

Ideally, simple editing would be done from within the browser.

View 5 Replies View Related

Excel VBA Automation For Internet Explorer To Website

Feb 26, 2013

I have been trying for some time to be able to download a file from what I believe to be a FTP site. There are three user input fields which I have been able to identify there names. After these fields are complete there is a button to push which I have also identified it's name.

Once the process of pushing this button is done, an unspecified amount of time must occur for data to be gathered and the option of Open, Save, or Canel appear in a Download window. I would then need to Save and Overwrite an existing file.

No Login or Password is required.

I have been able to automate the open of I.E. and input to the three select fields as well as the necessary button push.

However, I am unable to identify how to automatically save the file into a specified location, with overwrite privileges enabled. Below is my progress

View 9 Replies View Related

Excel 2007 :: Linking Cell To Part Of A Table On Internet

Apr 26, 2014

I am using Excel 2007. A few years ago I managed to link a spreadsheet to a particular part of a website. To be specific, I linked a cell to a portion of a table on a website showing the current average price of petrol in the U.K. I also linked a cell to a website which showed the current exchange rate for pounds and dollars. I haven't been able to replicate the procedure.

View 3 Replies View Related

Mailing Address Pasted From Internet To Excel And Then Mail Merge With Word?

Jul 26, 2013

I'm trying to use Word mail merge with Excel to create mail labels and letters for each person on the list. For example,

Johnson, Michael
7391 Wilson Street
Van Nuys, CA 91405

I want to create a mailing label for this person. If possible, I'd like to make the top line of the address "Dr. Michael Johnson," however the format that I'm copying from is last name, first name. And I also want to want to create a letter that starts with "Dear Dr. Last name," such as "Dear Dr. Johnson." This is the website that I want to copy the addresses from:

Doctors in Los Angeles, CA | Primary Care Physicians and Specialists

I have done my homework, but I don't know how to properly paste the addresses into Excel and then use Word to create the labels and letter. I have tried many ways, but I have been unsuccessful.

View 1 Replies View Related

Excel 2010 :: Hyperlinks With JPG Files Using Internet Explorer Do Not Show Pictures On Win7

Jan 26, 2013

In Excel 2007, Hyperlinks in cells pointing to jpg files in a subfolder display with internet explorer. On my WinXP/Intnernet Explorer 8/Office 2007 system these links work fine.

When sending the excel and jpg files to another person with Win7/Office 10, jpg hyperlinks work and launch Internet Explorer but come up blank. (Hyperlinks to PDF files work fine and show up in Acrobat, just the jpg's come up blank in Explorer.)

Questions:
What is causing this, a setting in Explorer/Win7 or Excel?
Can I change Excel hyperlink default software to use something other than Explorer to display the jpg files?

View 5 Replies View Related

Updating Worksheet Data From New CSV File?

Dec 14, 2011

I keep track of returns for my company and I am pulling a CSV file with all of the information on it.

I want to be able to format the info and create new columns for info I enter in to the sheet, and be able to import the updated CSV file into my already formatted sheet.

The part that I am wondering about is, after I import my first CSV file(sheet1) do I need to create another sheet(sheet2) and format sheet2 and have it pull the info from sheet1, then when I update workbook1 the data will update in sheet2?

Or, is there a way to just import the new data a single formatted sheet that I created from the old data and have it just add the new data without messing up any of my formatting?

View 2 Replies View Related

File Path Function Not Updating

Mar 1, 2013

I created a simple custom function called File_Path() using this macro line:

File_Path = ThisWorkbook.Path

I use the function in Cell A1 and it displays the path, but it doesn't automatically update when I change the path. I have to use F2 to get it to update. I have automatic calculation on.

View 6 Replies View Related

Error When Updating Chart From Imported File Data

Oct 4, 2013

I've created a spreadsheet which, on running a macro, imports data from a text file, formats it and then sums various parts of it giving me a subset of the large file as a range of data for a chart (a pie chart) on Sheet 2.

The problem begins when I delete the data in the worksheet in preparation for another import - the Pie chart just loses all the data and I have to manually reselect it in the chart each time.

Once deleted the chart is blank, but as soon as the data is imported, I get reference errors when I click on Sheet 2

I must be doing something wrong. You can delete data and repopulate it and the chart should pick up with the new data. If the cells it is referencing are empty, it is blank. Not so here.

Is it to do with importing the data? Or the formula for my chart data?

View 1 Replies View Related

Updating OLE Linked Objects From Excel

Mar 6, 2012

I have 2 excel workbooks - each containing one table.I have 1 Powerpoint Prtesentation with OLE Links to the 2 tables.

All I want is for any update in the excel tables to show in the running PP Presentation. The annoying part is when I set up the linked objects, everything works perfectly and any changes in the excel files update real time in the PP presentation.

As soon as I close the excel file and reopen though, from thereon in I have to update the links manually.

Things I have tried:

A PP Add in called "Update Links" which updated the OLE links on every rotaion of the show. This would be a fine workaround if it didn't stop the slideshow if/whenever someone was updating one of the source files with the "file is already open..." message...So set both source files to shared as PP will only be reading the data anyway. Still the error appears.Inserting some code into PP:

Code:

Sub linkupdate() Dim osld As Slide Dim oshp As Shape For Each osld In ActivePresentation.Slides For Each oshp In osld.Shapes If oshp.Type = msoLinkedOLEObject Then oshp.LinkFormat.Update Next oshp Next osld End Sub

All I want to do is update the links without stopping the slideshow. I have tried numerous PP approaches, but maybe there is an Excel solution that will update links automatically on each save.

View 1 Replies View Related

Updating Access Record Via Excel VBA

May 24, 2012

I currently use a function very similar to this one with a SELECT query to return a field to excel. I have modified this into an UPDATE query to update a field.

I am getting errors at this point:

Code:
If adoRS.BOF And adoRS.EOF Then
DBNoteUpdate = "Value not Found"
Else
DBNoteUpdate = "Action Confirmation"

I believe this area of code was to trap the error that occurs when the lookup field name was not found in the table. I left it in because I still want to trap if the record I am trying to update is not found in the table.

Here is the full code:

Code:
Public Function DBNoteUpdate(RecordNumber As String, _
UpdateTableName As String, _
UpdateNote As String) As Variant
Dim adoRS As ADODB.Recordset
If adoCN Is Nothing Then SetUpConnection

[code].....

The code does work, in that the record is being sucessfully updated by the SQL statement, but its erroring at the point I described above with the error:

Code:
Runtime Error '3704':
Operation is not allowed when the object is closed.

how 'adoRS' is closed at that point because the call to close is right at the end of the function?

View 8 Replies View Related

Updating Closed Excel Sheet

Jun 26, 2012

I have two Excel sheets (test-excel-1.xlsx & test-excel-2.xls)The test-excel-2.xls will never be opened. When I update cells in test-excel-1.xlsx and save, I want them to automatically update to the test-excel-2.xls without having to open it. I have tried the "='[test-excel-1.xlsx]Sheet1'!$G$4" but that needs me to open test-excel-2.xlsI also want original values to be pasted in test-excel-2.xls rather than the code (this is later used in another program).

View 6 Replies View Related

Save Excel File As Another File Using Current Date As Part Of File Name

Oct 10, 2011

VBA coding for automatically saving an excel file as another file using the current date as part of the file name together with "32ga" as a constant add-in. I also what this macro to run at a particular time of the day let say 00:20hrs. The excel file i want to save as is always open . It has data that changes every 24-hrs.

View 1 Replies View Related

Excel 2007 :: Updating Access Using SQL In Macro

Mar 29, 2012

I have a CSV that I have a excel macro created to do some formatting and then export the data into Access. that part works. I also have it checking for duplicate entries and skipping them. The problem that i run into is that not all my duplicates are truly duplicate, there have been updates and now i need to update Access. I have 2 fields, my primary key which is what I'm primarily matching on and then I'm checking if its been updated by checking another field "Last Changed" If this field doesn't match then I need to update the record.

At this point I'm trying to use a SQL UPDATE and I now believe that i have it formatted correct but when it gets to a record that needs to be updated I get an error: Run-time error '-2147217887 (80040e21)': The changes you requested to the table were not successful because they would create duplicate values in the index, primary key or relationship. I'm not sure what I'm doing wrong. the only other thing i could think to do would be to check each field to see if it has changed and just run the query against that but I feel like i would run into the same issue.
This is how I'm connecting to Access:

Code:
strTableName = "TableName"
strDBLocation = "xxxxuserhomexxxxxxxxxxxxDatabaseDatabase Backend.accdb"
strConnect = "Provider=Microsoft.ACE.OLEDB.12.0; Data Source=" & strDBLocation & ";"

Set cn = New ADODB.Connection
cn.Open strConnect
Set rs = New ADODB.Recordset
rs.Open strTableName, cn, adOpenKeyset, adLockOptimistic, adCmdTable
And this is the Query I'm using:

Code:
strSQL = "UPDATE " & strTableName & " "
strSQL = strSQL & "SET [Work Order ID] = '" & Range("B" & r).Value & "', "
strSQL = strSQL & "[JOBSTATUS] = '" & Range("C" & r).Value & "', "
strSQL = strSQL & "[SUBSTATUS] = '" & Range("D" & r).Value & "', "
strSQL = strSQL & "[Job Status] = '" & Range("E" & r).Value & "', "
strSQL = strSQL & "[STATUSDATETIME] = #" & Range("F" & r).Value & "#, "

[Code] ..........

The SQL code sits in a loop with an IF so it shouldn't execute every time and I plan on once i get this working to revisit this code and try to optimize it but that is not a priority currently.

I'm using both Excel 2007 and Access 2007 on XP.

View 7 Replies View Related

Updating Excel Table Values Into SAP Tables

Jul 23, 2012

I want to write a interface program using VB Macro, for updating the Excel Table values into SAP Tables. Is there any macro that can do this work?

View 4 Replies View Related

Excel 2010 :: Updating Linked Cell

Aug 14, 2012

I am using the Format as Table feature in 2010 and I am summing a range of cells (C2, D2 and E2) with the result in F2. I have linked F2 three rows below the table in cell C5.

When I add new data in the 3rd row in the table feature I can get an updated result in F3 but my linked cell does not update as it is now pushed to cell C6.

How can I have the linked cell update with the new total from cell F3 as it moves relative to the table?

View 1 Replies View Related

Excel 2002 :: Updating Separate Sheets

Oct 8, 2012

I've got Excel 2002. I am devising a sheet for checking work (sheet A) which feeds onto a separate sheet (sheet B). If I wanted to delete info from sheet A can I retain the info on sheet B? I want sheet A to be used repeatedly for each case but the info for every case to be recorded row by row on sheet B.

View 4 Replies View Related

Excel 2010 :: Updating Scores For Each Parameter

Apr 5, 2013

I have below format in excel and i will be updating scores for each parameter (column B).

I will be inserting a command/click button and when i click on the button macro should take the name, contact No., scores from column B and paste it in sheet 2 in the same workbook in one row, in the same way when I click the button the scores should be taken from sheet 1 column b and paste one below other row in sheet 2 each time i click on button.

Below is how raw data looks like.

Column A
Column B

Name:
ABC

Contact Number:
XYZ

Parameter
Score

[Code] ..........

Output expected in sheet 2 is as below.

Name:
Contact Number:
Parameter A
Parameter B
Parameter C
Parameter D
Total Score

ABC
XYZ
2
5
6
7
5

I am using Excel 2010.

View 5 Replies View Related

Excel 2007 :: Updating Cell Value On Table Through VBA?

Oct 27, 2013

I'm currently using Excel 2007 to get information from closed workbooks and updating my file.

First of all I create a table on selected range through "Insert table" command having something like this:

Then I have I piece of VBA code that tries to update every single cell of a column in this case it's updating %LD10 column:

But like you can see in first capture, the code updates every single cell with last value of variable fichero, having, at the end, the same value in whole column.

View 4 Replies View Related







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