473,748 Members | 2,659 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

execute javascript on a webpage via VBA

5 New Member
RE: execute javascript on a webpage via VBA

I have a procedure that opens a webpage. What I want to do is click a button on that page, but it isn't really a button. There is a Javascript function that clicking the "button" runs to open a different version of the webpage.
Aug 19 '13
12 23836
LWKnox
5 New Member
I've already tried several permutations of the code above without success. Apparently the "button" is not a button at all but an image that when clicked runs a Javascript sub that opens the next webpage. That is precisely what I want to do is run the js and open the next page.
Aug 20 '13 #11
zmbd
5,501 Recognized Expert Moderator Expert
then you need to find the parent of the image and try a click event on that.
Aug 20 '13 #12
zmbd
5,501 Recognized Expert Moderator Expert
Just to update,
As I noted in the last post to find the parent image, this what I did for my code in post#10 which I've now updated to reflect this, and I've added a bit of error traping etc...
This is what you'll have to try to do... either find the function call or find the element in the document that does the call.
It can be done.
Aug 20 '13 #13

Sign in to post your reply or Sign up for a free account.

Similar topics

1
6405
by: nerf | last post by:
How can I execute a javascript file(test.js) from within PHP. I'm running oscommerce and want to insert a menu created in javascript by Sothink DHTMLMenu. Thanks in advance
2
4305
by: jm | last post by:
I have a parent window: <script language="javascript"> function doSearch() { result=showModalDialog("searchmni.aspx?lastname=smith"); alert(result); } </script>
2
5595
by: Dave | last post by:
Hi, I have a datagrid with a Templated column below. I want to execute some javascript before the postback to show a hidden "div" tag with static message of "Please Wait..." since the query takes a few seconds. The js function simply sets the css style to display. <asp:TemplateColumn> <ItemTemplate> <asp:LinkButton Runat="server" CommandName="Select" ID="lbtnCompanyName"> <%# DataBinder.Eval(Container.DataItem, "CompanyName")%>...
5
4931
by: Scott Natwick | last post by:
Is there a way to execute a JavaScript from the Page_Load event? Or alternatively, is there a way to have it execute when the page is loaded? I am defining the script in the Page_Load event and using the RegisterStartupFunction to add it to the page. I just need a way to execute the script when the page loads. Any ideas?
1
1963
by: M | last post by:
Hi everybody, I have a Web form with something like: <form id="Form1" method="post" onsubmit="javascript:submitForm();" runat="server"> I need the JavaScript function submitForm() to execute everytime the form is submitted. I also have two RadioButtons with AutoPostBack set to true.
1
9707
by: Peter Dickson | last post by:
I am trying to pull data from a website into a database. Part of the website I am getting the data uses javascript to display the data. The only variable being passed to the javascript when it is executed is a record number (Ex: javascipt:getDetails('123456789') Can VB.Net control execute the javascript? If so, does anyone have an example of how it can be done. Thanks
4
4064
by: Ian Kelly | last post by:
Hi All, I have an .net form that is split into two frames. The left frame has a tree that displays a list of all the customers. The right frame displays the appropriate clients information. When the save button is pressed on the right frame, I want to update the tree in the left frame AFTER saving all the data as the changes to the right frame may affect how the tree is displayed. I tried using the following: ...
11
9422
by: Hakan ÖRNEK | last post by:
Hi , I register client scripts like this; -------------------------------------------------------------------------- ----------- Public Sub CreateClientAlert(ByVal Message As String, ByVal objPage As Page) Dim StrScript As New StringBuilder("") With StrScript .Append("<script type=""text/javascript"">") .Append(vbCrLf)
1
10309
by: Veerle | last post by:
Hi, I have a web page and at the end of the page I have inserted some javascript that checks if Acrobat Reader plugin is installed. If it is not installed, I disable some elements (buttons, checkboxes, ...) on the page. This javascript is at the end of the page, because javascript cannot identify html elements if they are defined below the script. Some of the elements that I disable when the plugin is not installed
7
4489
by: Peter | last post by:
I have a HoverMenuExtender which contains an asp:PlaceHolder, this place holder has a User Control and this control contrains a Button. The problem I am having is after the button fires the click event I want to do a server side function and then refresh the Page where the PlaceHolder risides. I have no problem doing the server side function, but the following 'alert' never shows up after the server side funtion. I am using the alert...
0
8996
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8832
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9562
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9254
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8255
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6799
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6078
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
1
3319
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
3
2217
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.