force excel cells to follow position of another cell - excel

i have a two tabs excel, in the first one the user input some data, then in the second tab the first five column are populated with the info from the first tab, the position of these data is relative to the position of the data in the first tab
so for example, if a user populate the first and tenth row in the first tab, then only the first and tenth row of the second tabs are populated.
thing is after the fifth column in the spreadsheet the user can put some more info regarding the data (like comments or other) and those cells are hardcoded by the user, so is someone happen to do a sorting action in the first tab the five columns in the second tab would also change position but not the other column after that, leaving behind the eventual data.
is there a way to force the cells after the fifth column to just "follow" the position of the data in the first five?

In trying to avoid using VBA you can achieve this if you are ok to add some technical columns.
Sheet1:
Change your source in sheet1 to table format (this will make sure formulas are copied down when user add data;
add a technical column (can be hidden, copy paste link from the user input column in sheet 2) e.g. Sheet1!B:B;
Sheet2:
Add 2 columns:
=> user input (unsorted) e.g. col.D, (This is the column that user can edit)
=> user input sorted (users should not edit this column)
Add a tech column (can be hidden) with : MATCH(D3;Sheet1!B:B;0)
Add in the "user input sorted": INDEX(D:D;MATCH(ROW();G:G;0);1)
When the sheet 1 is sorted, the tech column will also be sorted, we then use this info to find back the original comment, define it's new row nr and show it in the sorted col. on sheet 2. This will not work if 2 comments can be exactly the same!
Note!
for the formulas to work, you'll need to change my semicomma's to a comma if you are on a US Excel (I'm on EU).
best of luck,
ceci

Related

How to get cells in Excel to move with another specific cell

Good morning! I have a simple spreadsheet for tracking part numbers (and various data related to them). Column B (on "Data" page) automatically brings in all part numbers from another sheet ("Info" sheet). When this "Info" sheet gets updated with new part numbers (sometimes part #'s are removed, sometimes new ones added) the "Data" sheet also updates and sorts in numerical order. For most of the columns in the "Data" sheet, info is updated with a simple VLOOKUP formula. There are some though that are manual entries. The problem I have having is that when a part # moves up or down in column B, certain cells in that same row don't move and that data is now incorrectly attached to a different part #. How do I get the cell in column A to move with it's corresponding part # in column B?

Creating a Drop Down List for An Already Existing Data Table with Over 3500 Line Items (Rows)

Sorry to bother you. I really could not find an answer on Reddit or Google.
So I provided an example of the Table I am working with. Except my current data set is not just 11 Rows across. I have over 3500 Lines (Rows/ Line Items) that exist already.
Please see attached/ Picture uploaded
Essentially I want:
I) Excel to automatically recognize and grab the address for the existing 3500 lines (Current example with screenshot is that I have 11 entered) entered onto spreadsheet and with those correctly grabbed addresses shown as a drop down menu in Column B (Site Location). So in column B for the already entered addresses, the cell will look like it has a drop down menu to choose from?
II) With new line items being entered after Row 12 beginning Row 13 that Site Location (Column B) will also have a drop down menu for those entering the new data into Column B (Site Location).
III) Type of Personnel column will also have a dropdown menu for the existing data and new data to be entered.
Is this possible? Or am I dreaming beyond the capabilities of Excel?
Thank you!!
You can select the cells in colum B (or the whole column) and then add a data validation rule that references the same column as a list.
See https://support.microsoft.com/en-us/office/apply-data-validation-to-cells-29fecbcc-d1b9-42c1-9d76-eff3ce5f7249 for how to create a data validation.
Select the "list" option for the validation, then define the column B as the list. Make sure the check mark is set on "In-cell dropdown".
Then you'll have a dropdown list with the already present values in the column.
You can also add new values because they will become part of the list that validates the entries.

In excel, how can I automate a sheet to be filled based on conditions of another sheet?

Is there a way in excel to copy the contents of one column to another sheet based on particular values in another column.
I have data which looks like this:
Sheet1:
Sheet2:
I would like to copy the column A of sheet 1 directly onto column A of sheet 2, but only if the value in column B is Y.
I have tried used the match function but am not sure how the best way to do this would be. Is there a way for me to achieve this?
My desired output is:
As discussed in the comments, #Waldorf99 was looking to have a second worksheet that would automatically show a filtered list from the first sheet. I can think of a few ways to do this (array formulas or pivot tables come to mind). The problem with mixing dynamic columns with static values is that the static values would become desynced from the dynamic ones.
In the original example, rows may have a blank value in the condition column in sheet one, and then may be assigned a Y or N at a later date. If a Y is assigned to a row in the middle of other rows, the filtered sheet would shift the existing rows down to make room. The static values would stay where they were, and would become desynced. To demonstrate:
If the above image is the original state of sheet 1 and 2...
...adding a y next to x.1.c would result in sheet two shifting columns A and B of row 2 down, but leaves columns C and D behind (as they are static, and not tied into the first two columns in any way).
One thing that may work as you are wanting are filters. You would only have one sheet, with all of the data manually entered. Then you can add filters, and change them to hide rows temporarily when needed.
To add and use filters:
Start with your data all on one sheet...
Highlight your data...
On the Home tab, select "Format as Table" and choose any style...
This turns your data into a table. You can filter by clicking the drop down in a given columns header row, then deselecting the values you want to hide.
The results are a table that only shows the rows with a 'Y'.
The other rows aren't removed, just hidden. You can always reset or change your filters, to configure which rows are visible.
Note: when working with tables, they will auto expand to account for new rows, so long as you work in the row directly under the table (e.g. don't leave blank rows). You can also manually resize the table at any time by clicking and dragging from the bottom right corner of the table.
There are tons of resources of Excel tables online, and it's a pretty useful tool in Excel.
Hope that achieves what you were looking for.

Converting table into different Format in excel [duplicate]

This question already has answers here:
How to make a kind of pivot with strings?
(2 answers)
Closed 1 year ago.
I have data in the format shown in the first image with thousands of rows and different attributes. I would like for the data to be changed to a format in the 2nd image which would be easier to use and analyze. Are there any useful functions that could help me achieve this?
I would recommend you to do the following (it is not easy as applying some function, but it works haha). My Excel is in Portuguese, but I hope the images help you.
Copy the first column to another worksheet
Delete duplicates
Insert a new line before the first line on the new worksheet
Copy the second column of the original worksheet and paste it transposed - right click, transposed. Remember to just copy once each value. For example, in your case, just copy Name, Age, Height and Weight.
Finally, it is possible to add a line to represent header for your original data. For example, the first column you can call ID, the second you call Attribute and the third, Value. Then, you filter the colum Attribute by the first possibility - Name, in your case - and copy the column Value to the respective column on new worksheet. Then you filter by Attribute = Age and do the same. Do the same for all possibilities.
So, on the last step, the number of copy-paste is exactly the number of different values you have for your second column.
It is possible to do a VBA code to automate it, if you are going to do it frequently.
#1. You can try to use distinct Formula to get your data index (column A)
or Use Remove Duplicate icon at Excel Ribbon.
A2:A10 is the source list.
B1 is the cell above the first cell of the distinct list.
#2. Create Uniq Row (see my screencapture).
#3. You can use vlookup formula to match your data from sheet1 to sheet2.

Compare users in different sheets and add user to sheet A if not present in A but present in B

We use an Excel file as a support tracker. Our main sheet (A) has a list of users and their data. For daily support, we run the MYSQL stored procedure to get the data, then paste it into a blank sheet (B) that colors and filters the data.
I am supposed to search the users in sheets A and B, and if a user is present in B but not A (scenario representing adding a user to our system) add the missing user to sheet A.
Based on my past programming knowledge, the steps should be:
count rows in sheets A and B
A has more data further down the sheet that is not raw user data, but it is in the same columns so looking for the first blank cell in A
do a compare on those results
if the results are different, do a vlookup to find the missing entry
insert that entire row from sheet B to sheet A
I assume this can be done with VBA code.
You can write a VBA script to do this, and probably should if this is a regular process.
Alternatively a sorting approach will handle this and many similar problems. It works like this, given two sheets A & B with mixed duplicate and unique entries:
Append B to A
Sort by desired category (User in this case)
This will have duplicates (User) next to each other
Insert a match check column consisting of If User EQ PreviousUser, True, False;
Cut and paste Values to change from a function to simple content of True/False
Sort by True/False column
Delete the entire block of True's
Done!
This approach also works for more than two sheets. Append them all together, sort, mark dups, delete.

Resources