Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.misc
|
|||
|
|||
please help in this program_1
Problem 2 - Delete
Excel Background In a new sheet go to A1 and enter the value 1. In A2 enter the following formula: =IF(RAND()<0.2,A1,A1+1) Copy the formula down until A30. The result will be groups of increasing numbers. Select the entire column, Copy, Paste Special... Values only, to stabilize the data. Now you will have mostly successive numbers and at times a number will appear twice. Class Libraries Repeat what you did with Insert, but now with Delete. Be careful, it is different to clear a cell's contents by pressing the Delete key in the keyboard; it is different to delete a cell using the menu command. VBA Task Write a VBA macro to go down the list in column A:A. The algorithm should delete numbers that are not successive. E.g. if you have numbers 1, 2, 3, 3, 4, 5, 5, 6, the second 3 and the second 5 should be deleted to reach a perfectly sequential list 1, 2, 3, 4, 5, 6. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|