Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
 
  HOME    TRACKER    Visual Basic




How To Stop WebBrowser Control To Resize Itself


Hi !

I have a lil program that has a webbrowser and sometimes I surf to webpages that have the script to resize my browser window to be full screen or reduced, so it makes my webbrowser the size of my form....arg!! how can i disable this autoresize so that when it tries to resize my webbrowser, it will either not do anything or go back to teh original size??

Here is an example of a site that resize the WebBrowser control:
http://www.smalltiger.com/unverredeplus/enter.htm

Thank




View Complete Forum Thread with Replies

See Related Forum Messages: Follow the Links Below to View Complete Thread
How To Stop Auto Resize In Webbrowser Control
i have a lil program that has a webbrowser and soemtimes i surf to webpages that have the script to resize my browser window to be full screen, so it makes my webbrowser the size of my form....arg!! how can i disable this autoresize so that when it tries to resize my webbrowser, it will either not do anything or go back to teh original size??

How To Stop The Resize Of A Webbrowser Window.?
Hi!
How do i turn off the ability to resize the webbrowser window from a script in the
page?

/Jimmy

WebBrowser Control Disable Resize
I use a WebBrowser control in several of my apps and have a very anoying problem.

When a user goes to some sites using the WebBrowser control the site resizes the control and ruins the form the webbrowser is on. The webbrowser control max's to the form size...

I have been searching for weeks trying to find a way to prevent pages from resizing the webbrowser control and still can't find a way to do it short of telling the user to disable javascript before using the program.

Does anyone know of a way to either prevent resizing of the webbrowser control or a way to capture something and know when the webbrowser control is resized so I can set it back to it's old size?

Hmmmmmm. I really hope that all made some sense.

Re's
Rob

How To Resize HTML Contents Using Webbrowser Control?
Hello.

I have limited knowlege of web apps so forgive me.

I have a VB6 app that uses a webbrowser control to open a website. The web site has a subsequent popup window that contains a datagrid. I assume this is the html document in the web browser.

When using Internet explorer the user can resize the datagrid window. In doing so the datagrid within the window will resize accordingly to take up the entire area on the window.

I have two problems:

1) In my VB6 app I capture the datagrid window using the newWindow2 event(the new window is sent to a webbrowser control on a seperate form) I need to initialize this new form to the same size of the datagrid within the html document of the webbrowser control. How do I do this?

2) When I resize my new form I want the datagrid within the html document of the webbrowser control to resize accordingly. How do I do this?

Any help would be greatly appreciated.

Thanks

Resize Webbrowser Control To Size Of Web Page?
Is there any way the webbrowser control can be resized to the web page so there are no scroll bars?

What I am trying to do it resize the webbrowser control to the size of the web page and the webbrowser control is in a picturebox control. Then I am going to use some code I found that captures and saved the picturebox and the contents to an image file. This way I have the whole web page saved as an image.

Any suggestions?

Thanks!

Stop Dragging Links From Webbrowser Control
Hi all,
i'm creating a securelink browser application using
WebBrowser cotrol in VB6.
Our requirment is that no one can't do drag and drop
a hyperlink out side the application ,as one can do
with other browsers.
so how can i do this ,plz help me.

Thanks

Stop Webbrowser Control From Taking Windows Focus
i have a web browser control on my form and every time it does something the window its in get brought to the front of the screen even if the user has it minimized or in the back. Is there any way to stop this?

How Do I Stop Pages Browsed In Webbrowser Control Ending Up In IE's History Folder?
How do i stop pages browsed in webbrowser control ending up in IE's history folder?

Is there any way besides deleting the pages from the history after they have been browsed.

Thanks.

Stop A Webbrowser Control From &"clicking&"
hi guys

does anybody know if theres a way to stop the a microsoft internet control (web browser) from making that clicking sound every time it refreshes/loads a page?

alternately, is there a way to get the HTML source of a webpage WITHOUT using any extra ocx's that the user of my program may not have?

a module perhaps?

thanks!

Stop Resize
Can i physically stop my form from being resized under a certain size.

Cheers
ILMV









Added [RESOLVED] to thread title and green "resolved" checkmark - Hack

Stop From From Resize
Right but i dont want to stop the form from being resized totally, but i dont want the form being too small.

How would i do this

Cheers
ILMV

Stop The Resize?
how would i stop the resize. i want to make a limet on how small they can make the form?

Stop Resize
How do i stop my Active X control from being able to be resized at design time, when it is being used in a project (not when the control is being made).

Stop Resize Form
how could i stop users from resizing the form??

Is There Any Way To Stop Window-Resize Animation For My Form Only ?
Is there any way to stop Window-Resize Animation for my Form only ?

I'm changing the Form from vbMaximized/vbNormal mode to fullscreen-mode. The animation looks bad.


VB Code:
Private Sub cmdFullScreen_Click()     If IsFullScreen Then 'change to Maximized            RemoveTitlebar Me.hwnd ' This Sub removes titlebar at runtime        Me.WindowState = vbMaximized        IsFullScreen = False            Else            Titlebar False, Me.hwnd        Me.WindowState = vbNormal ' A maximized/Minimized form        '                           Can't be moved        Me.Move 0, 0, Screen.Width, Screen.Height        IsFullScreen = True        End If End Sub

Stop TextBox Flickering Form Resize
Hi
can anyone suguest any idea or may have some example code on how I can stop Flickering of a textbox when resizeing a form.

Any help whould be greatfull.

How To Stop Resize When User Dbl Clicks On Form's Caption Bar
I'm running  VB5 App using Access '97.  My main form is maximized on the desktop with no min button.  The form does not allow resizing or moving.   No one is supposed to be minimizing this application.  Network administrator's policy.

Somebody in clerical figured out that double clicking in the form's caption bar will resize the form  and allow the user access to their Window's Start Button.  Word spread. Users are now launching other application's without exiting mine first.  How can I stop that resize event from occurring and force them to exit my app first?

Webbrowser Resize
I have a web browser in my project. It is Webbrowser1 I can not figure out how to keep it sized. I want it to be fullscreen when the window is in normal state, or maximized state, basicly i want it to stay the same no matter how the size it. Any suggestions?

Stop Webbrowser Pop-ups
hi

i have webbrowser on a form, and i navigate to a link. I want to stop ANY pop-ups that may appear.
Anybody has any ideas...?

Thanx in advance

WebBrowser.Stop!
In a WebBrowser project, I have this simple code in the Click event function of a Picture to stop the browser from downloading the entire web page:
VB Code:
Private Sub picStop_Click()    picStop.Picture = LoadPicture(App.Path & "ImagesStop2.gif")    Me.wWeb.Stop    'sbrWeb is the StatusBar    sbrWeb.SimpleText = "Done"End Sub
Note that pressing the Esc key on the keyboard will also stop the page from downloading.

Now what is happening is if a web page has lots of graphics & textual content (thereby taking more time to download), if the Picture is clicked (or Esc is pressed) to halt the download, the browser hangs for around 40-50 seconds.

First of all, what's causing the browser to hang & secondly, how do I avoid that?

Restricting Resize With Webbrowser
im using the webbrower control and some pages resize the window and it takes over the whole form and really screws things up

so how do i stop it from doing this?

Webbrowser Resize And Navigate
I have to make a webbrowser control to resize when I resize the form.
When I resize the webbrowser I need its content being refreshed.

I tried with this code, but it doesn't resize, maybe because it refreshes too many times at once:


Code:
Private Sub Form_Load()

WebBrowser1.Navigate "www.google.it"

End Sub

Private Sub Form_Resize()

WebBrowser1.Width = Me.ScaleWidth
WebBrowser1.Height = Me.ScaleHeight

WebBrowser1.Navigate "www.google.it"

End Sub


I also thought to catch the mouse click on the form border to know when it's released and to refresh the browser in that case, but I don't know how to do it.

Detection Of Webbrowser Resize
I have a web browser control on a Visual Basic

What is the easiest way of detecting when the window
has changed size (caused by a window.resizeTo in Javascript)
and hence obtaining the resized window size??

Override Window Resize In Webbrowser
i have a lil prog with a webbrowser and some of the pages that it surfs to have auto window resize in thier HTML code, and it completely screws up my whole form cuz it maximizes to that size and i cant function properly...anyone know anything i can do to avoid this?

Can I Resize Webbrowser To Size Of Web Page?
I doubt this can be done but it never hurts to ask!

Is there any way the webbrowser control can be resized to the web page so there are no scroll bars?

What i am trying to do it resize the webbrowser control to the size of the web page and the webbrowser control is in a picturebox control. Then I am going to use some code I found that captures and saved the picturebox and the contents to an image file. This way I have the whole web page saved as an image.

Any suggestions?

Thanks!

Webbrowser Stop Flash Or Sound
Hey, quick question. I know it's been asked before because I searched, but I never really found a straight answer that worked, so I hope you guys don't get pissed for me re-asking.

I have a vb6 program that uses webbrowser to visit a web page similar to youtube (Plays .flv files and such). The thing is, I want to listen to music while the program is running, so can I either
A) Mute the sound of just the webbrowser or just that program. I don't care about the click sounds or whatever, I just don't want those flv videos to play the sound.
or
B) Can I somehow disable flash just for that instance of IE? I don't want this to affect IE on my entire comp, but just for my program. I realize that the movies won't play, but that doesn't matter. I just need the flash not to load so that the sounds won't play from the movies.

Any help would be appreciated. Also, if you know of a creative way to solve the issue other than the choices I have thought of, feel free to post that too.

Thanks in advance,
-Greatness

Stop Going Back In A Webbrowser If On Last Page?
im making a webbrowser just for the fun of it, and i'm having a problem.

if the user clicks back when the browser cant go back no more as there are no more pages before the one they are on, or forwards as they cant to forwards anymore, they get an error.. how to i remedy this so they cant click the back and forwards buttons when they cant go back or forwads?

How To Stop The Sound Webbrowser Produces
I have a webbrowser control which I use to navigate by clicking (by code) some links. The webbrowser control is using InternetExplorer and InternetExplorer produces a "click" sound when we click on a link or a button.

How can I avoid that? I just need it to be silenced.

Stop The WebBrowser From Downloading The Graphics, ...
How can I stop the WebBrowser from downloading the graphics, Java classes, etc? I just need the text but as a Document object so I can eazy access its tags.
Or, which is the best way to get the "Document" object from a URL so I can access the TAGS? Can this be done without using the webbrowser control?
If I use the Inet control to get the source how can I build the Document object?
ThanX.

Stop Media Player & Switch To WebBrowser
I have a program which I want to open with an avi video. I want to be able to stop the media player at any time by clicking on Command button 7 or Command button 4 (each will open a separate web page).
Problem right now is when the program runs, when I click on the Command buttons the media player continues to play and I can't view the webbrowser. I know this is a simple question, but you guys are my tutors!


Also, any suggestions you have for making this better I'd appreciate.



Sub List()
Private Sub Form_Load()
MediaPlayer1.FileName = "http://mywebsite.edu/aearly/movies/mpa1.avi"
End Sub

Private Sub Command7_Click()
Call WebBrowser1.Navigate("http://www.nku.edu/~mpa/")
End Sub

Private Sub Command4_Click()
Call WebBrowser1.Navigate("http://www.nku.edu/~gradprog/graduate_application.pdf")
End Sub

Private Sub Command2_Click()
MediaPlayer1.FileName = "http://mywebsite.edu/aearly/movies/mpa1.avi"
End Sub

Stop Java Script In Form1.WebBrowser
Is there a way to stop javascript from executing inside my webbrowser control.

How Can You Get A Webbrowser To Navigate To A Page, Then Make It Stop Immideately?
WB.Navigate "http://www.vbforums.com"
do:doevents:loop until wb.readystate = 3 or wb.readystate = 4
wb.stop

thats what im using now - it works, but it uses 100% cpu, and its not good for multithreading

i have 5 timers, each of them with interval 1 and each of them have this code:
if wb.readystate = 3 or wb.readystate = 4 then
wb.stop
wb(x).navigate "http://www.vbforums.com"
end if

and this way, i can 'multithread'. however, this causes the webbrowser to use a lot of cpu and resources..

is there anyway to simply stop the browser with a better method than what im using?
wb.navigate site
wb.stop
will not work, as the browser must be properly initialized..

i know it sound strange, but does anyone know?

Why Does Trapping OnClick In Document Stop Click Actions Happening In WebBrowser?
I am developing a VB.NET application with the WebBrowser control. I need to record user events, and play them back later. I have already built a generic document event handler and made that capture onClick events (see below), but the normal action of the onClick is not happening in the WebBrowser itself, e.g. dropping down a SELECT, or setting focus in an INPUT.text.

This is totally doing my head in, any ideas anyone?

Code: Private Sub AxWebBrowser1_DocumentComplete(ByVal sender As Object, ByVal e As AxSHDocVw.DWebBrowserEvents2_DocumentCompleteEvent) Handles AxWebBrowser1.DocumentComplete
        Dim domDocument As mshtml.HTMLDocument = DirectCast(AxWebBrowser1.Document, mshtml.HTMLDocument)
        Dim domEvents As mshtml.HTMLDocumentEvents2_Event = DirectCast(domDocument, mshtml.HTMLDocumentEvents2_Event)
        AddHandler domEvents.onclick, AddressOf domEventOnClick
    End Sub

    Private Function domEventOnClick(ByVal e As mshtml.IHTMLEventObj) As Boolean
        Debug.WriteLine("-------------------------------------------------------------------")
        Debug.WriteLine("type: " & e.type)
        Debug.WriteLine("srcElement.tagName: " & e.srcElement.tagName)
        Debug.WriteLine("srcElement.id: " & e.srcElement.id)
        Debug.WriteLine("srcElement.innerHTML: " & e.srcElement.innerHTML)
        Debug.WriteLine("srcElement.className: " & e.srcElement.className)
    End Function



Edited by - davidgreenmoor on 9/20/2002 1:06:52 AM

How To Make The Webbrowser Control (and Just The Webbrowser In My Form) Offline?
wb.Offline = True
wb.Navigate "www.excite.com"

wont work.. itll still load excite (or any other site, doesnt matter if its cache or not)

anyone know how to prevent this?

also, how can you stop that errorbox saying 'cant load page because browser is offline' with the 2 options saying 'connect' or 'stay offline'? i dont want it popping up dozens of times when i try to visit a site in the webbrowser

How Can I Stop Users From Reaching My Site Except Users Of My Own Browser?-WebBrowser
Hello,

I wrote A Web Browser using Visual Basic 6 Web Browser Control. Everything is working great, the only problem is I want to stop all users from being able to type my domain in the address bar from any browser! I want to make the only way to access my site via my browser.

How can I do that?

Any help would be greatly appreciated.

How Can I Stop Users From Reaching My Site Except Users Of My Own Browser?-WebBrowser
Hello,

I wrote A Web Browser using Visual Basic 6 Web Browser Control. Everything is working great, the only problem is I want to stop all users from being able to type my domain in the address bar from any browser! I want to make the only way to access my site via my browser.

How can I do that?

Any help would be greatly appreciated.

Can I Resize An Ocx Control?
Hi there,

Im creating an ocx control is basically very similar to a picture box, (will have other controls inside it etc.) anyway my question is, is it possible or how do i, allow my ocx to be resized once its on another form?, ie. i dynamically create it on a form, then want the user to be able to drag it larger like a form basically (in same way)? any ideas?, ive tried exposing the resize event but that doesnt ever get called?, HELP PLEASE!!

ive also thought of having labels on th right and bottom of my ocx then when the user drags those it resizes it , but practically im not sure if thats a possible solution...thanx

Resize Control
Hello guys,

I've searched 20 hours of my life to find a component that does the following to me:
A component that automatically resizes my forms and controls, as I want.A component that can take control over the width and height of my controls / forms and so on when the resolution of the screen changes
The first point is no problem. Several perfect controls I have found for that. But the second is more important to me. Guess, I've made a program with one form, with a textbox and a button. I've developed it on a resolution of 1024 x 768. The screen has(for example) a width of 1024 pixels, and a height of 768. When I change the screen resolution to 800 x 600, I want the form to resize so, that it shows exactly the same to the user as on a resolution of 1024 x 768.

Can anybody help me to find such a control? I don't like to write tricky code for doing that to myself (it also has to deal with resetting the controls to the right position on the screen and so on).

Thnx in advance

Control Resize
Does anyone know how you can tell a control that it is in design mode, when it is actuially in Runtime mode.

The reason for this odd request, is that we are developing a customizable user interface tool, and we want users to be able to move and resize the controls just like we can in the VB interface, i.e. when you click on the control the size boxes appear around the control showing where you can resize the control.

Any help would be great.

Steve.

Control Resize
Is there a way at run time to allow a user to resize controls such as the msflexgrid by pulling the corner as with a form



Joolz

Resize Control
I have a actixeX component (ocx) with a frame and 2 picture boxes and som line and captions.
How can I be able to resize the ocx on a form

What Resize Control To Use/Buy
I need to add resize control to my app to make it screen independent. I have seen several on google priced anywhere from $79 to >$500. Does anyone have any experiences with any of the ones out there? Any recommendations?

Thanks,
Dave

Resize SSTab Control
I am using an SSTab Control on my form. Question is how do I get it to resize to match the form size? I have the form set to show maximized when loaded, but the SSTab Control doesn't resize to fit the form. (The SSTab Control doesn't maximize, but the form does)

Is there some code I can put in the form load event to get the SSTab control to resize and fill the entire form?

How To Resize Control Correctly?
I have a resizeable form with menu & status bar and I want to resize the controls(picturebox) in the form, how do I find the size of the menu bar programmatically? Im can put a static size but when I move from Win2k to XP the picture box is too large and overlaps the statusbar...

Control Resize After Runtime
I'm tring to make a program that works kinda like VB. I want the user to be able to place controls on the form and resize them like VB does. I am aware that i need a control array so i can load new ones, but my problem is the resizing by clicking. Any help would be great!

ŁĄ~Jaywalker~ĄŁ

Select And Resize Control
Hi
If i click the Button at runtime i want to draw textboxes after that i want select that textbox and resize that
For example in vb
(In toolbox select textbox and draw into form) like that i want

Resize Image Not Control
I do not want to resize image control or picturebox control.
I want to fit the image to the size of Control. ( image or picture box )

Resize Control Within Form
I have found many examples on there regarding how to resize a control when a form resizes. But I'll be dammed if I can get any of them to work. Surely, there must be a standard formula for working this out?

Textbox.left=100
textbox.top=1000
textbox.height=5000
form.height=10000
form.width=10000

All I want to do is resize the textbox control while keeping the the left and top position intact.

Is there a standard formula for this? I got the width (kinda) working with:

textbox.move 100,1000,textbox.Width + ((Me.ScaleWidth - textbox.Width) - 200),??

But the number 200 was just guess work.

Thanks.

ListView Control - Resize
Can I intercept a resize on a column in a listview and stop it?

I don't want to subclass the control, or use any API . . . .

And I'm too lazy to investigate properly . . .

Copyright © 2005-08 www.BigResource.com, All rights reserved