I've been searching this site over and over to find a solution to my problem, but I can't find it and what I've found does not seem to work.
My problem is as follows: I'm trying to cite APA style in my ShareLaTeX file, but whenever I type \cite{} and select one of the proposed writers from my .bib file, an error occurs. The citation appears in bold, and the error is:
Citation 'Slagter2012' on page 1 undefined on input line 24.:
You have cited something which is not included in your bibliography.
Make sure that the citation (\cite{...}) has a corresponding key
in your bibliography, and that both are spelled the same way.
Now I've checked this over and over and it seems all the same to me. Is here something wrong in my file?
\documentclass{article}
\usepackage[utf8]{inputenc}
\usepackage[affil-it]{authblk}
\usepackage[american]{babel}
\usepackage{csquotes}
\usepackage[style=apa]{biblatex}
\DeclareLanguageMapping{american}{american-apa}
\addbibresource{article.bib}
\title{MyArticle}
\author{MyName}
\date{Dated: \today}
\affil{University of Amsterdam}
\begin{document}
\maketitle
\section{Introduction}
This is the introduction.\cite{Slagter2012}
\printbibliography
\end{document}
This is my .bib file
@article{Slagter2012,
author = {Slagter, Heleen A. and Tomer, Rachel and Christian, Bradley T.
and Fox, Andrew S. and Colzato, Lorenza S. and King, Carlye R.
and Murali, Dhanabalan and Davidson, Richard J.},
isbn = {1530-8898 (Electronic)$\backslash$n0898-929X (Linking)},
issn = {0898-929X},
journal = {Journal of Cognitive Neuroscience},
number = {9},
pages = {1932--1940},
pmid = {22663253},
title = {{PET Evidence for a Role for Striatal Dopamine in the
Attentional Blink: Functional Implications}},
volume = {24},
year = {2012}
}
And this is the output
What am I doing wrong?
NOTE I am completely new to this, be as clear as possible otherwise I will not understand ;)

\bibliography{article.bib}and recompile? – Mico Feb 07 '18 at 14:15.blgfile and post its contents here. – moewe Feb 07 '18 at 14:18.blgas explained in https://tex.stackexchange.com/q/284342/35864 and show us the contents. If you are working on a fully updated MikTeX, you might be facing https://tex.stackexchange.com/q/413898/35864 – moewe Feb 07 '18 at 15:32.blgas 'Performance Monitor files', but the.blgs produced by Biber are just text files you can open with your favourite text editor. – moewe Feb 07 '18 at 15:42.txtinstead of.blg. But you should be able to open the file from within a text editor even without renaming it. If you can't see or change the file extension, you must first enable that: http://www.thewindowsclub.com/show-file-extensions-in-windows – moewe Feb 07 '18 at 15:45.blgfile to see if something is wrong with Biber. – moewe Feb 07 '18 at 15:58