Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

TWebbrowser : How to scroll

Posted on 2001-07-16
2
294 Views
Last Modified: 2010-04-06
this might be a well knowed one, but here is what I try to do :
After navigating to a page, I would like to scroll to a relevant part
of the document.

I couldn't find ou how to do this.

if somebody has a clue?

thanks
0
Comment
Question by:mhervais
2 Comments
 
LVL 17

Accepted Solution

by:
inthe earned 150 total points
ID: 6286636
hi mark,
easiest way is to use named anchors in the html document then enter full url.

ie:

http://www.microsoft.com/page1.html#anchor1

or if you want to use the scroll method you can ..
example:

procedure TForm1.Button1Click(Sender: TObject);
begin
//sideways
EmbeddedWB1.OleObject.Document.parentWindow.scrollBy(100,0);
//and down
EmbeddedWB1.OleObject.Document.parentWindow.scrollBy(0,200);
end;

procedure TForm1.FormCreate(Sender: TObject);
begin
EmbeddedWB1.Go('http://www.experts-exchange.com');
end;



if you go to msdn.microsoft.com (cant remember exact url of page)and look for dhtml methods ,theres a listing of  different methods you can use of ie document object ,i would asume most will be carried forward to ie6.(not tested it yet)

Regards Barry

0
 
LVL 4

Author Comment

by:mhervais
ID: 6286762
This does it great.

thanks Inthe
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction The parallel port is a very commonly known port, it was widely used to connect a printer to the PC, if you look at the back of your computer, for those who don't have newer computers, there will be a port with 25 pins and a small print…
Creating an auto free TStringList The TStringList is a basic and frequently used object in Delphi. On many occasions, you may want to create a temporary list, process some items in the list and be done with the list. In such cases, you have to…
This video shows how to quickly and easily add an email signature for all users on Exchange 2016. The resulting signature is applied on a server level by Exchange Online. The email signature template has been downloaded from: www.mail-signatures…
Established in 1997, Technology Architects has become one of the most reputable technology solutions companies in the country. TA have been providing businesses with cost effective state-of-the-art solutions and unparalleled service that is designed…

860 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question