Hello the experts,
I'm not good with VBA but I use it a lot, I usually record some stuff then ask my friend google about what I can't get recorded. I know all my macros are probably very weak but as long as I'm the only one at risk it's not an issue. But this time some colleagues are interested and I don't want to "sell" them a rotten file. So... Would you please have a look on my macros and let me know if you see something that should be improved so I can share my file with good chances it will work for other people ? Your corrections are obviously welcome, but also your advices to help me understand why I should do this and not do that...
Thank you very much for your help, Kind regards,
MACRO 3 : This one is used only on my expanses files, to get the numbers on the desired format (Accounting, 2 decimals). There's a lot of "try & fail" behind what I suppose should be very simple and easy. Note that I'm french and for whatever insane reason we use a comma instead of a dot before the decimals. So I start by eliminating the damn commas and replace them by dots, then I apply the desired formatting. I get a feeling this macro is very wrong. But so far it does the job for me...
Selection.Replace What:=",", Replacement:=".", LookAt:=xlPart, _
SearchOrder:=xlByRows, MatchCase:=False, SearchFormat:=False, _
Selection.NumberFormat = "_(* #,##0.00_);_(* (#,##0.00);_(* ""-""??_);_(@_)"