TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am using TeXworks 0.4.5 r1280 with MikTeX 2.9 on Windows 7 64-bit. When I add


and try to typeset the document, I get a dialog window like this:

Package Installation Window

I select "Install", confirm UAC request and then get the following error on the console:

! LaTeX Error: File `datetime.sty' not found.

If I try to typeset the document again - the dialog and the error appear again.

Same thing happens when I've tried installing wrapfig and a few other packages at random: cases, comma, dowith, microtype. Other packages have installed fine before. What is wrong with my setup? Please let me know if you need more info about my setup in comments.

I've tried this solution: *.sty file not found. Didn't work.

share|improve this question
Try to change the repository using the button change. Select another one and check you Internet connection. – Sigur Jan 3 '14 at 15:22
Also, you can get it here ctan.org/pkg/datetime – Sigur Jan 3 '14 at 15:28
Awesome. Changing the repository helped. Please add your comment as an answer so that I can mark it as such. Thanks a lot. – Sergiy Byelozyorov Jan 3 '14 at 15:31
To other linux users, I hit this problem even though I'd just installed the .sty files with the package manager. The problem was stale temporary files and after a make clean (deleting dvi aux bbl files etc.) everything worked. – jozxyqk Jun 19 '15 at 9:49
up vote 5 down vote accepted

Try to change the repository using the button Change.

Select another one and check you Internet connection.

Also, you can get it from CTAN.

Note that you can decide if you want to see that dialog window every time or not.

share|improve this answer
Please add instructions on how to install it manually from CTAN. – Sergiy Byelozyorov Jan 10 '14 at 18:25
If there is only one sty file you can save it at the same folder as your tex file. But to let it work for all users you have to save it on the right place in some texmf subfolder. – Sigur Jan 10 '14 at 18:34

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.