How many solutions does the equation $\sum_{i=1}^{k}{x_i}=c$ have, given that the $x_i\in\mathbb{Z}$ and $0\leq x_i\leq d$?
HINT
The generating function for each of the $x$'s is $$1 + x + \ldots + x^d = \frac{1-x^{d+1}}{1-x}$$ and you have $k$ of them, so the g.f. of the result is their product. in which you are looking for coefficient of $x^c$.
In other words, you need $$ \left[ x^c \right] \left( \frac{1-x^{d+1}}{1-x} \right)^k = \left[ x^c \right] \left( 1-x^{d+1} \right)^k \frac{1}{(1-x)^k} $$
and now the first term expands via the Binomial Theorem. Can you take it from here, expanding the second term and adding the coefficients?
UPDATE
To expand $(1-x)^{-k}$ note that you really have $$ (1-x)^{-2} = \frac{d}{dx} \left[ (1-x)^{-1} \right] = \frac{d}{dx} \left[ \sum_{n=0}^\infty x^n\right] = \sum_{n=1}^\infty nx^{n-1} = \sum_{n=0}^\infty(n+1)x^n $$ and differentiating again $$ (1-x)^{-3} = \frac12 \frac{d}{dx} \left[ (1-x)^{-2} \right] = \frac12 \frac{d}{dx} \left[ \sum_{n=0}^\infty (n+1)x^n\right] = \sum_{n=0}^\infty \frac{n(n+1)}{2} x^n = \sum_{n=0}^\infty \binom{n}{2} x^n $$ if you see the pattern, it's easy to prove by induction that $$ \frac{1}{(1-x)^k} = \sum_{n=0}^\infty \binom{n+k-1}{k-1} x^n = \sum_{n=0}^\infty \binom{n+k-1}{n} x^n $$