By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
448,548 Members | 1,129 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 448,548 IT Pros & Developers. It's quick & easy.

i am unable to open stikcy note using subprocess and write to it please seee the code

P: 1
import subprocess
p=subprocess.Popen(["C:\Program Files\WindowsApps\Microsoft.MicrosoftStickyNotes_3 .1.55.0_x64__8wekyb3d8bbwe\Microsoft.Notes.exe"],stdin=subprocess.PIPE)
Mar 20 '19 #1
Share this Question
Share on Google+
1 Reply

Expert 100+
P: 626
If you print "C:\Program Files\WindowsApps\Microsoft.MicrosoftStickyNotes_3 .1.55.0_x64__8wekyb3d8bbwe\Microsoft.Notes.exe" it will likely contain things you didn't put in it. That is because the backslash, "\", followed by a letter, can be translated to some other character, for example, "\t" is translated to a tab. You can use forward slashed in Python, no matter what your OS. Another option is to use raw strings
Mar 20 '19 #2

Post your reply

Sign in to post your reply or Sign up for a free account.