You have several problems.
The main problem is that this code doesn't even compile correctly, as you are calling randomNum incorrectly when setting the label text.
The second problem is that this logic does not belong in the Page_Load method, It should be placed in an event handler for the control doing the postback (presumably a button click).
Third, your logic is way too complex. You are declaring variables that you don't need, and declaring them as the wrong type. Also, there is no need to call the Randon constructor twice.
Code:
using System;
public partial class Ques1 : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
}
protected void Button1_Click(object sender, EventArgs e)
{
int min = Convert.ToInt32(TextBox1.Text);
int max = Convert.ToInt32(TextBox2.Text);
Label1.Text = randomNum(min, max).ToString();
}
private int randomNum(int min, int max)
{
Random r = new Random();
int rnd = r.Next(10);
return ((max - min) * rnd / 10 + min);
}
}