Running server code from a client script?

Posted on 2002-06-20
Medium Priority
Last Modified: 2013-12-24

I seem to have come across a problem with my installation of VS-6 in that I cannot use the page object.  It immediately comes up with a Red Exclamation Mark (or R.E.M. for short :) ) when it is dropped on the page.  This REM still remains even if I change the page object name.  The when the mouse is over the REM, the hovering tool-tip says "named objects are not currently available."  I have re-applied all the latest service packs (win2k-sp2, vs6-s5). I have searched google web/newsgroups and found a few people have come across the same problem, but no answers were given.  The only thing I haven't tried is re-installing the OS and that aint going to happen (at least not yet :) ).

So for at least the short term, I need a workaround.  How can I run server code from a client script (avoiding the temptation to use a submit button of course).

Question by:EBAC
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
LVL 19

Expert Comment

ID: 7107790
You can't! Never was possible...and never will be....that would be a serious security hazard...


Expert Comment

ID: 7207371
Don't know what all your requirements are, but you can try remote script.
Works best with IE 5 + 6.
NS 6 does not work with it, but, theoretically NS 4 + 5 does.

Try this for some reading on it:

Author Comment

ID: 7207760
Thanks heaps!

We are only going to be using IE, because it is only for internal site purposes.  Unfortunately, many of the computers on site are Win95 clients.  That means that I would have to install Windows Scripting 5.5.

Would it ever pose a problem if we were to ever get a couple of XP computers on site (bearing in mind that it requires al least Windows scripting 5.6).

I can go ahead and run with this because it looks like it will do the job.  But I just don't want to burn any future bridges I may want to cross.

Thanks in advance.

Accepted Solution

CharlesM earned 200 total points
ID: 7209002
I don't think it matters much about the OS, more with the version of IE you have.

If you install v5 IE on the 95 computers, remote scripting should work fine.

I've used remote scripting on an XP machine (done a couple of projects with it), again, no problems.

I upgraded to the .NET platform, still ran fine.
Remote scripting isn't supported in .NET projects though, but it runs fine on a .NET machine.

Expert Comment

ID: 7437416
I am not sure about the REM problem - it sounds like a permissions issue.  Make sure that you logged in as an administrator while you installed VI.

The page object does include an 'execute' feature, that allows a server-side function to be executed from client script.  It uses a Java runtime module (RSPROXY.JAVA) in the _ScriptLibrary. See also the RS.ASP / HTML files, that wrap the javascript, and PM.ASP / JS that handles the Page Object at runtime.  Unfortunately, not all browsers or security systems allow Java applets - though in your situation it sounds like it would be OK.

But without the page object (and its execute handler) you may need to use FRAMES (or Layers in Netscrape).  Through an iframe on the page, you can request separate url's, passing parameters in the query string, and recieving the reply as content or xml.  This information can be passed back to the main page via the window.parent object.

So if the content returned to the frame included javascript, this would run and could pass values back to the parent window document.

We also have a pop-up frame that has a gif image that looks like a % completion status bar that fills from the left.  Clearly it fills then starts again, but at least it shows the user that something is still happening.

Featured Post

7 Extremely Useful Linux Commands for Beginners

Just getting started with Linux? Here's a quick start guide that has 7 commands that we believe will come in handy.

Question has a verified solution.

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

Objective of This Article In 1990’s, when I was a budding software professional, I had a lot of confusion about which stream or technology, I had to choose to build my career. In those days, I had lot of confusion like whether to choose System so…
This guide will walk you through the essential considerations and tech stack for building scalable websites. Know how to grow your business the smart way!
The purpose of this video is to demonstrate how to create a Printer Friendly PDF on a WordPress Page. This will be demonstrated using a Windows 8 PC. Tools Used are Photoshop, Awesome Screenshot” Google Chrome Extension, and SmallPDF.com Log…
The purpose of this video is to demonstrate how to update a WordPress Site’s version. WordPress releases new versions of its software frequently and it is important to update frequently in order to keep your site secure, and to get new WordPress…
Suggested Courses

777 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