<div dir="ltr">If you're on Windows the command would be `py -m pip install openpyxl` (since it sounds like you didn't check the box at install time to add python to your PATH), although I would suggest doing `py -m pip install --user openpyxl` instead (a virtual environment would be better, but explaining that is off-topic for this mailing list).<br></div><br><div class="gmail_quote"><div dir="ltr">On Tue, 27 Mar 2018 at 23:04 森平 直樹 <<a href="mailto:naoki_morihira@outlook.jp">naoki_morihira@outlook.jp</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div lang="JA" link="blue" vlink="#954F72">
<div class="m_-9021364928057389455WordSection1">
<p class="MsoNormal"><span lang="EN-US">Mathew,</span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:12.0pt"><u></u> <u></u></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:12.0pt">Thank you for your quick response.
<u></u><u></u></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:12.0pt"><u></u> <u></u></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:12.0pt">Does “cmd” shell mean MS-Windows command prompt ?<u></u><u></u></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:12.0pt"><u></u> <u></u></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:12.0pt">I executed in Windows command prompt and the result is shown below:<u></u><u></u></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:12.0pt"><u></u> <u></u></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt">C:\Users\N.Morihira>pip install openpyxl<u></u><u></u></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt">Pip is not recognized as executable command at Windows command prompt and so is Python command line.
<u></u><u></u></span></p></div></div><div lang="JA" link="blue" vlink="#954F72"><div class="m_-9021364928057389455WordSection1">
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt"><u></u> <u></u></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:12.0pt"><u></u> <u></u></span></p>
<p class="MsoNormal"><span lang="EN-US">Best Regards,</span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt">---------------------<br>
Naoki Morihira<br>
TEL: <a href="tel:+81%2090-6460-6265" value="+819064606265" target="_blank">01181-90-6460-6265</a><br>
---------------------<br>
<br>
</span><span lang="EN-US" style="font-size:12.0pt;font-family:"\00ff2d\00ff33 \00ff30\0030b4\0030b7\0030c3\0030af",sans-serif"><u></u><u></u></span></p>
</div></div><div lang="JA" link="blue" vlink="#954F72"><div class="m_-9021364928057389455WordSection1"><div style="border:none;border-top:solid #e1e1e1 1.0pt;padding:3.0pt 0mm 0mm 0mm">
<p class="MsoNormal" style="border:none;padding:0mm"><b>差出人<span lang="EN-US">: </span>
</b><span lang="EN-US"><a href="mailto:matthew.brett@gmail.com" target="_blank">Matthew Brett</a><br>
</span><b>送信日時<span lang="EN-US">: </span></b><span lang="EN-US">2018</span>年<span lang="EN-US">3</span>月<span lang="EN-US">27</span>日<span lang="EN-US"> 13:21<br>
</span><b>宛先<span lang="EN-US">: </span></b><span lang="EN-US"><a href="mailto:naoki_morihira@outlook.jp" target="_blank"><span lang="EN-US"><span lang="EN-US">森平</span></span><span lang="EN-US"><span lang="EN-US">
</span></span><span lang="EN-US"><span lang="EN-US">直樹</span></span></a><br>
<b>CC: </b><a href="mailto:brett@python.org" target="_blank">Brett Cannon</a>; <a href="mailto:distutils-sig@python.org" target="_blank">
distutils-sig@python.org</a><br>
</span></p></div></div></div><div lang="JA" link="blue" vlink="#954F72"><div class="m_-9021364928057389455WordSection1"><div style="border:none;border-top:solid #e1e1e1 1.0pt;padding:3.0pt 0mm 0mm 0mm"><p class="MsoNormal" style="border:none;padding:0mm"><b>件名<span lang="EN-US">: </span></b><span lang="EN-US">Re: [Distutils] Need how to install 3rd party python modules</span></p></div></div></div><div lang="JA" link="blue" vlink="#954F72"><div class="m_-9021364928057389455WordSection1">
<p class="MsoNormal"><span lang="EN-US" style="font-size:12.0pt;font-family:"\00ff2d\00ff33 \00ff30\0030b4\0030b7\0030c3\0030af",sans-serif"><u></u> <u></u></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt">Hi,<br>
<br>
Brett is just saying that you should first open a "cmd" shell, and, at<br>
the cmd prompt, type:<br>
<br>
pip install openpyxl<br>
<br>
Your problem (which is relatively common) is that you were typing the<br>
command at the Python prompt, instead of the cmd prompt.<br>
<br>
Best,<br>
<br>
Matthew<br>
<br>
<br>
On Tue, Mar 27, 2018 at 6:04 PM, </span><span style="font-size:11.0pt">森平 直樹<span lang="EN-US"> <<a href="mailto:naoki_morihira@outlook.jp" target="_blank">naoki_morihira@outlook.jp</a>> wrote:<br>
> Brett,<br>
><br>
><br>
><br>
> Thank you for responding me.<br>
><br>
> Could you tell me the e-mail address of the python-tutor ?<br>
><br>
> And if you have something even a little to be a hint to resolve this syntax<br>
> error, it is appreciated to teach me.<br>
><br>
><br>
><br>
> Best Regards,<br>
><br>
> ---------------------<br>
> Naoki Morihira<br>
> TEL: <a href="tel:+81%2090-6460-6265" value="+819064606265" target="_blank">01181-90-6460-6265</a><br>
> ---------------------<br>
><br>
><br>
><br>
> ________________________________<br>
> </span>差出人<span lang="EN-US">: Brett Cannon <<a href="mailto:brett@python.org" target="_blank">brett@python.org</a>><br>
> </span>送信日時<span lang="EN-US">: Tuesday, March 27, 2018 9:44:57 AM<br>
> </span>宛先<span lang="EN-US">: ?? ??<br>
> CC: <a href="mailto:distutils-sig@python.org" target="_blank">distutils-sig@python.org</a><br>
> </span>件名<span lang="EN-US">: Re: [Distutils] Need how to install 3rd party python modules<br>
><br>
> For general help to get started with Python I would recommend the<br>
> python-tutor mailing list; this one is for discussing the development of how<br>
> to package things in Python.<br>
><br>
> But in your specific case you typed the command in Python's REPL and not at<br>
> the terminal. For further help please ask on python-tutor.<br>
><br>
> On Tue, 27 Mar 2018 at 09:42 ?? ?? <<a href="mailto:naoki_morihira@outlook.jp" target="_blank">naoki_morihira@outlook.jp</a>> wrote:<br>
>><br>
>> I would like to install openpyxl, and<br>
>><br>
>> I installed Python shown as follows:<br>
>><br>
>> Python 3.6.4 (v3.6.4:d48eceb, Dec 19 2017, 06:04:45) [MSC v.1900 32 bit<br>
>> (Intel)] on win32<br>
>><br>
>><br>
>><br>
>> But as the following situation shows, I cannot succeed installing<br>
>> openpyxl.<br>
>><br>
>><br>
>><br>
>> >>> pip install openpyxl<br>
>><br>
>> File "<stdin>", line 1<br>
>><br>
>> pip install openpyxl<br>
>><br>
>> ^<br>
>><br>
>> SyntaxError: invalid syntax<br>
>><br>
>><br>
>><br>
>> How can I succeed installing openpyxl ?<br>
>><br>
>><br>
>><br>
>> Best Regards,<br>
>><br>
>> ---------------------<br>
>> Naoki Morihira<br>
>> TEL: <a href="tel:+81%2090-6460-6265" value="+819064606265" target="_blank">01181-90-6460-6265</a><br>
>> ---------------------<br>
>><br>
>><br>
>><br>
>> _______________________________________________<br>
>> Distutils-SIG maillist - <a href="mailto:Distutils-SIG@python.org" target="_blank">Distutils-SIG@python.org</a><br>
>> <a href="https://mail.python.org/mailman/listinfo/distutils-sig" target="_blank">https://mail.python.org/mailman/listinfo/distutils-sig</a><br>
><br>
><br>
> _______________________________________________<br>
> Distutils-SIG maillist - <a href="mailto:Distutils-SIG@python.org" target="_blank">Distutils-SIG@python.org</a><br>
> <a href="https://mail.python.org/mailman/listinfo/distutils-sig" target="_blank">https://mail.python.org/mailman/listinfo/distutils-sig</a><br>
><u></u><u></u></span></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:12.0pt;font-family:"\00ff2d\00ff33 \00ff30\0030b4\0030b7\0030c3\0030af",sans-serif"><u></u> <u></u></span></p>
</div></div></blockquote></div>