This is my script :
<%
if (TempData["Resultat"] != null){
%>
<script type="text/javascript">
alert('<%: TempData["Resultat"]%>');
</script>
<%
}
%>
In this case pop-up is shown before page loaded, but i want that's appear after page is fully loaded. in Html it's looks like this :
<body onload="happycode() ;">
but i can't use it in MVC i got one master page for all my web application