Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Where is the WinNT\System32?

Status
Not open for further replies.

Apinedo

Programmer
Oct 5, 2000
6
CO
Hi.
I have just a question.
Is there some way to know where the directory WinNT\System32 is located in my machine?

I need to work with some files in this directory.

Thanks.
 
Here is an API and function that I use:

[tt]
Private Declare Function GetSystemDirectory Lib "kernel32" Alias "GetSystemDirectoryA" _
(ByVal lpBuffer As String, ByVal nSize As Long) As Long

Public Function GetWindowsSystemDir()
Dim sBuffer As String
Dim X As Long

sBuffer = String(255, vbNullChar)
X = GetSystemDirectory(sBuffer, Len(sBuffer))
GetWindowsSystemDir = Left(sBuffer, X)
End Function
[/tt]
hope that helps, dont shoot me if it didnt (I'll be watching :cool: ) [sig]<p>Karl<br><a href=mailto:kb244@kb244.com>kb244@kb244.com</a><br><a href= </a><br>Experienced in : C++(both VC++ and Borland),VB1(dos) thru VB6, Delphi 3 pro, HTML, Visual InterDev 6(ASP(WebProgramming/Vbscript)<br>
[/sig]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top