+ Reply to Thread
Results 1 to 6 of 6

VBA to copy formulas in column

  1. #1
    Registered User
    Join Date
    12-03-2013
    Location
    US
    MS-Off Ver
    Excel 2007
    Posts
    63

    VBA to copy formulas in column

    Dear Friends,

    I have formulas from Colum B: BD. These formula start from B6:BD6.

    I need to create a button in the sheet so that it copies the formula in row B6:BD6 to all the row till B5000:BD5000.

    Kindly help me with the code.

  2. #2
    Forum Expert Logit's Avatar
    Join Date
    12-23-2012
    Location
    North Carolina
    MS-Off Ver
    Excel 2019 Professional Plus - 2007 Enterprise
    Posts
    7,014

    Re: VBA to copy formulas in column

    .
    Please Login or Register  to view this content.

  3. #3
    Registered User
    Join Date
    12-03-2013
    Location
    US
    MS-Off Ver
    Excel 2007
    Posts
    63

    Re: VBA to copy formulas in column

    Hi Logit, thanks for the code.

    The code is working and giving the desired result in unprotected sheet. But if I protect the sheet, the code is not working. Please advice how to make the code work in protected sheet.

  4. #4
    Forum Expert Logit's Avatar
    Join Date
    12-23-2012
    Location
    North Carolina
    MS-Off Ver
    Excel 2019 Professional Plus - 2007 Enterprise
    Posts
    7,014

    Re: VBA to copy formulas in column

    .
    You will need to temporarily 'unprotect' the sheet ... perform your actions ... then protect the sheet again.

  5. #5
    Registered User
    Join Date
    12-03-2013
    Location
    US
    MS-Off Ver
    Excel 2007
    Posts
    63

    Re: VBA to copy formulas in column

    The sheet is developed for other users. It need to be protected before I email them. Cannot even share password with them. So kindly suggest any alternate solution, if possible.

    Thanks Again.

  6. #6
    Forum Expert Logit's Avatar
    Join Date
    12-23-2012
    Location
    North Carolina
    MS-Off Ver
    Excel 2019 Professional Plus - 2007 Enterprise
    Posts
    7,014

    Re: VBA to copy formulas in column

    .
    I am not familiar with any other method. Perhaps someone else has a suggestion.

    Here are a couple of points ... the macro takes well less than one second to fill the sheet. Here is a modified version of the
    macro you can run there to obtain the same results :

    Please Login or Register  to view this content.
    Less than a second is not sufficient time for anyone to do anything. Were someone desirous of breaking into
    the code and / or modifying the formulas, having the sheet in protected status is not going to hinder them.
    Excel has long been well known for its lack of security. The built-in password measures are so weak as to render
    them truly useless. Only the absolute 'straight and narrow / purer than white snow' person is affected by the
    built-in security measures. The Internet is laden with numerous methods of circumventing all of the security
    measures contained within Excel ... as well as commercial add-ons that purport to provide a higher level of
    security.

    Having said that, I understand it may be a company policy that everything is to be password protected. And that
    is fine .... but, it won't keep the interested party from getting what they want.

    I wish I had an answer for you as I understand your desire to protect the workbook.

+ 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. Macro to copy formulas and formatting down one column
    By MrChrisP in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 12-12-2018, 09:50 AM
  2. Copy formulas from one column to next column based on Current & Prior Month
    By balston2 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 11-29-2018, 08:59 PM
  3. Copy a column worth of formulas and text
    By shannydaw in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 04-04-2013, 04:19 PM
  4. Copy several formulas to the right and only changing the column letter
    By tiggi in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 03-27-2013, 10:17 PM
  5. Vba - find next empty column, insert column, copy paste values & copy paste formulas
    By DoodlesMama in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 12-20-2012, 12:43 PM
  6. VBA to copy formulas in column D and paste as values in same column
    By maacmaac in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 01-10-2012, 05:18 AM
  7. copy/paste column remove formulas
    By sugargenius in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 07-18-2006, 06:55 PM

Tags for this Thread

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