This is probably not safe. It's not just about voltage... NiCd batteries have different charging voltage/current profiles and charge termination criteria from Li-ion batteries which the laptops almost surely are. I wouldn't do it.... especially not with the 20v.
Thanks for the advise and the explanation about the difference voltage/current characteristic between the NiCad and Li-ion battery. Sorry , I was not specific enough when posting my question. The 18V power adapter looks like any 5V power block that we got these days as USB charger. I am not sure the protection or current regulation circuitry is in there. I opened up the charging station where the battery is plugged in, There is another circuit board inside which may be doing the voltage/current regulation required for NiCad charging (again pure speculation). If I am right, the 18V adapter may simply be supplying 18V DC and there should be no difference using the supplied 18V adapter or a power adapter for laptop which can output 18V. Unfortunately, in my case, I can only have a 16V or 20V DC source. I did further investigation after my first post. I measured the voltage at the charging station with no battery plug in. When I provide 16V DC source, the voltage is 14.95V. When I provide 20V, the voltage is 18.5V. Any further advise ?
For learning purpose, is that a requirement that the charging voltage applied to the rechargeable battery must be higher that the rated voltage of the battery being charged ?