+ Reply to Thread
Results 1 to 5 of 5

Need a vba to save anytime sheet changes at all

Hybrid View

  1. #1
    Forum Contributor
    Join Date
    04-18-2013
    Location
    utah
    MS-Off Ver
    2010
    Posts
    668

    Need a vba to save anytime sheet changes at all

    I need a vba for the below sheet to save anytime the sheet is updated or changes in anyway. I thought I had one but its not working

    Picking log-Rev6.xlsm

  2. #2
    Forum Expert
    Join Date
    11-28-2012
    Location
    Guatemala
    MS-Off Ver
    Excel 2010
    Posts
    2,394

    Re: Need a vba to save anytime sheet changes at all

    I tried and modified a cell at random. it called the sub but D1 in picking log is blank so it fails how or when is cell d1 fill?

  3. #3
    Forum Contributor
    Join Date
    04-18-2013
    Location
    utah
    MS-Off Ver
    2010
    Posts
    668

    Re: Need a vba to save anytime sheet changes at all

    D1 is filled at start of work it is the batch number. need to save as cell D1 anytime sheet is changed.

  4. #4
    Registered User
    Join Date
    01-07-2014
    Location
    United States
    MS-Off Ver
    Excel 2013
    Posts
    24

    Re: Need a vba to save anytime sheet changes at all

    Try modifying the top part of the code to
    Private Sub Worksheet_Change(ByVal Target As Range)
    
    Dim txtLocation As String
    Dim txtExtension As String
    Dim txtFileName As String
    Dim response As Integer
    Dim batchnum As String
    
    batchnum = Range("D1").Value
    'Set Target = Range("D1")
    txtLocation = "D:\picking logs\"         'Change this to the location for the files always with a \ at end
    txtExtension = ".xls"      'The extention for the file
    txtFileName = txtLocation & "Batch " & batchnum & txtExtension

  5. #5
    Forum Contributor
    Join Date
    04-18-2013
    Location
    utah
    MS-Off Ver
    2010
    Posts
    668

    Re: Need a vba to save anytime sheet changes at all

    still not saving as D1 every time batch is updated.

+ 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. Automatically stamp date anytime a cell value changes
    By omarshafi15 in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 11-13-2013, 03:18 PM
  2. [SOLVED] VBA code that will save anytime sheet is updated and..
    By superchew in forum Excel Programming / VBA / Macros
    Replies: 12
    Last Post: 09-09-2013, 01:14 AM
  3. [SOLVED] VBA to save active sheet as new file with save as option
    By Gti182 in forum Excel Programming / VBA / Macros
    Replies: 10
    Last Post: 08-14-2013, 10:54 AM
  4. Replies: 1
    Last Post: 01-25-2011, 10:50 PM
  5. Replies: 4
    Last Post: 08-16-2010, 09:54 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