473,407 Members | 2,326 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,407 software developers and data experts.

reading USER from Registry - Javascript

Hi all,

I've been having this mega-problem for a while now.
I'm trying to access the Registry; I've tried using PHP (server-side, so won't work), so I've gone client side, and seeking for the solution within Javascript.

I know theres a lot of issues with accessing the Registry from Javascript, mainly having to have low security settings in order to beable to read it, and so on, but this won't be an issue (hopefully) as once I have got the program to do what I want, I'm handing it over to people who can deal with all the .hta and certificate stuff.

I'm pretty proficient in Javascript, but I can't get any script working for the life in me.
Here's some code I've found and been playing about with:

Expand|Select|Wrap|Line Numbers
  1.   function shell(){
  2.     var sh1 = new ActiveXObject("WScript.Shell");
  3.     var sh2 = sh1.RegRead("HKEY_CURRENT_USER");
  4.     alert(sh2);
  5.   }
  6.  
Obviously this is wrong, since it doesn't work, but does anyone know why? All I need to do is get the user inside a variable and I'm away.

Thanks in advance :)
Jul 4 '07 #1
1 1656
kovik
1,044 Expert 1GB
Last I checked, Microsoft forbids registry access through IE.
Jul 4 '07 #2

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

Similar topics

1
by: Duncan Allen | last post by:
I'm trying to use aspnet_setreg to encrypt user names & password used in the web.config file for use in the indentity element. When the website runs I get the message 'Error reading the password...
3
by: Mike Malter | last post by:
On my XP Professional dev machine, I am able to read the registry by giving permissions to the ASP.NET account on the local machine. When I transfer the code to my staging server (Windows 2003),...
5
by: Dhilip Kumar | last post by:
Hi All, I'm writing a Windows Service app using C#. I need to read some configuration settings before the service starts up. These settings will be used by the service in its operation. ...
3
by: Ahmad Jalil Qarshi | last post by:
Hi! I am developing an application in C# as a windows NT Service. This application needs to check for eventlog using EventLog.Exists("System") But unfortunately it generates exception...
12
by: Simon Hart | last post by:
Hi, I am using Impersonation and turned off anon access for my web service. I am using the administator to authenticate the request using ICredentials. I am simply trying to read a key in...
5
by: UJ | last post by:
I have a system that has five programs that all communicate with each other via Message Queues. Works well. One program is a watchdog that will make sure the others are up and going. Currently I...
3
by: Aussie Rules | last post by:
Hi, I want to store some data in the registry, however I have not been able to do this, and think my logic maybe flawed. Firstly I try to open the registry and read in any existing values....
0
by: tmsprowl | last post by:
Greetings! I was wondering if someone could help me with a problem I'm having. My department is just one of many within my organization. My organization has control over the network domain,...
1
by: gracepaul | last post by:
hi all, I write a javascript for reading the registry value as follows <script language="javascript" type="text/javascript"> <!-- function ReadRegistry() { var WshShell;
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
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,...
0
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...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
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...
0
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,...
0
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...

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.