473,320 Members | 1,940 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

hrefs and javascript, navigate and other beasties

Not sure if this is the right place to post, but here goes anyway. I
pull out "javascript:__doPostBack('ctl01$ContentPlaceHolder Main
$Page_SearchResults$Results','LID_2076923')" from an href in an object
I'm parsing and set URLaddress to be that string

On a whim, I then plug it into obIe.navigate (URLaddress) and miracle
of miracles, it actually brought me to the right web page, which I
didn't think it would do and have no idea why it actually works.
Setting aside the issue of why it does work as well as it works,
there's still a problem.
It never enters readyState 4, but remains at readyState 3, so I never
leave the loop.

In VBA I do:
obIe.navigate (URLaddress)
Do While obIe.readyState <4 'READYSTATE_COMPLETE
DoEvents
Loop

I can't figure out how to get past this. I'm sure it must have to do
with the href string in some way since I didn't expect it to work at
all.

I was considering doing something like [myObject].href.onClick
instead, but I would prefer to use the navigate method above for the
simple reason that I believe I have more control over timing and
errors - at least usually.

Any help?

Thank you
Oct 9 '08 #1
1 2264
Dudely wrote:
Not sure if this is the right place to post, but here goes anyway.
"I don't care if this could interest you, but I bother you nonetheless."

How very social of you. And yes, it was the right place -- *this* time.
I pull out "javascript:__doPostBack('ctl01$ContentPlaceHolder Main
$Page_SearchResults$Results','LID_2076923')" from an href in an object
I'm parsing and set URLaddress to be that string

On a whim, I then plug it into obIe.navigate (URLaddress) and miracle
of miracles, it actually brought me to the right web page, which I
didn't think it would do and have no idea why it actually works.
[...]
obIe.navigate (URLaddress)
`javascript:...' is a URI (if still a proprietary one), why should it *not*
work with a method that appears to accept a URI and then to navigate to it?
[...]
It never enters readyState 4, but remains at readyState 3, so I never
leave the loop.
Quite obvious, there is no direct HTTP request here.
In VBA I do:
Visual Basic for Applications is obviously well beyond the scope of this
newsgroup.
[...]
I was considering doing something like [myObject].href.onClick
instead, but I would prefer to use the navigate method above for the
simple reason that I believe I have more control over timing and
errors - at least usually.
Usually you have more control over timing and errors if you employ a
standards-compliant event listener instead of a proprietary URI scheme.
PointedEars
--
Prototype.js was written by people who don't know javascript for people
who don't know javascript. People who don't know javascript are not
the best source of advice on designing systems that use javascript.
-- Richard Cornford, cljs, <f8*******************@news.demon.co.uk>
Oct 9 '08 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: Andy Fish | last post by:
Hi, I want to use an anchor tag to invoke some javascript and I've read that it's bad form to use <a href="javascript:foo()"> I've read endless usenet posts and hint sites on the net, they all...
6
by: Alex Rast | last post by:
First of all, this is not a programming question. I'm a user, not programming in JavaScript. I'm not, however, a novice user or even a power user - I certainly know programming intimately as well...
4
by: Gagan Diesh | last post by:
all I want to do is add the ability for an image to take the user further down a page (href="#bottom"). Anyone tell me how to do this? ==the code below works perfectly=== My code on an...
1
by: Joe | last post by:
Hi folks, Been looking at this for the day so any ideas would be appreciated. Here's the scenario, bear with me - it looks more complicated than it is :) I have a page templating system that...
3
by: | last post by:
If there is a better forum in which to post this question, please let me know... I need to know how the src and href attributes are handled in html such as the following: <script...
8
by: =?Utf-8?B?QW1yaXQgS29obGk=?= | last post by:
Okay, after much research, I have discovered a few interesting things in ASP.NET. I have a MasterPage that has a WebForm on it and it looks like this: <body> <form id="controls"...
5
by: aelred | last post by:
I have a web page where a member can open up a chat window (child window) with another member. - From there the member can also navigate to other web pages. - From other pages in the site, they...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 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 former...

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.