code: def broadcast_change():
      '''
      Refresh the windows environment.
  
      .. note::
          This will only effect new processes and windows. Services will not see
          the change until the system restarts.
  
      Returns:
          bool: True if successful, otherwise False
  
      Usage:
  
          .. code-block:: python
  
              import salt.utils.win_reg
              winreg.broadcast_change()
      '''
      # https://msdn.microsoft.com/en-us/library/windows/desktop/ms644952(v=vs.85).aspx
      _, res = win32gui.SendMessageTimeout(
          win32con.HWND_BROADCAST, win32con.WM_SETTINGCHANGE, 0, 0,
          win32con.SMTO_ABORTIFHUNG, 5000)
      return not bool(resf broadcast_change():
      '''
      Refresh the windows environment.
  
      .. note::
          This will only effect new processes and windows. Services will not see
          the change until the system restarts.
  
      Returns:
          bool: True if successful, otherwise False
  
      Usage:
  
          .. code-block:: python
  
              import salt.utils.win_reg
              winreg.broadcast_change()
      '''
      # https://msdn.microsoft.com/en-us/library/windows/desktop/ms644952(v=vs.85).aspx
      _, res = win32gui.SendMessageTimeout(
          win32con.HWND_BROADCAST, win32con.WM_SETTINGCHANGE, 0, 0,
          win32con.SMTO_ABORTIFHUNG, 5000)
      return not bool(res)
docs: Refresh the windows environment.
  
      .. note::
          This will only effect new processes and windows. Services will not see
          the change until the system restarts.
  
      Returns:
          bool: True if successful, otherwise False
  
      Usage:
  
          .. code-block:: python
  
              import salt.utils.win_reg
              winreg.broadcast_change()