Ouch,
the statement <%= something%> is an equivalent to the statement <%Response.Write(something)%> and is used to write something onto the page. So, you should use the normal procedure like:
<%@ Language=VBScript %>
<HTML>
<HEAD>
<META NAME="GENERATOR" Content="Microsoft Visual Studio 6.0">
</HEAD>
<BODY>
<%
Dim rndnum
Randomize
rndnum = Int(Rnd()*(99999999-10000000+1)+10000000) ' generates random 8-digit number in a range between 10000000 and 99999999
%>
<P>
<% =rndnum%></P>
</BODY>
</HTML>
Good luck