Archive

I’m amazed somehow about how people on the Internet do not read a question properly or think outside of their own little worlds. I’m always a little wary of tech information I read on the Internet, especially answers posted in newsgroups and forums, but sometimes, they are you’re only source and sometimes they are correct!

Yesterday, I was searching for information regarding a somewhat strange, but necessary question for my job. Simply put, the question was “How can I call a JavaScript function from within VBScript?”.

I have to use a JavaScript and VBScript in the same page. In the way that VBScript is calling a JavaScript.

Can anybody tell me how to call a javascript from a vbscript?

Thanx,
Ahmed

So, the question is the same as mine, albeit phrased diffently, and in broken English (that’s fine).

Straight off the bat, the first answer (from “matt.carter.25”) gets the context wrong:

You cant call VBScript from javascript,

VBscript is processed by the server before the page is sent, javascript works in the browser when its being viewed.

Hmm, no one said he was using ASP and Server Side VBScript. If you think about it before you act, it’s logical that he is using Client Side VBScript and Javascript.

The next answer is more helpful, and actually provides an answer (well done “Warren86”!). Two answer’s later and “matt.carter.25” is at it again:

I think what he is tring to ask is if he can call vb function using JS

This time, he’s got the question wrong! He’s got it the wrong way round! I mean, it’s not difficult to read the question.

Next answer from “96tunerri” is also incorrect:

yes he was, which cannot be done

Not only has he read the question wrong as well, his answer is not even technically correct.

Again, thanks to “Warren86”, his is proved wrong and a correct answer is posted:

Yes, it can.

<HTML>
<Head>

…

Finally, to add insult to injury, “Exuro” now preaches about VBScript not working for 20% of the Internet. Which is actually OK – I mean, the information that “Exuro” is preaching is accurate and it’s good advice – if you are creating an external website. At no point is it mentioned that the guy is creating a website, he just says he’s creating “a page”.

At work, I deal with HTML every day – my application depends on it for the UI – but it’s not a website that you can access with a browser (OK, you can, but it doesn’t work). We use nothing but VBScript, because we know for a fact that the pages will not be viewed by anything other than Internet Explorer.

How do we know this? Because the executable that is run is just a wrapper around the Internet Explorer ActiveX control….

So, we have one guy that can read properly, and checks his answers before he posts them, another who assumes a load of stuff, and 2 that are pretty useless. All on one page! Great!

The past few weeks, I’ve had to use Microsoft Word a bit so that I can write up some specifications for other people to review, comment, enhance, reword, approve, you name it.

I am now soooo fed up with Word, it’s unbelievable.

The problem is, you can change things. There’s no structure system that you can use to force a document to do exactly what you want. Instead, you’re left with a series of stupid handling issues which lead to inconsistent documents across a department and people banging their heads on their desks in frustration.

Take, for example, my incident yesterday. Having reworked an existing specification from the ground up, I found cause to delete the final section of the document. This section was in landscape orientation, not portrait, because it contained some screen mock-ups (no complaint there). When I came to delete the sections, it changed every single section to be landscape, and changed the Page Header to be something completely different – in fact, it changed it to something that was not visible in the document to begin with, so I couldn’t even correct that.

I remember getting frustrated about this kind of thing before. That was whilst I was doing my final year project for my degree. I switched from Word to LyX.

Using LyX worked great for me, and I couldn’t have produced my final report without it, but I don’t think it would work in an office environment.

I think too many people are used to WYSIWYG, and not WYSIWYM (What You See Is What You Mean), and so would be constantly frustrated with the inability to see what your document looks like in Real-Time.

What I would love, is a cross between the two.

I would love to be able to create a rigidly structured document, where no one can change the text position, change the font, change the font size, mess with headers, etc – at least not without having to update a template. But as I’m typing, I’d love to see what that document would look like once printed, not the LyX modus operandi of “enter text, preview the DVI file”.

Couple that with a few more features, such as Word’s “Track Changes” and LyX’s far superior cross-reference and footnote handling, and you’re on to a definite winner.

Finally, just because you have to work with the rest of the world, some form of export to Microsoft Word format would be great.

Hey, Rich, feel like resurrecting “SLaTe”?

Update:

Ooh, apparently LyX now supports “Track Changes”. A lot can happen when you don’t use a bit of software for 6 years!

Last night, I amazed myself when I discovered I had a real-life, genuine, need for a Farraday cage.

I was trying to install my parent’s new Wireless printer, but unfortunately, it had joined the wrong wireless network and I couldn’t get it to leave that network and join the correct one.

Stupidly, the printer came with a utility so that you could set the IP address, and from there you could then connect to a web interface so that you can set which wireless network to join, and security settings, etc. That’s all well and good, but if it’s on the wrong network altogether, then you can’t set the IP, you can’t connect to the web interface, and you therefore can’t set the security information!

So, I decided to resolve the situation by blocking out the other wireless signal. I attempted to construct a Farraday cage with a Quality Street tin, and then place the correct wireless router, and the printer, inside the cage.

Sadly, Quality Street tins don’t make good Farraday cages.

I eventually resolved the situation by moving the printer next to the router, connecting it to the router with an ethernet cable, printing out the network configuration that the printer had picked up with DHCP, using the utility to set a static IP address, and then connecting to the web interface to force the correct wireless network and the correct security settings.