Mr. A, a professional accountant, has been asked by company X to carry out a search and survey on company Y which is involved in gambling business. The reason why company X has requested Mr. A to carry out the search is because company X intends to acquire/buy company Y. Is Mr. A allowed to carry out such search in his professional and be paid a fee?
All perfect praise be to Allaah, The Lord of the Worlds. I testify that there is none worthy of worship except Allaah, and that Muhammad is His slave and Messenger.
Gambling is forbidden by the text of the Quran, Allaah Says (what means): {O you who have believed, indeed, intoxicants, gambling, [sacrificing on] stone alters [to other than Allaah], and divining arrows are but defilement from the work of Satan, so avoid it that you may be successful.}[Quran 90].
If company X wants to buy company Y, and the latter practises gambling, as you mentioned, then this implies that company X will practise the same activity which company Y is doing.
Therefore, it is not permissible for Mr. A to carry out a research on the said company, because by doing so, he is helping in sin and Allaah Says (what means): {And cooperate in righteousness and piety, but do not cooperate in sin and aggression.}[Quran 5:2].
You can search for fatwa through many choices