Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / .NET Framework / New Users / March 2006

Tip: Looking for answers? Try searching our database.

.Net Framework 2.0 and WSH 5.6

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Ornulf Schomer - 02 Mar 2006 07:36 GMT
Can I use .Net Framework 2.0 objects with Windows Script Host 5.6? I haven't
found this information anywhere. I know that you have to use VS2005 to be
able to use .Net 2.0 so my guess is no!

Ornulf Schomer
Norway
Patrice - 02 Mar 2006 09:32 GMT
You could expose .NET objects so that they are usable from VBScript.
You could also just compile the code and run the script (the compiler is
part of the Framework).

What are you trying to do ?

Signature

Patrice

> Can I use .Net Framework 2.0 objects with Windows Script Host 5.6? I haven't
> found this information anywhere. I know that you have to use VS2005 to be
> able to use .Net 2.0 so my guess is no!
>
> Ornulf Schomer
> Norway
Ornulf Schomer - 02 Mar 2006 12:03 GMT
I am planning to write a script that traverses our data server disks and
checks if there is any users og domain global groups in the ACEs. Our
standard is to give access rights to folders and shares via Domain Local
groups, but I know that there has been a lot of errors made. And to script
this would be preferable to right-clicking every folder and make a note of
the ACEs . :-)

Originally I thought I'd write an commandline-app that did this but as I
have visual studio 2003 only - I cannot access the
System.Security.AccessControl-namespace.

So my question then is wether Visual Basic Scriping Edition in any way can
use these objects, when VS2003 can't?

Ornulf

> You could expose .NET objects so that they are usable from VBScript.
> You could also just compile the code and run the script (the compiler is
[quoted text clipped - 9 lines]
>> Ornulf Schomer
>> Norway
Dmytro Lapshyn [MVP] - 02 Mar 2006 13:02 GMT
Hi,

Yes you can, however it requires some work. You should create a class
library project and make appropriate classes COM visible. The details are
well described in MSDN, look for the

"Exposing .NET Framework Components to COM"

section. You will need to make sure you use dual interfaces and OLE
automation-compatible data types.

> Can I use .Net Framework 2.0 objects with Windows Script Host 5.6? I
> haven't found this information anywhere. I know that you have to use
> VS2005 to be able to use .Net 2.0 so my guess is no!
>
> Ornulf Schomer
> Norway
Ornulf Schomer - 02 Mar 2006 13:52 GMT
Ok! Thanks alot! I can see the sense in that. I think there is some stuff
about Com Wrapping in a ADO.NET book I have so I just have to read up on
that.

Ornulf

> Hi,
>
[quoted text clipped - 13 lines]
>> Ornulf Schomer
>> Norway
Patrice - 02 Mar 2006 16:43 GMT
The big picture of what you are trying to do do may also help.

It looks a bit strange to me (i.e. you could perhaps compile a .NET 2.0
script that does what you need instead of exposing .NET 2.0 objects througt
COM so that they are usable from WSH ?).

Signature

Patrice

> Ok! Thanks alot! I can see the sense in that. I think there is some stuff
> about Com Wrapping in a ADO.NET book I have so I just have to read up on
[quoted text clipped - 19 lines]
> >> Ornulf Schomer
> >> Norway

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.