RAJESH1960
Banned for repeated rules violations
- Joined
- Mar 26, 2020
- Messages
- 2,313
- Office Version
- 2019
- Platform
- Windows
Hello guys,
I need your expertise to help me to correct this code.
When I run the code, there is just one sheet in the workbook -"Bank". After I run the code a new sheet is created with the new name (first and last dates in the Bank sheet). That new sheet is moved and copied to a different folder. Again, I replace the data in the bank sheet and run the code. This way it goes on. Each time, I have to correct the mismatches because of the code.
The code runs without any error. Still, I am not getting the expected result and the wrong msg box as mismatched.
Changes required.
1. Column G is missing to take the 2 decimals and hence it is showing a mismatch.
2. Column G may contain Cr or Dr in different scenarios. The code shows Cr only. I would like to include Dr also in that line.
3. As there are 2 different balances Dr. & Cr, the formula to be made optional. If the column G contains Cr. Then the formula in column H should be =H2+F3-E3 and if the column G contains Cr, then the formula in column H should be =H2-F3+E3. Please note that it is possible that a single workbook with data may contain both Dr and Cr. So, if the code checks each row for Dr and Cr it can apply the formula accordingly in each row.
4. If possible, Column G to be copied as it is without removing Dr. Cr.
After that, I hope that will solve all the problems
FYI, This code was posted in other forum a few days back. But as I was not able to get the expected result, I am sharing it here again.
0. Edit code Clean & customise.xlsm
I need your expertise to help me to correct this code.
When I run the code, there is just one sheet in the workbook -"Bank". After I run the code a new sheet is created with the new name (first and last dates in the Bank sheet). That new sheet is moved and copied to a different folder. Again, I replace the data in the bank sheet and run the code. This way it goes on. Each time, I have to correct the mismatches because of the code.
The code runs without any error. Still, I am not getting the expected result and the wrong msg box as mismatched.
Changes required.
1. Column G is missing to take the 2 decimals and hence it is showing a mismatch.
2. Column G may contain Cr or Dr in different scenarios. The code shows Cr only. I would like to include Dr also in that line.
3. As there are 2 different balances Dr. & Cr, the formula to be made optional. If the column G contains Cr. Then the formula in column H should be =H2+F3-E3 and if the column G contains Cr, then the formula in column H should be =H2-F3+E3. Please note that it is possible that a single workbook with data may contain both Dr and Cr. So, if the code checks each row for Dr and Cr it can apply the formula accordingly in each row.
4. If possible, Column G to be copied as it is without removing Dr. Cr.
After that, I hope that will solve all the problems
FYI, This code was posted in other forum a few days back. But as I was not able to get the expected result, I am sharing it here again.
0. Edit code Clean & customise.xlsm