4. The number of integer solutions $(x, y)$ for the equation $\frac{1}{x}+\frac{1}{y}=\frac{1}{7}$ is ( ).
(A) 5
(B) 6
(C) 7
(D) 8
4. A.

When $x=7$, there is no solution.
When $x \neq 7$, $y=\frac{7 x}{x-7}$.
Thus, $(x-7)|7 x \Rightarrow(x-7)| 49$
$$
\begin{array}{l} 
\Rightarrow x=-42,6,8,14,56 \\
\Rightarrow(x, y)=(-42,6),(6,-42),(8,56), \\
(14,14),(56,8) .
\end{array}
$$

In summary, there are 5 solutions.