Vb6.0 get windows directory
September 29th, , PM 2. Re: How to get the current directory and current drive in VB6. September 29th, , PM 3. ExeName Hope it helps Srikanth. Quick Navigation Visual Basic 6.
NET Framework. I think they are just using SQL Server to store user names and passwords for other applications - and instead would prefer to verify them against their AD accounts. In which case PWise's code is a reasonable solution if we get rid of the pointless lines of code. I'm just trying to not store the user names and passowrds in a table and just have them use there AD account to login to my apps.
I really appreciate your help guys. Ahh yes, that is very different. Are you sure you need to do this? It isn't considered good practice. Some background on it can be found at How to validate user credentials on Microsoft operating systems Quote: Note Collecting user credentials from a User-mode application can be annoying to the users and can provide a possible security hole in the enterprise computing environment. Consult the security documentation in the Platform SDK for more information on impersonation and programming secured servers.
Your code does not declare the variables before using them, which is required if Option Explicit is set which it is You need: Dim sUsername as String Dim sPassword as String Dim sDomain as string in your code.
I'm missing something here. Otherwise, it retrieves the path of the private Windows directory for the user. For an example, see Getting System Information. The sysinfoapi. Mixing usage of the encoding-neutral alias with code that not encoding-neutral can lead to mismatches that result in compilation or runtime errors. For more information, see Conventions for Function Prototypes.
System Information Functions. Skip to main content. This browser is no longer supported. Are you looking for the Windows directory or just the system directory? If the System directory you could simply do this:. Otherwise to get the Windows directory you can still use that value to move a directory back up the tree.
NET take a look at its page on pinvoke. GetEnvironmentVariable "windir". Ask a question.
0コメント