could you help if I need to save data in sheet 2 from sheet 1 and avoid duplicate entries in sheet 2, where I need to compile my data
@muhammadmunir40682 жыл бұрын
Respected sir your code is working well when I put duplicate data and press ENTER. But when i move to other cell through arrow keys it does not works.Secondly when we move to previous cell its row also deleted even it is happen to be unique value. Please advise how to fix this issue
@jooste Жыл бұрын
Start @ 2:54
@sallytong2413 жыл бұрын
If it is possible the final action is not deleting the last row, but go to the number that has previously been entered. For example, if it is not ID number, it is fax number, I do not want to type duplicated fax number.
@ExcelDestination3 жыл бұрын
for that, I would suggest, you should use search and update feature using vba code.
@sallytong2413 жыл бұрын
@@ExcelDestination Thank you
@broudjzed78924 ай бұрын
Hello boss how to update database once by transfering all listbox items once tanks
@曾文東-x5d5 жыл бұрын
Where to find the exercise file?
@ranjanbirla55543 жыл бұрын
This code has an issue if you move up in column four (04), It will show it is a duplicate record and delete it. You keep moving the cursor in the upper row and it will keep deleting records. Which should not be the case.
@ExcelDestination3 жыл бұрын
this code is to prevent duplicates only. if you need any vba code support, please share your requirement at exceldestination@gmail.com
@shruthinagappan26782 жыл бұрын
Exactly
@alializadeh81952 жыл бұрын
Thank man
@robertgryska39544 жыл бұрын
Hi I have problem with this line lastrow = Worksheets("Sheet1").Cells(Rows.Count, 4).End(x1Up).Row - Runtime error 1004 application defined or object defined error. Thx
@alsaadventure85014 жыл бұрын
XLup not x1up Cmiiw
@sureshsomaiya38204 жыл бұрын
Thanks bhai
@ExcelDestination4 жыл бұрын
YW
@mukundpotdar98495 жыл бұрын
Hi In case if user try to copy and paste the data from Row 1 of Customer Id to Row 16 of Customer Id. Can we prevent the duplicate data.
@ExcelDestination5 жыл бұрын
Thanks for your question...I haven't tried it while developing this code...will try and let you know.
@giuseppegenovese47475 жыл бұрын
Enter this code and adapt it to the need to do wath you asked for Private Sub Worksheet_SelectionChange(ByVal Target As Range) Dim nr As Variant If ActiveCell.Column = 3 And ActiveCell.Offset(1, 0).Value = "" Then nr = Worksheets("Foglio17").Range("c" & Rows.Count).End(xlUp).Value lastrow = Worksheets("Foglio17").Cells(Rows.Count, 3).End(xlUp).Row For i = 2 To lastrow - 1 If nr = Worksheets("Foglio17").Cells(i, 3).Value Then Worksheets("Foglio17").Cells(lastrow, 3).ClearContents MsgBox ("Numberr already present please rewrite it"), vbInformation Worksheets("Foglio17").Cells(lastrow, 3).Select End If Next i End If End Sub
@mukundpotdar98495 жыл бұрын
Thank you, Its Working
@luissoler97695 жыл бұрын
@@giuseppegenovese4747 Ciao! I've tried this code but when i go to the last cell in the sheet or i have an error i got a massagger with error 13 or error 1004
@markarvin77255 жыл бұрын
📢 This is nice, but there's a problem. If you mistakenly click on an entry that you don't want deleted, it automatically deletes that entry. Is there a fix out there for this? 😃
@michaelsmits86774 жыл бұрын
why not use a mesbox yes/no to first confirm your action? That would help I guess
@Quoteminds54 жыл бұрын
Hello , let say we have a id 12 and u right again in the below 12 , then it shows duplicate and delete the cell which is great , but when u enter again in blank cell the above data gets deleted also please advise
@ExcelDestination4 жыл бұрын
you can choose any other column, except id.
@Quoteminds54 жыл бұрын
@@ExcelDestination you can choose another column normally , but whats happening if u write id 12 and then press enter it goes to cell 13 , ( which should be id number 13 entered ) but if u leave it blank and press enter again it deletes row 12
@Quoteminds54 жыл бұрын
@@ExcelDestination yes but i want in the id column to not except duplicates and at the same time move down in the empty cells, 2- the rows I'm working with have colors in them , but them i press the command button to copy the rows , the rows copies perfectly as the data specified but the colors of the cells change " is there any vba code to keep the colors the same "
@crazy22424 жыл бұрын
@@ExcelDestination Is there a better way to not delete the cell for that id? What if i select that id column and when i press up, it accidentally deletes the important data one by one?