I do not get any errors from this MWE and neither does WriteLaTeX as you can verify by clicking on the OPEN IN WRITELATEX button right above the code box. Maybe you need to update your TeX distribution?
This is pdfTeX, Version 3.1415926-2.5-1.40.14 (TeX Live 2013) (format=pdflatex 2013.8.21) 23 AUG 2013 17:08
entering extended mode
restricted \write18 enabled.
%&-line parsing enabled.
**tmp.tex
(./tmp.tex
LaTeX2e <2011/06/27>
Babel <3.9f> and hyphenation patterns for 7 languages loaded.
(/daten/heimatordner/rudi/texmf/tex/leaflet.cls
Document Class: leaflet 2004/12/22 v1.0d LaTeX document class (JS,WaS,RN,HjG)
(/usr/share/texmf-dist/tex/latex/etex-pkg/etex.sty
Package: etex 1998/03/26 v2.0 eTeX basic definition package (PEB)
\et@xins=\count79
)
\@@@out@mark=\marks1
\c@@@total@outs=\count80
\c@@@last@exec=\count81
(/usr/share/texmf-dist/tex/latex/base/article.cls
Document Class: article 2007/10/19 v1.4h Standard LaTeX document class
(/usr/share/texmf-dist/tex/latex/base/size10.clo
File: size10.clo 2007/10/19 v1.4h Standard LaTeX file (size option)
)
\c@part=\count82
\c@section=\count83
\c@subsection=\count84
\c@subsubsection=\count85
\c@paragraph=\count86
\c@subparagraph=\count87
\c@figure=\count88
\c@table=\count89
\abovecaptionskip=\skip41
\belowcaptionskip=\skip42
\bibindent=\dimen102
)
(/usr/share/texmf-dist/tex/latex/ms/everyshi.sty
Package: everyshi 2001/05/15 v3.00 EveryShipout Package (MS)
)
(/usr/share/texmf-dist/tex/latex/tools/calc.sty
Package: calc 2007/08/22 v4.3 Infix arithmetic (KKT,FJ)
\calc@Acount=\count90
\calc@Bcount=\count91
\calc@Adimen=\dimen103
\calc@Bdimen=\dimen104
\calc@Askip=\skip43
\calc@Bskip=\skip44
LaTeX Info: Redefining \setlength on input line 76.
LaTeX Info: Redefining \addtolength on input line 77.
\calc@Ccount=\count92
\calc@Cskip=\skip45
)
(/usr/share/texmf-dist/tex/latex/graphics/graphicx.sty
Package: graphicx 1999/02/16 v1.0f Enhanced LaTeX Graphics (DPC,SPQR)
(/usr/share/texmf-dist/tex/latex/graphics/keyval.sty
Package: keyval 1999/03/16 v1.13 key=value parser (DPC)
\KV@toks@=\toks14
)
(/usr/share/texmf-dist/tex/latex/graphics/graphics.sty
Package: graphics 2009/02/05 v1.0o Standard LaTeX Graphics (DPC,SPQR)
(/usr/share/texmf-dist/tex/latex/graphics/trig.sty
Package: trig 1999/03/16 v1.09 sin cos tan (DPC)
)
(/usr/share/texmf-dist/tex/latex/latexconfig/graphics.cfg
File: graphics.cfg 2010/04/23 v1.9 graphics configuration of TeX Live
)
Package graphics Info: Driver file: pdftex.def on input line 91.
(/usr/share/texmf-dist/tex/latex/pdftex-def/pdftex.def
File: pdftex.def 2011/05/27 v0.06d Graphics/color for pdfTeX
(/usr/share/texmf-dist/tex/generic/oberdiek/infwarerr.sty
Package: infwarerr 2010/04/08 v1.3 Providing info/warning/error messages (HO)
)
(/usr/share/texmf-dist/tex/generic/oberdiek/ltxcmds.sty
Package: ltxcmds 2011/11/09 v1.22 LaTeX kernel commands for general use (HO)
)
\Gread@gobject=\count93
))
\Gin@req@height=\dimen105
\Gin@req@width=\dimen106
)
Class leaflet Info: Generating code for pdfTeX on input line 264.
Runaway argument?
{
! Paragraph ended before \calc@assign@generic was complete.
<to be read again>
\par
l.386 \setmargins{11mm}{11mm}{8mm}{8mm}
?
! Emergency stop.
<to be read again>
\par
l.386 \setmargins{11mm}{11mm}{8mm}{8mm}
End of file on the terminal!
Here is how much of TeX's memory you used:
1025 strings out of 494981
13325 string characters out of 6180069
63016 words of memory out of 5000000
4297 multiletter control sequences out of 15000+600000
3640 words of font info for 14 fonts, out of 8000000 for 9000
14 hyphenation exceptions out of 8191
34i,0n,21p,264b,36s stack positions out of 5000i,500n,10000p,200000b,80000s
! ==> Fatal error occurred, no output PDF file produced!
I didn't post my complete log but only the file list that will be printed there when you add \listfiles to the document preamble. This is a useful command to check which files actually have been used.