Cocartesian squares in the category of abelian groups. Recently, I've been doing a recap of (basic) category theory and found an old exercise I seem to be unable to solve. The question is as follows.
Let $A, B$ be abelian groups, $A'<A$ and $B'<B$ subroups and $\phi:A\to B$ such that $\phi(A')\subseteq B'$. Let $\phi':A'\to B'$ and $\phi'':A/A'\to B/B'$ be the maps induced by $\phi$. Prove that the diagram
\begin{array}
AA' & \to & A \\
\downarrow{\phi'} & & \downarrow{\phi} \\
B' & \to & B  
\end{array}
is a cocartisian square if and only if $\phi''$ is an isomorphism.
The exercise preceding this one looks like a dual statement which I did manage to prove (a similar square being cartesian iff $\phi'$ is an iso), yet just dualising the proof doesn't seem to work. That proof, however, suggests using the universal property of cocartesian squares for one of the implications ($\Rightarrow$), while using the explicit construction of pushouts in the category of abelian for the other one. The pushout of $A_1\overset{f_1}{\leftarrow} A_3 \overset{f_2}{\rightarrow} A_2$ in this category is given by $A_1\oplus A_2/\{(f_1(x),-f_2(x))\mid x\in A_3\}$.
Can anyone provide me with a proof, or give a sketch of proof that might point out which step I fail to see just yet?
 A: Take $A' \to A \to A/A'$, the first map is the inclusion and the second is the quotient projection. Take then $B' \to B \to B/B'$, the maps as above. These are both exact sequences, which means $\operatorname{im}(\text{inclusion}) = \ker(\text{projection})$. You should notice that $(\phi', \phi, \phi'')$ is a morphism of exact sequences, which means that this triple makes the obvious diagram commute.
Now, you may check that the sequence $B' \to P \to \operatorname{coker}(i)$ is exact, if $P$ is the pushout of the inclusion $A' \subseteq A$ along $\phi'$ and $i$ is the standard inclusion of $B'$ into the direct sum you mention. If you put the two diagrams together (the one that describes the map $(\phi', \phi, \phi'')$ and the one with $(\phi', j, k)$, where $j\colon A \to P$ is the standard inclusion and $k\colon A/A' \to \operatorname{coker}(i)$), you notice that there is also a map form $B$ to $P$ because of the universal property of $P$. As you should know the universal map is an iso, so $B \cong P$. Then you notice that $\operatorname{coker}(i)$ is iso to $B/B'$, because the inclusions $B' \subseteq B$ and $B' \subseteq P$ differ by an iso. This means that your square is in fact a pushout.
This is a succession of iff-s, so your claim is proved. This should be so much easier if you write down the diagrams I mention, which I cannot do here, since it looks like mathjax does not support xypic, and I'm not familiar with any other way of writing commutative diagrams.
Clarification: I understand this is an exercise in category theory and I didn't use any strictly categorical methods, but you should notice that the category of abelian groups is an abelian category and this is actually done in utter generality in any abelian category if, instead of quotients you take cokernels.
EDIT: Here's the diagram I was talking about. 

