Polynomial Remainder Theorem:
If we divide a polynomial f(x) by a factor (x – a), then the remainder will be f(a).
In your case, the remainder from dividing by (x-7) will be f(7)
f(7) = (7)^2 + k(7) -19
= 49 + 7k -19
= 30 + 7k
If you want the remainder to be -5, when set 30+7k equal to -5 and solve:
30 + 7k = -5
7k = -35
k = -5