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




[VB6]Webbrowser && Right Click On A Link


i disabled the right click menu and i made my own menu...now i need a code for a button in the menu that when i click on a link it comes the menu "open in a new page"...can any1 help me?




View Complete Forum Thread with Replies

See Related Forum Messages: Follow the Links Below to View Complete Thread
[VB6]Webbrowser && Right Click On A Link
i disabled the right click menu and i made my own menu...now i need a code for a button in the menu that when i click on a link it comes the menu "open in a new page"...can any1 help me?

Webbrowser Javascript Link Click Help
I'm trying to "click" a link on a webpage using a vb program and the webbrowser control. I have searched this site and many others but with no help. I know how to click a standard link but the one I'm working on now is javascript.

Here is the code from the webpage that I'm trying to click.

Code:
<a class="pagingLink" href="javascript:__doPostBack('ctl00$cpMain$pagerTop','5')">Next &rsaquo;</a>


I got the program to work by using

Code:
WebBrowser1.Document.links(0).Click

and I would continue to go this route but the index of where that link is changes each page load. any ideas?

and this method does not work for me

Code:
WebBrowser1.Navigate "Http://www.mywebsite.com?javascript:__doPostBack('ctl00$cpMain$pagerTop','2')

Webbrowser Click Text Link
hi i'm loading a page with the webbrowser control and I need to click on a 'next' text link. its not part of a form and the actually href link is a '#' which means you have to automate a manual type click in away.

so how would i mouse click the next link or simulate a mouse click so the app can run in the background

Click A Link With Webbrowser Control
How can I click a link with the webbrowser control after I have navigated to a page?

How Can I Click On A Link With WebBrowser Control?
I have a page which has a frame with this source code:

Code:<HTML>
<HEAD>
</HEAD>
<BODY BGCOLOR=#000000 TEXT=#FFFFFF LINK=#FFFFFF VLINK=#FFFFFF leftmargin=0 topmargin=0 marginwidth=0 marginheight=0>
<IMG SRC="http://207.200.11.37/utopia/gr/uttitle.gif" WIDTH=80 HEIGHT=30 BORDER=0><FONT SIZE=-1>
<MAP NAME=menu>
<AREA SHAPE=rect TARGET=utomain HREF="/menu.cgi?" COORDS=1,3,80,15>
<AREA SHAPE=rect TARGET=utomain HREF="/council.cgi?" COORDS=1,16,80,28>
<AREA SHAPE=rect TARGET=utomain HREF="/explore.cgi?" COORDS=1,42,80,54>
<AREA SHAPE=rect TARGET=utomain HREF="/build.cgi?" COORDS=1,55,80,67>
<AREA SHAPE=rect TARGET=utomain HREF="/science.cgi?" COORDS=1,68,80,80>
<AREA SHAPE=rect TARGET=utomain HREF="/military.cgi?" COORDS=1,81,80,93>
<AREA SHAPE=rect TARGET=utomain HREF="/magic.cgi?" COORDS=1,107,80,119>
<AREA SHAPE=rect TARGET=utomain HREF="/thievery.cgi?" COORDS=1,120,80,132>
<AREA SHAPE=rect TARGET=utomain HREF="/attack.cgi?" COORDS=1,133,80,145>
<AREA SHAPE=rect TARGET=utomain HREF="/aid.cgi?" COORDS=1,146,80,158>
<AREA SHAPE=rect TARGET=utomain HREF="/readmsg.cgi?" COORDS=1,172,80,184>
<AREA SHAPE=rect TARGET=utomain HREF="/msg.cgi?" COORDS=1,185,80,197>
<AREA SHAPE=rect TARGET=utomain HREF="/forum.cgi?" COORDS=1,198,80,210>
<AREA SHAPE=rect TARGET=utomain HREF="/politics.cgi?" COORDS=1,211,80,223>
<AREA SHAPE=rect TARGET=utomain HREF="/status.cgi?" COORDS=1,224,80,236>
<AREA SHAPE=rect TARGET=utomain HREF="/scores.cgi?" COORDS=1,250,80,262>
<AREA SHAPE=rect TARGET=utomain HREF="/leaders.cgi?" COORDS=1,263,80,275>
<AREA SHAPE=rect TARGET=utomain HREF="/news.cgi?" COORDS=1,276,80,288>
<AREA SHAPE=rect TARGET=utomain HREF="/news.cgi?yesterday=true?" COORDS=1,289,80,301>
<AREA SHAPE=rect TARGET=utomain HREF="/dragon.cgi?" COORDS=1,302,80,314>
<AREA SHAPE=rect TARGET=utomain HREF="/pref.cgi?" COORDS=1,328,80,340>
<AREA SHAPE=rect TARGET=_blank HREF="http://games.swirve.com/utopia/help" COORDS=1,341,80,353>
<AREA SHAPE=rect TARGET=utomain HREF="http://games.swirve.com/utopia/help/faq.htm" COORDS=1,354,80,366>
<AREA SHAPE=rect TARGET=_top HREF="/logout.cgi?" COORDS=1,370,80,385>
</MAP>
<CENTER><IMG SRC="http://207.200.11.37/utopia/gr/newmenu.gif" USEMAP="#menu" HEIGHT=385 WIDTH=80 BORDER=0>
<a href="sidenogr.htm"><font size=1 face=verdana><B>No Graphics</B></FONT></A>
</BODY></HTML>

I want to the webBrowser to automatically click the HREF="/attack.cgi?" link. How can I do this? Also, remember this is in a frame, so I also need to know how to select a specific frame before attempting to click the link.

How Disable Shift+link-click In Webbrowser
please any one know how to disable the shift key with link-click in webbrowser control to stop open the new page in different browser

thanks

How Handle Click Event On Link In Webbrowser Control?
How handle click event on link in webbrowser control?

I use webbrowser control in VB. I want handle click on link.

WebBrowser: Open Link In Other WebBrowser
Hi

I have a question about the webbrowser control to which I haven't found an answer:

I have one form with two webbrowser objects (WebBrowser1 and WebBrowser2). The first WebBrowser loads an html site containing links. When I now click on one of these links, I would like the WebBrowser2 to open the page, the webbrowser1 should stay the same. How do I do that?

Any help is much appreciated....

Thanks
hajunk

WebBrowser Link
Hello, i have been searching for a while and I cannot find an example that works...

I have a webbrowser1 and webbrowser2 (default names).
In broswer1 im loading main.htm using the app.path command.

I want it when a user clicks a link within main.htm to load in browser2 instead of broswer1, so that they can view main.htm in browser1 and the newly clicked link in browser2 which are side by site.

Link Click
on my internet thingy, when I click a link... nothing happens, why not?

Click Link!
Assume that a web browser project has a Boolean variable named blnNavigated. The browser also has the Back & Forward buttons for users to navigate.

What I want is if a user clicks a link in a web page to navigate to another page, then blnNavigated should be set to True but if the user navigates using the Back or Forward button, then blnNavigated should be set to False. Setting blnNavigated to False can be done in the Back & Forward buttons' Click event function but how do I set blnNavigated to True if the user has clicked a link in the web page to navigate to another page?

Get URL From A Link With WebBrowser Control
Hi!

I have a webbrowser control in a form and when i click on a link it navigates to that link.

Can i get the URL of a link without navigate to it?

I wan't to store it in a variable.


The thing is that i wan't new windows to open in a new instance of my program instead of open in Internet Explorer.

WebBrowser1.NewWindow2 doesn't have a URL variable


/Erik

WebBrowser - Mouseover Link
Hello everyone (again),

I am testing out my programming skills (What little i have) by programming a simple Web Browser. I have got so far, but now I am stuck. I want make it so that on a mouse over of a link it show the link in the statusbar.

I've looked in the dropdown list of the webbrowser, but couldent see any that could help.

Thanks,
Jinx88.

Open Link In Webbrowser
Ok, pretty basic, might be something like " Blah.URL = "Whatever" " you know, something like that, but I need it to open my website in a coustom webbrowser, then I got to make another webbrower that you can use your own link, once again, that should be pretty easy.

Thanks

Get Link Name (webbrowser Control)
Ok, simple question.

How do I get the value between to <a> tags?

<a href="something">Get This Text</a>

Get URL From A Link In WebBrowser Control
Hi!

I have a webbrowser control in a form and when i click on a link it navigates to that link.

Can i get the URL of a link without navigate to it?

I wan't to store it in a variable.


The thing is that i wan't new windows to open in a new instance of my program instead of open in Internet Explorer.

WebBrowser1.NewWindow2 doesn't have a URL variable


/Erik

Webbrowser+link+function???
HI all, can anyone tell me if it is possible (and how) to check the value of a clicked link in the html and then call a function with the value of this link???


thanks

Click On Link By Program
I have a web site for example:
http://www.bbc.co.uk/
and now I wont click on "History"(left) by my program automatic


...
Dim adresa

adresa = "http://www.bbc.co.uk/"
Set ie = CreateObject("InternetExplorer.Application")
ie.navigate adresa

Do While ie.READYSTATE <> 4
DoEvents
Loop

ie.Visible = True

ie.Document.All("a_ID_link_or_I_dont_know").Click
Set ie = Nothing
...

(beginner)

Double Click Link
In my application I have a window that contains 400+ links, when you select a link ( website address ) you have to press a button to open the website, the code behind the button is:


Code:
ShellExecute Me.hWnd, "open", Combo1.Text, "", "", SW_SHOW Or SW_NORMAL


How can I make it so a user not only has to click the button to open a website, but can just double click one of the website addresses and it opens that website?

Thank you.

Click A Link On IE Browers
Hi, I was wondering how would I be able to click a link on IE?

VBscript....link Click ?
Hi! Please help to solve these problem:
I need to do this: when the user is clicking on the link...i need to write to a file and to link to program.exe wich the user want to download!

p.s: to write in a file I can, but i don't know how to know if the user clicked the link and then let him download the programm!

Plz help!thanks!

Click Link In Web Control
i added a web (IE) control to my project, and i want to make the browser click a link when i press a command button, how can i do it? i dont just want to navigate to the link, i want the browser to "click it". Is it possible?


~~~Dimava~~~

Can A Link In A Webbrowser Open A New Browser That's Not IE?
I have a webbrowser control in my application and in the page that loads on startup, there are links that open in new browser windows.

From what I understand, the webbrowser is just emulating IE, but is it possible to make the user's default browser open (instead of IE) when they click on links in the page?

If not, I'm thinking I'll just dynamically rewrite the html in the pages that load, so that all links open in the webbrowser control, and not a new browser...

any ideas?

thanks

Webbrowser Find Link With Changing Url
I have been trying to find and click
<a style="cursor: pointer;" onclick="if(!fbjs_sandbox.instances.a2437228683.bootstrapped)fbjs_sandbox.instances.a2437228683.boot strap();return fbjs_dom.eventHandler.call([fbjs_dom.get_instance(this,2437228683),function(a2437228683_event){a2437228683_doajax('inbox', 'http://74.86.142.203/~tearswep/human...;search=', '')},2437228683],new fbjs_event(event));">Next</a>

I'm not sure how I would navigate to it or 'click' the word next. But that's what I need to do.

I've tried

For Each Var In WebBrowser.Document.links
If InStr(1, CStr(Var), "Next") > 0 Then
WebBrowser.Navigate CStr(Var)
Exit Sub
End If
Next Var

and that hasn't worked. It worked to find the 'Logout' link which was similar looking. I am using VB6. Any help is appreciated thanks.

How Can You Highlight A Link In A Webbrowser Control?
Anyone know?

How about highlighting a link if it has been previously viewed?

Can I Run A Local Exe From A Link Through Webbrowser Control?
I have a webbrowser control and want to show a web page and when i click on some links, I want it to run an exe that is on the computer. When I just put the path and filename as the link, it asks me if I want to save or open the file. Is there a way of having it just open the file without asking and without changing the default settings of IE?

Thanks!

WebBrowser - Automatically Folow A Link
Is it possible to ... 'Sort of', "Automatically Click" a link of a page displayed in the WebBrowser object ?
(say the link I wanna click is in a string var. or something)


Thanks in Advance
Ram

I Need A Link In The WebBrowser Control To Run VB Procedure
I have a WebBrowser control displaying a webpage. I want the Command1_Click procedure to be run when a user clicks on a specific link on the webpage. Is this possible?

Run My Program When Click On Html Link
I want to add in registry values , so when i click on html link it open my program with link i click on.

I create a program in VB6 that will get as an argument an html link on startup, and do something with him.(like download manager)


Does anyone know how to?

Tnx

Click Link In Web1 Control ?
Can you click a link in a Web1.Control? What about a submit button?

-X

Web Fill Forms -&gt; Click Link
Anyone know how to click a link <a href> in a webstire throug VB Web fill forms. I am using Webbrowser control to fill the details in text boxes. I am able to click the submit Buttons automatically.

But now I want to go to another page by clicking a link within <a href> tags.

Please help. Thanks in advance

How To Simulate Click On A Link With Javascript
Hi,

I am trying to simulate clicks on a link of a web page using vb6 and the webbrowser control. The link contains a tag like this:

<a href="javascript:;" class="someName"> inner text </a>

I can find the object of this A tag (let's call it objCur), but when I use this code to simulate the click, it does not work.

objCur.Click     

It once worked when the link did not contain javascript, but not now.

I have also tried these:

objCur.InvokeMember ("Click")
objCur.raiseevent ("Click")

but none of them worked. But how to make it work for link like <a href="javascript:;" ? I tried several hours but no answers found. Please help! Thanks in advance!

VB.NET In ASP Click Link And Pop Up New Browse Window
Ok here is the question I am trying to stick mainly to VB not vbscript on an ASP.NET server. I want to have a button that calls a function that pops up a new browser window with no toolbar and such because it'll be used for displaying results and or a login page. Maybe I am going about this the wrong way. I know you can do it in JSCRIPT but I would like to find a mehtod of using VB to do the same thing. I can get the button to work but getting the window to pop up I get either A.Headache reading all of MS's documentation B.Lost on the MSDN site C.Both A & B THankx if someone answers this I will feel less and be

How To Link A WebBrowser Control To Text1.text
Is there a way to link a WebBrowser control to a textbox control.

Something like this (but this doesn't work)

I am using the Internet Transfaer Control to download a file

Text1.Text=Inet1.OpenURL ("http://mydomain.com")

and by placing WebBrowser1.Navigate text1.text in Text1_Change()

Whenever I download a page it will show up in the WebBrowser Control and I can try some changes in the textbox control without having to save it as a temp file and navigating to that temp file

Any help will be greatly appreciated

Thanks

Webbrowser Control: Clicking A Text Link With No Id? Possible?
i want to click a text link on a website that doesnt have an id.

the link i want to click is the "See full-size image." link on google images.

i.e.
http://images.google.ca/imgres?imgur...icial%26sa%3DN


i checked the source and the link has no id... otherwise i'd use


Code:
WebBrowser1.Document.All.Item("EnterIDHere").Click


is this possible

any ideas?

WebBrowser: Replace Part Of Url Link Within Page ?
Hello:
Im wondering if this is possable, bare with me, not sure how to word this.

Im using a WebBrowser Control which loads a page with a bunch of links in it.
The links are formatted like; wwwaddress.com?todo=whatever&somthing=else

What i would like to do is have it so when the user clicks one of the links it will drop the last part of the url and only pass/load; wwwaddress.com?todo=whatever with-out the &somthing=else.

I know how to "split" the urls to be how i would like them, but i do not know how to have my edited link/url "active" within the page.

I thouhgt i could do somthing in the BeforeNavigate2 function, but to no avail.
Then i thought i might be able to do something in the DownloadComplete, somthing to the effect of:
wb1.Document.documentElement.innerhtml = MyEdits and just replace the whole html source, but you cant do that

The only other thing i can think is saving my edited HTML source and load that source into the Browsercontrol as a new page. Is there any way around that ?


Im using VB6.
Thanks for any suggestions.

How Do I Access A Link From A Webpage In WebBrowser Control?
I want to access science.cgi from a page with source code:

<HTML>
<HEAD>
</HEAD>
<BODY BGCOLOR=#000000 TEXT=#FFFFFF LINK=#FFFFFF VLINK=#FFFFFF leftmargin=0 topmargin=0 marginwidth=0 marginheight=0>
<IMG SRC="http://207.200.11.37/utopia/gr/uttitle.gif" WIDTH=80 HEIGHT=30 BORDER=0><FONT SIZE=-1>
<MAP NAME=menu>
<AREA SHAPE=rect TARGET=utomain HREF="/menu.cgi?" COORDS=1,3,80,15>
<AREA SHAPE=rect TARGET=utomain HREF="/council.cgi?" COORDS=1,16,80,28>
<AREA SHAPE=rect TARGET=utomain HREF="/explore.cgi?" COORDS=1,42,80,54>
<AREA SHAPE=rect TARGET=utomain HREF="/build.cgi?" COORDS=1,55,80,67>
<AREA SHAPE=rect TARGET=utomain HREF="/science.cgi?" COORDS=1,68,80,80>
<AREA SHAPE=rect TARGET=utomain HREF="/military.cgi?" COORDS=1,81,80,93>
<AREA SHAPE=rect TARGET=utomain HREF="/magic.cgi?" COORDS=1,107,80,119>
<AREA SHAPE=rect TARGET=utomain HREF="/thievery.cgi?" COORDS=1,120,80,132>
<AREA SHAPE=rect TARGET=utomain HREF="/attack.cgi?" COORDS=1,133,80,145>
<AREA SHAPE=rect TARGET=utomain HREF="/aid.cgi?" COORDS=1,146,80,158>
<AREA SHAPE=rect TARGET=utomain HREF="/readmsg.cgi?" COORDS=1,172,80,184>
<AREA SHAPE=rect TARGET=utomain HREF="/msg.cgi?" COORDS=1,185,80,197>
<AREA SHAPE=rect TARGET=utomain HREF="/forum.cgi?" COORDS=1,198,80,210>
<AREA SHAPE=rect TARGET=utomain HREF="/politics.cgi?" COORDS=1,211,80,223>
<AREA SHAPE=rect TARGET=utomain HREF="/status.cgi?" COORDS=1,224,80,236>
<AREA SHAPE=rect TARGET=utomain HREF="/scores.cgi?" COORDS=1,250,80,262>
<AREA SHAPE=rect TARGET=utomain HREF="/leaders.cgi?" COORDS=1,263,80,275>
<AREA SHAPE=rect TARGET=utomain HREF="/news.cgi?" COORDS=1,276,80,288>
<AREA SHAPE=rect TARGET=utomain HREF="/news.cgi?yesterday=true?" COORDS=1,289,80,301>
<AREA SHAPE=rect TARGET=utomain HREF="/dragon.cgi?" COORDS=1,302,80,314>
<AREA SHAPE=rect TARGET=utomain HREF="/pref.cgi?" COORDS=1,328,80,340>
<AREA SHAPE=rect TARGET=_blank HREF="http://games.swirve.com/utopia/help" COORDS=1,341,80,353>
<AREA SHAPE=rect TARGET=utomain HREF="http://games.swirve.com/utopia/help/faq.htm" COORDS=1,354,80,366>
<AREA SHAPE=rect TARGET=_top HREF="/logout.cgi?" COORDS=1,370,80,385>
</MAP>
<CENTER><IMG SRC="http://207.200.11.37/utopia/gr/newmenu.gif" USEMAP="#menu" HEIGHT=385 WIDTH=80 BORDER=0>
<a href="sidenogr.htm"><font size=1 face=verdana><B>No Graphics</B></FONT></A>
</BODY></HTML>


It must be accessed from the site, since it gives me a "You cannot access this page from outside the site" error.

Statusbar Link Display In Webbrowser Control
I need the same thing that happens in the IE browser when
  you mouseover a url link, as in a link in a webpage.
  When you mouseover a link in IE it appears in the stausbar,
  giving the path to the file/page wanting to be accessed.
 
  this is what I need also, do you now understand?
 
  How do I accomplish this in VB code?

Cannot Link To Help In Rt-click Popup Menus Using HelpContextID
I have several controls/programs that use rt-click popup menus. I would like to link the items in the menu to certain places in the Help file.

I figured that setting the "HelpContextID" for each menu items would accomplish this. However, when I press the F1 key it does absolutely nothing. The "HelpContextID" property works for other controls (forms, ...) - but won't work for me with any of these rt-click popup menus.

Any ideas? Is there something I'm missing?

Click Button On Webpage && Image Link
i have 2 questions
if u go here Mail and view the source can anyone work out the "click" code from the source for the sign in button ive tried everything and just cant find it and get it to work. im using yahoo mail as a way to just work it out its not actually for yahoo but if i knew that it would make my other project alot easier
second question
how can i automatically get the image source link from say this page link
thats not the page im trying to figure it out for but the other site is a private site u need to sign up register and pay but it uses a verification word just like yahoo msn and alot of sites do. basically why i want to be able to grab the image link and show the image in say a pic box is cause im making a quick login tool for the site ill still see it in a webbrowser control but it saves me typing every lil thing in this way ill just need to type the image word into a textbox and hit submit type thing.
anyone got any ideas for these 2 questions?

Click On A Link At A Specific Location In Web Browser
Hello Guies

I want to know that

if any web site is being browsed and there is some link or button in a page
Say Prev or Next

How should i write a VB Program that can automatically clicks on those links or button and the the link is activated

i can use the web browser control of VB as well

Get Hyperlink Address Of Link When Clicked On It In Webbrowser Control
HI all,

I am using webbrowser control for displaying URL's.


I want to get the hyperlink (URL Address) address of the link displayed in the Webpage when user clicks on the link.

Open A Link From WebBrowser Control In Default Browser?
On a WebBrowser control (that uses Internet Explorer engine), I need to open the links of the page displayed, on a new window of the default browser, instead of forcing the user to use IE.

I could strip the HTML code to get the URL, put a layer on top of the WebBroser control, to then open the link on the default browser, but this would be lame.

How to do this in a (good) way?

Changing Destination Object Of Link In Webbrowser Control
Project attached ...

In the NewWindow2 event of the WebBrowser control I am trying to set the ppDisp object to one of the other WebBrowser controls in the array. It doesn't work how it apparently should. According to what I've read it should be as simple as ppDisp = webPage(index) but it appears that it's not that simple - the new window opens anyway.


Remember to use [code=vb][/code] tags around code.
| Posting rules | How to get your questions answered | Wonko's Blog | Twerps Peerage |
vbCity Recent Topics RSS feed

Link An Excel Macro Into A CommandButton Click Event
This an easy question :
I have a macro named "sort" in my excel file.
I have a button on the sheet wich I want to execute this macro,
But how can I do that?

*solved*How Can I Hide Text1 When I Click Link In Webrowser1?
Hi,

How can i make text1.visible = false when i click a link in the html page in webrowser?

which property is it?





Edited by - Hopeless on 8/22/2006 9:36:02 PM

Get Text From Value Attribute When Clicking On A Link In A VB Hosted Webbrowser Control?
Hi,

I have an application which uses the webbrowser control.
Is there a way to "catch", in the host application (VB),
which link is clicked in the loaded html page?

For exampel in the html page the code could look
something like this:

<A href="_cdindex.htm" id="index"
value="myType">_cdindex.htm</a>

I'd like to be able to get a hold on the value ("myType")
in the value-attribute for the clicked link. Is this
possible?

regards / magnus

Click A Link, Button, Or Edit Input Field In Browser Control?
I have no experience with the browser control, nor do I with the Inet control. Is there a way to insert text into an input field of a webpage, click on a specific link, or click a "submit" button?

For example, if I wanted to log someone into a site based on info they provided in a text box?

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