Hello,
I recommend that you try the following methods to see if they can solve the problem:
Enable the sharing service to start automatically. This problem usually occurs when one of the services is not working properly.
Press the Windows logo key + R.
In the Run dialog box, type "services.msc", and then select OK.
Right-click each of the following services, select Properties, and if the service is not running, select the Start menu, and then select Automatic next to Startup type:
Function Discovery Provider Host
Function Discovery Resource Publishing
SSDP Discovery
UPnP Device Host
If the problem still cannot be solved, I suggest you try restarting the Function Discovery Resource Publication service.
Best regards
Zunhui