当有人登录我的电脑时如何获得警报?


Answers:


26

是的,您可以这样做。

进入start> Control Panel> Administrative Tools>Task Scheduler

首先左键Task Scheduler Library单击,然后右键单击并选择Create Task...

在“名称”中,为其指定一个易于识别的名称。

到选项卡 Triggers

New...

在开始任务之后的顶部:On a schedule将其更改为:At log on,然后按OK

转到Actions选项卡,然后按New...按钮。

行动时:Start a program更改为Send an e-mail

填写所有表格,附件是可选的。SMTP服务器必须是有效的smtp服务器。从您的ISP中选择一个。如果您不知道,请使用googleSMTP server [name of isp]

最后按 OK

每当用户(包括您自己)登录时,它都会发送一封电子邮件,因此请注销并重新登录以测试其是否有效。

您可能可以在消息中使用%USERNAME%来显示谁登录。鉴于我使用的是Windows 8.1,因此此操作系统版本不建议使用电子邮件功能,因此我无法对其进行测试。

重要说明:在Windows 8或更高版本中,或在Windows Server 2012中,此功能均不起作用。在这些操作系统中,不建议使用发送电子邮件或显示消息的功能。显示味精可以使用以下方法完成start a program msg * type message here


尽管您的脚本可以发送电子邮件,例如说powershell。
joojaa

@joojaa是的,可以,但是鉴于它仍然可以在Windows 7中正常运行,因此我没有在回答中包括它。
LPChip

1
我认为Windows应该很容易。在Ubuntu中,只需添加mail -s “Someone logged in” you@gmail.com到配置文件。
dotancohen

谁说Windows应该很简单?笑话
DIDIx13 '18

我的意思是这很难吗?
汤姆
By using our site, you acknowledge that you have read and understand our Cookie Policy and Privacy Policy.
Licensed under cc by-sa 3.0 with attribution required.