ShowModalDialog displays blank window - InfoPath Dev
in

InfoPath Dev

Use our Google Custom Search for best site search results.

ShowModalDialog displays blank window

Last post 07-17-2018 08:43 AM by jd422. 0 replies.
Page 1 of 1 (1 items)
Sort Posts: Previous Next
  • 07-17-2018 08:43 AM

    • jd422
    • Not Ranked
      Male
    • Joined on 07-22-2010
    • Pennsylvania, USA
    • Posts 6

    ShowModalDialog displays blank window

     I have an onClick event routine (vbScript) for a button as follows:

     Sub TestButton1_OnClick(eventObj)
       Dim retVal
     
       retVal = XDocument.UI.ShowModalDialog("DiaglogHTML.htm", XDocument)

       MsgBox "retVal =""" & retVal & """"

    End Sub 

     The html file contains:

     <html>
       <head>
          <script language="jscript" type="text/jscript">
             function Initialize()
      {
       window.alert("Hello world!");
      }
          </script>

          <title>Custom Dialog Box</title>
       </head>

       <body onLoad="Initialize()">
          This is your modal dialog box.
        </body>
    </html>

     When I preview the form in InfoPath designer, all I get is a blank window when I click on the button.

     Clicking on the little red X at the top right of the blank window, the vbScript displays the MsgBox as expected which shows blank quotes (as expected) for the return value due to the fact that I don't know how to return a value. 

    I am using the most minimal amount of coding, etc. and I can't even get the dialog box to be anything but a blank window.

    Can anyone provide some guidance? 

Page 1 of 1 (1 items)
Copyright © 2003-2018 Qdabra Software. All rights reserved.
View our Terms of Use.