...

View Full Version : showModalDialog Title Change...



kcanil
06-03-2005, 04:02 AM
Hey guys....I'm using JavaScript for creating a MOdalDialog box..My issue is i cannot change the Title of ModalDialog...It is staying same as "-- Web Page Dialog".....How can i modify the title of the dialog box??? Let me know guys....Thanks...


function fnRandom(iModifier){
return parseInt(Math.random()*iModifier);
}
function fnSetValues(){
var iHeight=oForm.oHeight.options[
oForm.oHeight.selectedIndex].text;
if(iHeight.indexOf("Random")>-1){
iHeight=fnRandom(document.body.clientHeight);
}
var sFeatures="dialogHeight: " + iHeight + "px;";
return sFeatures;
}
function fnOpen(){
var sFeatures=fnSetValues();
window.showModalDialog("showModalDialog_target.htm", "",
"title.text:'hello';font-size:10px;dialogWidth:50em;dialogHeight:50em")
}
</SCRIPT>

<FORM NAME=oForm>
Dialog Height <SELECT NAME="oHeight">
<OPTION>-- Random --
<OPTION>150
<OPTION>200
<OPTION>250
<OPTION>300
</SELECT>

Create Modal Dialog Box
<INPUT TYPE="button" VALUE="Push To Create"
onfiltered="fnOpen()">
</FORM>

A1ien51
06-03-2005, 04:12 AM
You can't

kcanil
06-03-2005, 04:19 AM
reallyy...i thiought there shudbe some workaround...hmmmm,...

enumerator
06-03-2005, 04:57 PM
The notification doesn't appear from a trusted application (such as mshta), but otherwise, the best you can do is include a <title>element</title> in the dialog document...



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum