+ Reply to Thread
Results 1 to 10 of 10

Insert Rows (randomly), Copy/Paste above's format & formulas, while PROTECTING formulas

  1. #1
    Registered User
    Join Date
    01-13-2014
    Location
    Texarkana, TX
    MS-Off Ver
    Excel 2007
    Posts
    23

    Question Insert Rows (randomly), Copy/Paste above's format & formulas, while PROTECTING formulas

    I have a spreadsheet (multiple documents use same format) that contains formulas in multiple columns (column D, F, G, H, I, etc). These formulas need to be protected from being overwritten/deleted/etc. (unless user has a password).

    The issue I have is I need our numerous users to be able to randomly add rows throughout the spreadsheet so they can add new data (ie: insert a new row at 23, 39, 55, 71, 89, 105, etc. - there isn't a pattern), copy the format and formula from the row above insert (or below if that is easier) while protecting the formulas in the spreadsheet.

    So basically is there a way to protected formulas but allow a user to copy and insert random rows throughout spreadsheet, while continuing to protect the formulas?

  2. #2
    Forum Expert
    Join Date
    11-26-2013
    Location
    Colac, Victoria, Australia
    MS-Off Ver
    Excel 2016
    Posts
    1,309

    Re: Insert Rows (randomly), Copy/Paste above's format & formulas, while PROTECTING formula

    Hi Shannon,

    Not sure what you're trying to achieve, but have you had a look at the options available when you protect the sheet?

    You can see a list under Allow all users of this worksheet to:
    Some of the options are Format Cells and Insert Rows

    Try ticking those options,

    I hope this helps, please let me know!

    Regards,

    David

    Please remember, your request is clearer if you attach a sample workbook.
    - Click on Go Advanced and click on the Paper Clip.

    If this has been of assistance, please advise.
    - Please click on the *Add Reputation button at the bottom of helpful responses.

    Please mark your thread as SOLVED:
    - Click Thread Tools above your first post, select "Mark your thread as Solved".


  3. #3
    Registered User
    Join Date
    01-13-2014
    Location
    Texarkana, TX
    MS-Off Ver
    Excel 2007
    Posts
    23

    Re: Insert Rows (randomly), Copy/Paste above's format & formulas, while PROTECTING formula

    David

    I think I am needing a VBA code that will copy the row above when a user inserts a new row [randomly throughout document]. But also protect the formulas in the rows from being edited [located in random cells in the spreadsheet].

    I just don't know exactly what I need.

    I have tried protecting the cells, but it won't let users copy / paste the row above insert. I am open to letting users manually insert rows [randomly] and then copying and pasting the row above, but the protection won't allow that. I am not sure what I am doing wrong.

  4. #4
    Forum Expert ben_hensel's Avatar
    Join Date
    01-26-2012
    Location
    Northeast USA
    MS-Off Ver
    Office 365
    Posts
    2,043

    Re: Insert Rows (randomly), Copy/Paste above's format & formulas, while PROTECTING formula

    One of the tricks I have is using Data Validation with a Custom Formula ( ="Password" or something like that) set to prevent data entry into the cells. If you have the Data Validation set to a range (eg, D1:D5) and insert a row above row 3, then it will automatically extend the protection, so now D1:D6 with the new D3 is included.

    This doesn't protect against copy/paste at all, only direct manual entry. This will allow users to fill in the cell using dropclicking or with copypasta. I mostly do this as a quick-and-easy way to prevent fat-fingering a data entry over a formula cell, not to actually protect the spreadsheet as such, because it's not really protected, it's error-catching.
    Click the [* Add Reputation] Button to thank people for help!
    Post Attachment: Click [Go Advanced] under the reply box; then click [Manage Attachments] to launch the attachments dialogue.
    Mark Thread Solved: Go to the top of the first post; Select [Thread Tools] dropdown; Pick the [Mark thread as Solved] option.

  5. #5
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,929

    Re: Insert Rows (randomly), Copy/Paste above's format & formulas, while PROTECTING formula

    Why cant they just add the data to the end of the existing list? You could then structure the formulas so they show nothing until something is entered into a specofic cell (date?)
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

  6. #6
    Registered User
    Join Date
    01-13-2014
    Location
    Texarkana, TX
    MS-Off Ver
    Excel 2007
    Posts
    23

    Re: Insert Rows (randomly), Copy/Paste above's format & formulas, while PROTECTING formula

    Quote Originally Posted by FDibbins View Post
    Why cant they just add the data to the end of the existing list? You could then structure the formulas so they show nothing until something is entered into a specofic cell (date?)
    I sure wish it was this easy. The spreadsheet contains multiple entities that are tested and the results have to be entered under each entity with the date and results in the inserted row.
    If there is a way to create a condition that will insert the formulas when the user enters the date in col A, row [insert], then I am all ears, but I am not that fluent in excel.

    ie: user inserts row 23, in cell D23 formula "=c23-b23", in F23 "=d23*e23", in G23 "=$c$8-b23", etc. so I am at an 'stump'ing point on this. and goes without saying that the row no. would change with each inserted row.

  7. #7
    Registered User
    Join Date
    01-13-2014
    Location
    Texarkana, TX
    MS-Off Ver
    Excel 2007
    Posts
    23

    Re: Insert Rows (randomly), Copy/Paste above's format & formulas, while PROTECTING formula

    I am not familiar with Data Validation, but going to review and see if I can utilize the feature

  8. #8
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,929

    Re: Insert Rows (randomly), Copy/Paste above's format & formulas, while PROTECTING formula

    Can you upload a sample of what you are dealing with, as well as some examples of what you would be doung, and what the expected outcome would look like?

    Without entering all data 1-below-the-other, or using VBA, I dont think there is a formula-way to do what you want

  9. #9
    Registered User
    Join Date
    01-13-2014
    Location
    Texarkana, TX
    MS-Off Ver
    Excel 2007
    Posts
    23

    Re: Insert Rows (randomly), Copy/Paste above's format & formulas, while PROTECTING formula

    PROTECT FORMULA - 2042 WL TABLE.xls

    Here is one of the tables in question.

    So a user is going to enter the data we will receive for our December 2015 sampling event. The user will insert a row under the June 2015 data. They should manually enter data in column A, B, C, E with the remaining cells (D,F,G,H,I) having formulas that need to be protected from user manually typing over them.

    I hope this helps.

  10. #10
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,929

    Re: Insert Rows (randomly), Copy/Paste above's format & formulas, while PROTECTING formula

    OK, I think I have an answer for you.

    Convert your range to a table, then, when you insert rows, the formulas get copied for you. Did not test it with protectyed cells though

+ 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. Insert row at the end of data and copy formulas and format painter from the row above.
    By sportynumair in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 07-06-2015, 03:05 PM
  2. Copy paste only the format and formulas not values
    By sudharshan86 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 05-26-2014, 07:53 AM
  3. Command button to add rows, copy and paste formulas, and format.
    By seankuus in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-05-2013, 08:37 PM
  4. Insert rows and copy formulas
    By amlal in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 07-30-2012, 02:53 PM
  5. [SOLVED] auto insert rows and copy formulas
    By shocks24 in forum Excel Formulas & Functions
    Replies: 11
    Last Post: 05-23-2012, 04:19 PM
  6. [SOLVED] Auto Insert Rows and copy formulas
    By shocks24 in forum Excel Formulas & Functions
    Replies: 16
    Last Post: 05-11-2012, 02:50 PM
  7. Copy/Insert rows with formulas
    By GregR in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 04-26-2005, 06:06 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