Hi All, How to get the status of all ports on the remote system? I need to give a list of ports that are listening, opened, waiting to close etc. Almost the same output as: netstat -o
The only thing is that, I need to get the information of remote system. I am trying WMI, but, no luck yet. Any help is greatly appreciated. Regards, KVRN Kiran Kumar.
kvrnkiran
Posts
-
Ports status on remote system -
Uninstall menu for application by Windows InstallerHi, You need to keep you application specific data in the following key:
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall
Observe the keys already there in this registry path. Hope that helps. Kiran. -
Help with conversion to VC* - Linker errorHi Bill, I guess, you have "Ignore All Default libraries" option selected. Unselect this option. Go to project settings and choose Link option and uncheck the Ignore All default libraries check box (if you are using VS2003 and above, choose No in the list. The name of the item is same). Hope that helps. Kiran.
-
Creating TimeStampHi, For the year, you need to add 1900 (see MSDN for more information). So, your
sprintf
turn to:sprintf(dateString,"**%4d%02d%02d**",newtime->tm_year **+ 1900** , newtime->tm_mon, newtime->tm_mday); sprintf(timeString,"**%02d%02d%02d**",newtime->tm_hour, newtime->tm_min, newtime->tm_sec);
The bold letters are those places where I made changes. Hope that helps. Kiran. -
Physical disk information of a remote systemHi, I am trying to fetch the information about remote computer. Initially, I need the information of number of physical disks and their sizes. I am taking help of the following registry key to get the number of physical disks (I am opening remote registry and querying these keys):
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\IDE HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\SCSI
These keys contains the number of disks on the system. But, I am unable to fetch their sizes.CreateFile
is not opening physical disks on remote system (returning INVALID_HANDLE_VALUE). Can anybody help resolving this issue? Kiran. -
Owner Draw button changes the tab orderHi BlrBoy, Try using
SWP_NOZORDER
in yourSetWindowPos
function. This retains the Z-order of the control. Hope that helps. Kiran. -
Attaching popup menu to an existing menuHi Paritha, Here is a sample code:
CMenu menu; menu.CreatePopupMenu(); menu.AppendMenu(MF_STRING, 10, "item 1"); CPoint pt; GetCursorPos(&pt); //Now, create the submenu CMenu menu1; menu1.CreatePopupMenu(); menu1.AppendMenu(MF_STRING, 11, "Item 1 in submenu1"); //attach the submenu to main menu menu.AppendMenu(MF_POPUP, (UINT_PTR)menu1.m_hMenu, "Submenu1"); menu.TrackPopupMenu(TPM_RETURNCMD, pt.x, pt.y, this);
Hope that helps. Kiran. -
ClistCtrl DoubleClick Hit Column???Hi, Use
CListCtrl::SubItemHitTest
instead. This returns both the item and sub-item as well. Kiran -
SendMessage to Worker threadYes. It is possible. Use
PostThreadMessage
. Hope that helps. Kiran.