I have the next equation: $$\int_{0}^{t}h(\tau)e^{-(t-\tau)}\mathrm{d}\tau=10e^{-t}\cos(4t) \tag{1}$$
Derivating both sides, I get: $$h(t)e^{-(t-t)}=h(t)=10[(-1)e^{-t}\cos(4t)+e^{-t}(-4)\sin(4t)] \tag{2}$$
However, if first simplify (1) and then derivating: $$\int_{0}^{t}h(\tau)e^{\tau}\mathrm{d}\tau=10\cos(4t)$$ $$h(t)=10[-4\sin(4t)]e^{-t} \tag{3}$$
Please clarify me what is the correct expression among (2) and (3) and why.
When you write $$\int_{0}^{t}h(\tau)e^{-(t-\tau)}d\tau,$$ what is the value of $t$ in the term $e^{-(t-\tau)}$? Is it the same value of $t$ that is the upper bound of the integral? Does it vary in the same way when you differentiate with respect to $t$?
As I interpret this formula, I see the following identity (with which I see you agree, since the way you "simplify" the formula implies this): $$\int_{0}^{t}h(\tau)e^{-(t-\tau)}d\tau = e^{-t} \int_{0}^{t}h(\tau)e^{\tau}d\tau.$$ But \begin{eqnarray} \frac{d}{dt}\left( e^{-t} \int_{0}^{t}h(\tau)e^{\tau}d\tau \right) & = & e^{-t} \frac{d}{dt} \left(\int_{0}^{t}h(\tau)e^{\tau}d\tau \right) + \left(\frac{d}{dt} e^{-t}\right) \int_{0}^{t}h(\tau)e^{\tau}d\tau \\ & = & e^{-t} (h(t)e^t) + (- e^{-t}) \int_{0}^{t}h(\tau)e^{\tau}d\tau \\ & = & h(t) - 10e^{-t} \cos(4t) \end{eqnarray} which is not equal to $h(t)$ except when $\cos(4t) = 0$. And oh, look, that term of $- 10e^{-t} \cos(4t)$ that is missing from your supposed derivative of $\int_{0}^{t}h(\tau)e^{-(t-\tau)}d\tau$ is exactly what you need to reconcile the (corrected) equation $(2)$ with equation $(3)$.
(Note that @copper.hat essentially gave this solution already in a comment on the original question; I am merely spelling it out in more detail.)