Page 2 of 2
Re: How many time my application is run in memory (SOLVED)
Posted: Tue May 17, 2022 9:23 am
by MarcoBoschi
Jimmy,
It's Fantastic!
In this way I can verify from client if there is a running application in my server
oWMI := oLocator:ConnectServer( "srvmng" , , user , password )
Many thanks
Re: How many time my application is run in memory (SOLVED)
Posted: Tue May 17, 2022 9:48 am
by MarcoBoschi
Re: How many time my application is run in memory (SOLVED)
Posted: Tue May 17, 2022 12:34 pm
by MarcoBoschi
Hi,
maybe someone have already translate this function from delhpi to fivewin?
https://stackoverflow.com/questions/677867/run-application-or-process-on-a-remote-computerI'd like to test just one thing
many thanks
marco
Re: How many time my application is run in memory (SOLVED)
Posted: Tue May 17, 2022 11:14 pm
by Jimmy
hi,
WMI can access "REMOTE" ... but you need "Rights"
this is Xbase++ Code
Code: Select all | Expand
IF VAL( OS(OS_VERSION) ) > 6
IF strComputer == "Localhost"
objWMIServices := CreateObject( "WbemScripting.SWbemLocator" ):ConnectServer(strComputer, "Root\CIMv2")
ELSE
IF EMPTY(cPassword)
MSGBOX("Need Password")
QUIT
ELSE
objWMIServices := CreateObject( "WbemScripting.SWbemLocator" ):ConnectServer(strComputer, "Root\CIMv2",strComputer+"\"+cUser,cPassword)
ENDIF
ENDIF
ELSE
objWMIServices := GetObject("WinMgmts:{impersonationLevel=impersonate}\\"+strComputer+"\Root\CIMv2")
ENDIF
Is it possible to read Open Files in Shared folders via WMI?. (My Computer, Manage, System Tools, Shared folder, Open Files)
as i know you "can" find out "share" Files ... but only "on Server"
Re: How many time my application is run in memory (SOLVED)
Posted: Fri May 27, 2022 1:27 pm
by MarcoBoschi
Hi Jimmy i've tried but I'm not capable
I'd Like to test a function to launch some applications server side
many thanks
marco
Re: How many time my application is run in memory (SOLVED)
Posted: Sat May 28, 2022 10:23 am
by Jimmy
hi,
you need to enable "winrm" Service on Remote PC
try Powershell on Remote PC and check with
If it is stopped, type:
Add access permission to the remote host.
Code: Select all | Expand
winrm s winrm/config/client '@{TrustedHosts="REMOTECOMPUTERNAME/IP"}'
REMOTECOMPUTERNAME = Name "see" under Network
IP = 192.xxx.xxx.xxx
---
also Windows Firewall is blocking the Remote Access.
goto Firewall and select WMI

when all is enable try
Code: Select all | Expand
get-wmiobject CIM_Memory -computername "192.xxx.xxx.xxx" -credential "username"
you will ask for Password ... and hope now you got access of Memory Information
---
when all work in Powershell you can run you harbour App
Re: How many time my application is run in memory (SOLVED)
Posted: Mon May 30, 2022 11:16 am
by MarcoBoschi
Re: How many time my application is run in memory (SOLVED)
Posted: Mon May 30, 2022 11:53 am
by Otto
Hello Jimmy,
maybe you can just explain what the difference is between RDP and run remote as described here?
Where is the screen displayed when "Run remotely".
Kind regards
Otto
PS: What about a Tirol holiday?
Re: How many time my application is run in memory (SOLVED)
Posted: Mon May 30, 2022 1:25 pm
by Jimmy
hi Otto,
using WMI "just" get Hard-/Software Information of PC, no Screen or "Input"
Re: How many time my application is run in memory
Posted: Mon May 30, 2022 1:37 pm
by Jimmy
hi,
Horizon wrote:Is it possible to read Open Files in Shared folders via WMI?. (My Computer, Manage, System Tools, Shared folder, Open Files)
i need to know "Win32_xxx" to "generate WMI Code using "WMI Code Creator"
https://www.microsoft.com/en-us/download/details.aspx?id=8572it will not "generate" xBase OOP Code but it it easy to "translate"
if you tell me which "Win32_xxx" you are looking for i can "generate" xBase OOP Code
---
"on Server" you can run
look at "Share Folder" -> "Session" and/or ""Open Files"
Re: How many time my application is run in memory (SOLVED)
Posted: Mon May 30, 2022 2:11 pm
by Antonio Linares
Dear Marco,
Using Harbour hbnetio you can execute remote Harbour code on the server.
Ritzan explained that to us recently