Re: HTML doc save dialog

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance

From: joseph.inglis (joseph.inglis_at_btclick.com)
Date: 06/30/04


Date: Wed, 30 Jun 2004 13:40:00 +0000 (UTC)

Thanks Shakir... that sounds good.

Im right in the middle of something else but as you can be sure, I'll be
doing this in the next couple of hours... will report back then.

regards

Tam

"Shakir Hussain" <shak@nodomain.com> wrote in message
news:eCaw3dmXEHA.648@TK2MSFTNGP10.phx.gbl...
> Joseph,
>
> Thanks for ellaborating the problem
>
> If you replace or do something with the tags, the modified flag will be
set
> to true in the HTMLDocumentClass even if its same data, and thats why you
> get the save dialog. There is no way to supress them.
>
> To get through with this problem
>
> 1. After getting the string from database do not set the string to
> body.InnerHTML
> 2. Instead flush the string to a temprory "test.html", adding proper start
> and end html tags.
> 3. Navigate this temp file using browser component
> 4. In the document complete event of browser, get the new document again
>
> //refresh the object again
> pHTMLDoc = (HTMLDocumentClass)DesignBrowser.Document;
>
> 5. Since its a new navigation, the browser will discard the old document,
> and you wont get that save dialog.
>
> There are few options still left to try out. Let me know if this doesnt
work
>
>
> Shak
> (Houston)
>
>
> "joseph.inglis" <joseph.inglis@btclick.com> wrote in message
> news:cbt1bo$5fl$1@sparta.btinternet.com...
> > Nope, been around this road. I do have a toolbar and I do have methods
for
> > cut/paste/indent/bullets etc as you describe.
> >
> > But not for save. Im not doing that.
> >
> > What im doing is this. Im only actually saving the part inbetween <body>
> > tags in a database. In order to refresh the page I get a an existing
entry
> > from the database, create a string that represents the entire html
> document
> > content and set this to the
> > HTMLDocumentClass.body.innerHTML
> >
> > property. I do the reverse and parse out when changing documents. So
> > essentially its the same document, in fact, totally. This all works
> smoothly
> > here but performing this action on the clients machine generates the
> "Save"
> > dialog.
> >
> > Its been driving me nuts for weeks. I hope im being a bit clearer, I
> should
> > have been in the first place so I apologise.
> >
> > Tam
> >
> > "Shakir Hussain" <shak@fakedomain.com> wrote in message
> > news:OmfaQkiXEHA.3112@tk2msftngp13.phx.gbl...
> > > Try using
> > >
> > > OLECMDEXECOPT_DONTPROMPTUSER as parameter before saving in ExecWB
> > function.
> > >
> > > --
> > > Shak
> > > (Houston)
> > >
> > >
> > > "joseph.inglis" <joseph.inglis@btclick.com> wrote in message
> > > news:cbsl6o$s86$1@titan.btinternet.com...
> > > > Thanks for your reply shak... I already do that.
> > > >
> > > > web1.Navigate2(ref o, ref oEmpty, ref oEmpty,ref oEmpty, ref
oEmpty);
> > > >
> > > > web1.NavigateComplete2+=new
> > > >
> > >
> >
>
AxSHDocVw.DWebBrowserEvents2_NavigateComplete2EventHandler(web1_NavigateComp
> > > > lete2);
> > > >
> > > > Songs will be sung about the person that can solve this for me ;-)
> > > >
> > > >
> > > >
> > > > "Shakir Hussain" <shak@fakedomain.com> wrote in message
> > > > news:u%23aIwvgXEHA.3016@tk2msftngp13.phx.gbl...
> > > > > Instead of using Navigate method, use Navigate2 method in browser
> > > object.
> > > > >
> > > > > --
> > > > > Shak
> > > > > (Houston)
> > > > >
> > > > > "joseph.inglis" <joseph.inglis@btclick.com> wrote in message
> > > > > news:cbs5fj$lrn$1@titan.btinternet.com...
> > > > > > I have a web browser object on a form which I have set to edit
> mode
> > > and
> > > > > use
> > > > > > the UCOMIConnectionPointContainer interface to hook in and catch
> > > events.
> > > > > >
> > > > > >
> > > > > >
> > > > > > All working sweetly.
> > > > > >
> > > > > >
> > > > > >
> > > > > > Except there are instances where i rewrite the Document.Content
> and
> > > the
> > > > > > first keypress results in a default windows "Content has
changed,
> > > Save"
> > > > > > dialog.
> > > > > >
> > > > > >
> > > > > >
> > > > > > How can I suppress this? This does not happen on my machine here
> and
> > > is
> > > > > only
> > > > > > apparent on clients machine. It did at one point during
> development
> > > many
> > > > > > months ago then stopped so... ive maybe done something my end...
> but
> > > > what?
> > > > > >
> > > > > >
> > > > > >
> > > > > > All used .dlls are with the application and were both on .NET
1.1
> > > > > >
> > > > > >
> > > > > >
> > > > > > Tam
> > > > > >
> > > > > >
> > > > > >
> > > > >
> > > > >
> > > >
> > > >
> > >
> > >
> >
> >
>
>



Relevant Pages

  • Re: Trouble escaping / Misc nightmare
    ... you're talking about inserting values into a database. ... but any data put into a query string should be ... My question is whether the apostrophe you see is stored as an apostrophe ... correct in the browser, depending on what phpMyAdmin does when displaying ...
    (comp.lang.php)
  • Re: Javascript Browser Sniffer
    ... That is an old lasting "tradition" to have UA's string syntax close to ... to extract all of it one needs a sophisticated AI - or a huge database ... My beloved one remains the mark in the old AOL packages. ... their browser version the string ended up with "DigitallyExt". ...
    (comp.lang.javascript)
  • Re: HTML doc save dialog
    ... If you replace or do something with the tags, the modified flag will be set ... After getting the string from database do not set the string to ... In the document complete event of browser, ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: Processor ID with php
    ... > person's browser identifier as seed. ... > know they've been there before because the same encrypted string will be ... > generated again and you can check for its existence in the database. ... Doing it the way with a pid is a guarenteed method, ...
    (comp.lang.php)
  • Re: Publish Report to Word - computed textbox value doesnt show
    ... the "computation" is a set of string substitutions. ... tags with data from various tables in the database, ... database, do the tag substitution, then display the result in the report. ...
    (microsoft.public.access.reports)