Question to people who experienced similar problem and familiar with Lenovo tablets.

I have lenovo yoga yt3-x50f tablet with wifi problem majority of times seen lately. (it has been working perfectly for few years).
When I try to turn wifi On the button flicks back to Off position by itself after few seconds (trying to initialize the wifi module as I suspect).
Sometimes it works fine but mostly wifi cannot be turned On and obviously no connections could be found.

The things I tried so far without much success:
1. Turning the tablet Off and On
2. Restarting the tablet
3. Clearing network settings
4. Factory reset. After reset it worked for about 10 minutes.
5. Open up the tablet and reset wifi antenna cable. After that wifi worked while tablet was open. After closing the case wifi disappeared again driving me nuts.

I realize there could be one problem, either motherboard with the module or wifi antenna. Neither part I have to test with.
I found online antenna for sale in US but something tells me if antenna was faulty I should still be able to turn wifi on. Trying to buy motherboard just to try seems like the most probable course of actions but not sure if it is worth spending money for the tablet without guaranteed result.

I am looking for suggestions here from people who faced similar problem and know more about the tablets to confirm my assumptions above.

Thank you for reading and appreciate your comments.