win32evtlogutil.py 文件源码

python
阅读 21 收藏 0 点赞 0 评论 0

项目:purelove 作者: hucmosin 项目源码 文件源码
def RemoveSourceFromRegistry(appName, eventLogType = "Application"):
    """Removes a source of messages from the event log.
    """

    # Delete our key
    try:
        win32api.RegDeleteKey(win32con.HKEY_LOCAL_MACHINE, \
                     "SYSTEM\\CurrentControlSet\\Services\\EventLog\\%s\\%s" % (eventLogType, appName))
    except win32api.error, exc:
        if exc.winerror != winerror.ERROR_FILE_NOT_FOUND:
            raise
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号