How to use System Environment Values like %Path% or %Computername% in Form Fields?

C

Christoph Sbach

Example:

Set objCurrentFolder = Application.ActiveExplorer.CurrentFolder
set CurrentItem = objCurrentFolder.Items.Item(1)
CurrentItem.UserProperties.item("Computername").Value=
CurrentItem.UserProperties.item("Username").Value=

Y:\>set
COMPUTERNAME=PC-F110-1
ComSpec=C:\WINNT\system32\cmd.exe
OS=Windows_NT
USERNAME=HannibalL
:
 
C

Christoph Sbach

This resolve my problem:

in vba i create a sub MyShell with shell command inside.

in vbs run this macro with Application.MyShell.



OL2000: Calling a VBA Procedure from VBScript

Anwendbar auf

This article was previously published under Q221827
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top