Hi,
Does a FreeBasic include file for WTSapi32 exist and if so where can I get it?
Thanks,
ring0
WTSapi32
-
- Posts: 2958
- Joined: Jun 02, 2015 16:24
Re: WTSapi32
Hi,
I dont know the answer to your question but if you're looking for a way of making speach under Windows, here is a dummy example that I crafted previously. I just grabbed the speach procedures from somewhere in the forum and used it for fun:
https://freebasic.net/forum/viewtopic.p ... 2A#p231586
Maybe it can help?
I dont know the answer to your question but if you're looking for a way of making speach under Windows, here is a dummy example that I crafted previously. I just grabbed the speach procedures from somewhere in the forum and used it for fun:
https://freebasic.net/forum/viewtopic.p ... 2A#p231586
Maybe it can help?
Re: WTSapi32
Hello Tourist Trap,
Thank you for your offer but I am not looking for a way of making speech under windows.
As far as I know WTSapi = Remote Desktop Services API
It can be used to enumerate processes by name which is what I want to do.
Cheers,
ring0
Thank you for your offer but I am not looking for a way of making speech under windows.
As far as I know WTSapi = Remote Desktop Services API
It can be used to enumerate processes by name which is what I want to do.
Cheers,
ring0
-
- Posts: 2958
- Joined: Jun 02, 2015 16:24
Re: WTSapi32
I see, I confounded with sapi.ring0 wrote:.
As far as I know WTSapi = Remote Desktop Services API
It can be used to enumerate processes by name which is what I want to do.
https://msdn.microsoft.com/en-us/library/windows/desktop/ms682623(v=vs.85).aspx
It is about enumerating all active processes in the link above. I still dont know anyway how to make this work in fb. I will try to translate the msdn example once at home I think.
Have a good day.
Re: WTSapi32
Hello TouristTrap,
Thank you for the link. That looks like it will accomplish what I want and so I will give it a try.
Cheers,
ring0
Thank you for the link. That looks like it will accomplish what I want and so I will give it a try.
Cheers,
ring0
Re: WTSapi32
Something like this?ring0 wrote:It can be used to enumerate processes by name which is what I want to do.
Code: Select all
Print "ct", Tb$, "ID", Tb$, "path"
For_ count=0 To GetProcessArray(?)-1
Print Str$("\n%i\t", count), Str$(MbProcID(count)), Tb$, MbProc$(count)
Next
Code: Select all
ct ID path
0 2668 C:\Windows\System32\taskhost.exe
1 3164 C:\Program Files (x86)\NVIDIA Corporation\NvContainer\nvcontainer.exe
2 1216 C:\Windows\System32\dwm.exe
3 2408 C:\Windows\explorer.exe
4 3480 C:\Program Files\Microsoft Security Client\msseces.exe
5 2496 C:\Program Files (x86)\AutoHotkey\AutoHotkey.exe
6 2956 C:\ArcZip\FreeCommander\FreeCommander.exe
Re: WTSapi32
I did a such list for fbdebugger.
Code: Select all
#Include Once "windows.bi"
#Include Once "win\tlhelp32.bi"
#Include Once "win\psapi.bi"
#Define fmt(t,l) Left(t,l)+Space(l-Len(t))+" "
Dim prcinfo As PROCESSENTRY32,snap As HANDLE
snap=CreateToolhelp32Snapshot (TH32CS_SNAPPROCESS, 0)'Take snapshot of running processes
If snap <> INVALID_HANDLE_VALUE Then
prcinfo.dwSize=SizeOf(PROCESSENTRY32)
Print "file Process name ID Nthread parent id"
If Process32First (snap,@prcinfo) Then
Do
Print fmt(prcinfo.szExeFile,30)+fmt(Str(prcinfo.th32ProcessID),5)+fmt(Str(prcinfo.cntThreads),3)+fmt(Str(prcinfo.th32ParentProcessID),5)
Loop While Process32Next (snap,@prcinfo)
Else
Print "Process list error, Failed to create process list!"
End If
CloseHandle (snap)
Else
Print "Process list error, Failed to create process list!"
End If
Sleep
Re: WTSapi32
Thank you jj2007 and SARG for the info.
My initial interest in the WTSapi32.dll was from this link
http://codexpert.ro/blog/2013/12/01/li ... ices-api/
which seems to provide a very easy solution. However, I shall explore the methods that you have suggested since FB support already exists for them.
I may also try dynamically linking to WTSapi32.dll just as an exercise.
Thanks to all,
ring0
My initial interest in the WTSapi32.dll was from this link
http://codexpert.ro/blog/2013/12/01/li ... ices-api/
which seems to provide a very easy solution. However, I shall explore the methods that you have suggested since FB support already exists for them.
I may also try dynamically linking to WTSapi32.dll just as an exercise.
Thanks to all,
ring0