用 Python 打开 Outlook [英] Opening Outlook with Python

查看:41
本文介绍了用 Python 打开 Outlook的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试用 Python 打开 Outlook,我得到了这个...

I am trying to open Outlook with Python and I got this...

import win32com.client
ol = win32com.client.Dispatch("outlook.Application")

它打开 Outlook,但我的问题是它在 Windows 的通知区域(时钟所在的位置)中打开它,但它没有在屏幕上打开它.我试过...

It opens Outlook but my probles is it opens it in the notification area of Windows (where the clock is) and it doesn't open it up on the screen. I tried a ...

OL.visible= True

但我收到一个错误,提示 Outlook 应用程序无法设置为可见.所以我的问题是如何将 Outlook 设置为全屏或将其最大化到全屏?

But I get an error that Outlook application can't be set to visible. So my question is how can I bring Outlook for, or maximze it to a full screen?

推荐答案

好的,我发现这和以前一样简单......

Ok I found this to work as simple as it was....

import os
os.startfile("outlook")

它使它变成一个大窗口,并使其最小化.

It makes it into a large window and mot a minimized one.

这篇关于用 Python 打开 Outlook的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆