Avatar of thresholds
thresholdsFlag for United States of America

asked on 

Debug stand alone javascript in Windows 7 (not in browser)

How can I debug a stand alone javascript file that has nothing to do with a browser or web page in Windows 7?  I have made a script that is supposed to move some files based on the create date.  I need to debug it but I can’t find any way to get a script debugger that will work on a script that is not running in a browser using Windows 7.  I was able to do this in Windows XP but I tried down loading what I thought was the proper debugger from Microsoft’s website - I can’t get it to work with a stand alone javascript file.  I looked in the Office 2010 installation and there doesn’t seem to be a debugger in there.
I tried using “debugger” at the top of the script but it is ignored.
I can’t be the only one in the world who needs to do this.  I have Visual Studio 2005 installed also if that helps but I tried getting it to work in there but it seems to be like every other javascript debugger in the world in that it only works with scripts in web pages.
Thanks
Windows 7JScriptOperating Systems

Avatar of undefined
Last Comment
thresholds
Avatar of leakim971
leakim971
Flag of Guadeloupe image

are you sure this is javascript? and not VBScript?

Anyway :
a = a + 10;
has "nothing to do" with a browser but you can debug it with the js debugger of the browser
Avatar of thresholds
thresholds
Flag of United States of America image

ASKER

Yes I am sure it is javascript.  How can I run a javascript file in a browser?  I can open the "MoveBackups.js" file in Windows Explorer 8 but it just sits there and I don’t see any way to make it run.
Avatar of thresholds
thresholds
Flag of United States of America image

ASKER

The first link gives me page not found and the second won't work since You Tube is blocked here at work.  I looked at the “jonathanboutelle.com” site and I don’t see anything relevant. If the javascript is running in a web page won’t the security prevent it from being able to move files?   I don’t do web programming and have no experience with it.
Nobody makes a stand alone debugger for javascript?  Maybe I should just use C# - at least there is a good debugger.
Avatar of leakim971
leakim971
Flag of Guadeloupe image

Try this one : http://jsfiddle.net/BqpUY/

jQuery(document).ready(function() {
    $('.nav').find('ul').hide().end();
    $('.nav').find('li').click(function(e) {
        e.stopPropagation();
        $(this).children("ul").slideToggle();
    });
});

Open in new window

Avatar of thresholds
thresholds
Flag of United States of America image

ASKER

That looks like what I need but they don't have a version I could try w/o coughing up actual money?  I work for a non-profit agency and getting money is not easy - we haven't even had raises in 4 years.

ASKER CERTIFIED SOLUTION
Avatar of leakim971
leakim971
Flag of Guadeloupe image

Blurred text
THIS SOLUTION IS ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
Avatar of thresholds
thresholds
Flag of United States of America image

ASKER

This one looks more like my speed.  I'll have to wait until tomorrow to do the download since our connection is extremely show during the work day.
Avatar of thresholds
thresholds
Flag of United States of America image

ASKER

I downloaded and installed the “Eclipse IDE for JavaScript Web Developers”.  My first reaction was that it was way more than I was looking for but it will do what I need (and a lot that I don’t need) so I thank you.
Avatar of thresholds
thresholds
Flag of United States of America image

ASKER

I may have spoken too soon.  I was running a script in the debugger and when it got to the line that creates a FileSystemObjcect it came to a screeching halt.  No messages but apparently it doesn't know what a FileSystemObject is.  There may be a way to reference the correct dll but it may take a while to find - there is nothing obvious.
Any ideas?
Windows 7
Windows 7

Windows 7 is an operating system from Microsoft. Features include multi-touch support, a redesigned Windows Shell with a new taskbar, referred to as the Superbar, a home networking system called HomeGroup, and performance improvements.

48K
Questions
--
Followers
--
Top Experts
Get a personalized solution from industry experts
Ask the experts
Read over 600 more reviews

TRUSTED BY

IBM logoIntel logoMicrosoft logoUbisoft logoSAP logo
Qualcomm logoCitrix Systems logoWorkday logoErnst & Young logo
High performer badgeUsers love us badge
LinkedIn logoFacebook logoX logoInstagram logoTikTok logoYouTube logo