web browser/mshtml problem

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Tam Inglis

    web browser/mshtml problem

    Got a problem.

    Setting design mode on and making changes to an existing HTMLDocument makes
    subsequent page changes to throw up dialog

    ----------------
    Title has application path and file name,
    "This document has been modified. Do you want to save changes?"
    "Yes: Saves your changes"
    "No: Discards your changes"
    "Cancel: Keeps this document open"
    Yes/No/Cancel buttons.
    -----------------

    How can i supress this?

    Bascially I'm loading the contents (<body>) from a text file, wrapping it in
    html headers and saving to a temp.html which i then
    ..Navigate({pat hto}\temp.html) to. Works well.

    When done i extract the body content and save to its original source file.
    So i dont care for this message.

    I cant call document.Exec(" SaveAs",false,{ pathto}\temp.ht ml) as this causes
    the FileSave dialog to appear. The third argument is ignored as part of the
    underlying security policy (cos webpages could upload to your HD at that
    point i suppose).

    Am stuck. Any help any of you can give this would be appreciated.


  • Nicholas Paldino [.NET/C# MVP]

    #2
    Re: web browser/mshtml problem

    Tam,

    If you go to the options dialog in VS.NET, under the "Environmen t"
    folder and the "Documents" section there is a textbox labled:

    Detect when file is changed outside of the environment

    Make sure this is unchecked, and when the file is changed, it will not
    give you that message.

    However, this does this for all files, so be careful.

    Hope this helps.


    --
    - Nicholas Paldino [.NET/C# MVP]
    - mvp@spam.guard. caspershouse.co m

    "Tam Inglis" <joseph.inglis@ btclick.com> wrote in message
    news:br4fpd$pmb $1@sparta.btint ernet.com...[color=blue]
    > Got a problem.
    >
    > Setting design mode on and making changes to an existing HTMLDocument[/color]
    makes[color=blue]
    > subsequent page changes to throw up dialog
    >
    > ----------------
    > Title has application path and file name,
    > "This document has been modified. Do you want to save changes?"
    > "Yes: Saves your changes"
    > "No: Discards your changes"
    > "Cancel: Keeps this document open"
    > Yes/No/Cancel buttons.
    > -----------------
    >
    > How can i supress this?
    >
    > Bascially I'm loading the contents (<body>) from a text file, wrapping it[/color]
    in[color=blue]
    > html headers and saving to a temp.html which i then
    > .Navigate({path to}\temp.html) to. Works well.
    >
    > When done i extract the body content and save to its original source file.
    > So i dont care for this message.
    >
    > I cant call document.Exec(" SaveAs",false,{ pathto}\temp.ht ml) as this[/color]
    causes[color=blue]
    > the FileSave dialog to appear. The third argument is ignored as part of[/color]
    the[color=blue]
    > underlying security policy (cos webpages could upload to your HD at that
    > point i suppose).
    >
    > Am stuck. Any help any of you can give this would be appreciated.
    >
    >[/color]


    Comment

    • Tam Inglis

      #3
      Re: web browser/mshtml problem

      Sorry, should have been plainer.

      Its the webbrowser that generating these errors, not VS.NET :-)


      "Nicholas Paldino [.NET/C# MVP]" <mvp@spam.guard .caspershouse.c om> wrote in
      message news:O8GyHPmvDH A.3216@TK2MSFTN GP11.phx.gbl...[color=blue]
      > Tam,
      >
      > If you go to the options dialog in VS.NET, under the "Environmen t"
      > folder and the "Documents" section there is a textbox labled:
      >
      > Detect when file is changed outside of the environment
      >
      > Make sure this is unchecked, and when the file is changed, it will not
      > give you that message.
      >
      > However, this does this for all files, so be careful.
      >
      > Hope this helps.
      >
      >
      > --
      > - Nicholas Paldino [.NET/C# MVP]
      > - mvp@spam.guard. caspershouse.co m
      >
      > "Tam Inglis" <joseph.inglis@ btclick.com> wrote in message
      > news:br4fpd$pmb $1@sparta.btint ernet.com...[color=green]
      > > Got a problem.
      > >
      > > Setting design mode on and making changes to an existing HTMLDocument[/color]
      > makes[color=green]
      > > subsequent page changes to throw up dialog
      > >
      > > ----------------
      > > Title has application path and file name,
      > > "This document has been modified. Do you want to save changes?"
      > > "Yes: Saves your changes"
      > > "No: Discards your changes"
      > > "Cancel: Keeps this document open"
      > > Yes/No/Cancel buttons.
      > > -----------------
      > >
      > > How can i supress this?
      > >
      > > Bascially I'm loading the contents (<body>) from a text file, wrapping[/color][/color]
      it[color=blue]
      > in[color=green]
      > > html headers and saving to a temp.html which i then
      > > .Navigate({path to}\temp.html) to. Works well.
      > >
      > > When done i extract the body content and save to its original source[/color][/color]
      file.[color=blue][color=green]
      > > So i dont care for this message.
      > >
      > > I cant call document.Exec(" SaveAs",false,{ pathto}\temp.ht ml) as this[/color]
      > causes[color=green]
      > > the FileSave dialog to appear. The third argument is ignored as part of[/color]
      > the[color=green]
      > > underlying security policy (cos webpages could upload to your HD at that
      > > point i suppose).
      > >
      > > Am stuck. Any help any of you can give this would be appreciated.
      > >
      > >[/color]
      >
      >[/color]


      Comment

      Working...