Can I find out how much heat in temperature can a resistor give if I know its wire and its resistance value?
Reisitance value: 5k ohms.
Voltage I am going to pass is 240 V.

You are not going to &quot;pass&quot; voltage. You will apply the voltage to your load. The result will be that current will pass through the load.

How much heat does resistors dissipate?

The heat will be the electrical power (in watts) consumed by the resistor.
$$ P = VI = I^2R = \frac {V_2}{R} $$
Since you know V and R you can use the last option, \$ P = \frac {V_2}{R} \$.

Can I guess the temperature or do we have formula for calculating heat in temperature.

The temperature will stabilise at the point where heat losses to the environment or the matter you are heating equals the power input. You will probably have to experiment to find the resultant temperature.
The energy you put into the system will be \$ E = P \cdot t \$ and will be in joules (J) or watt-hours (Wh).