Página 4 de 4

Funções com API do Windows

Enviado: 08 Mar 2013 09:45
por Mário Isa
ok. obrigado.. vou testar...
também vou atentar para colocar as dúvidas tudo na última janela...

também o tutor20 o problema era q eu deixava o avast rodá-lo dentro da sandbox e aí travava...
fora dela não...

Obrigado.
Mário

Funções com API do Windows

Enviado: 08 Mar 2013 11:46
por Mário Isa
Sobre a função de que falamos lá atrás:

Código: Selecionar todos

Local aTitles := GetTitles( GetForegroundWindow() )
Teria como eu mandar um parâmetro para ela me mostrar os processos de todos os usuários? (no caso de "i" os invisíveis)

Mário

Funções com API do Windows

Enviado: 08 Mar 2013 18:01
por Pablo César
Mário Isa escreveu:Teria como eu mandar um parâmetro para ela me mostrar os processos de todos os usuários?
Mario, a função GetForegroundWindow() te traz a janelas que estão abertas na CPU onde está sendo executado. Portanto não há comando que rastrei todas as janelas que estão abertas de todos em um rede. Seria isso que você está pedindo ??

Funções com API do Windows

Enviado: 08 Mar 2013 23:07
por Mário Isa
ok. Pablo
Terei que me contentar com o comando
qprocess * (comando via DOS)
POrém no W-7 nem tem. Eu tive q pegar o qprocess.exe do XP.
Mas tudo bem...

Obrigado.

Funções com API do Windows

Enviado: 08 Mar 2013 23:30
por Pablo César
Eu não conhecia o qprocess.exe, agora entendo o que você dizia. Pensei que você queria fazer uma espécie de TRACKING dos processos em outros computadores. O que você quer é filtrar o processo do usuário, eliminando o que forem de sistemas. Acredito que em C isso é possível.

Funções com API do Windows

Enviado: 09 Mar 2013 01:00
por Mário Isa
tipo assim:
saber se, por ex. o acbrmonitor.exe está rodando neste computador / mas com outro usuário..... //

he he he

mas a essas alturas do campeonato consegui resolver meus problemas e abandonei o wapi.exe /
com a sua ajuda.

obrigado.
Mário

Funções com API do Windows

Enviado: 12 Ago 2014 18:45
por Mário Isa
Pablo,
Tem como deixar este .EXE mais pequeno ?
Mesmo compactado ele fica com 1.039 KB.

Mário

Funções com API do Windows

Enviado: 13 Ago 2014 08:34
por asimoes
Olá Mário
Pode utilizar o usar o UPX para compactar.

Funções com API do Windows

Enviado: 13 Ago 2014 12:00
por JoséQuintas
Tem a função de API do WIndows, findwindow() ou algo parecido.
Ela encontra processos pelo nome da janela.

Funções com API do Windows

Enviado: 13 Ago 2014 12:22
por Itamar M. Lins Jr.
Ola!
Para os que não sabem . o Harbour possue vários comandos e funções para nós programadores a respeito das api´s do windows.
Os exemplos de uso de algumas na pasta \contrib\hbwin, fazem parte da lib hbwin.
Inclusive a wapi_FindWindow()

Código: Selecionar todos

C:\Users\Itamar>hbmk2 -find wapi_*
hbwin.hbc (instalado):
   wapi_AbortDoc()
   wapi_AddFontResource()
   wapi_AddFontResourceEx()
   wapi_AppendMenu()
   wapi_Arc()
   wapi_CheckMenuItem()
   wapi_CheckMenuRadioItem()
   wapi_ComboBox_AddString()
   wapi_CreateAcceleratorTable()
   wapi_CreateDC()
   wapi_CreateFont()
   wapi_CreateFontIndirect()
   wapi_CreateHatchBrush()
   wapi_CreateMenu()
   wapi_CreateMutex()
   wapi_CreatePen()
   wapi_CreatePopupMenu()
   wapi_CreateSolidBrush()
   wapi_CreateWindowEx()
   wapi_DeleteMenu()
   wapi_DestroyacceleratorTable()
   wapi_DestroyMenu()
   wapi_DestroyWindow()
   wapi_DialogBoxParam()
   wapi_DrawMenuBar()
   wapi_DrawText()
   wapi_Ellipse()
   wapi_EnableMenuItem()
   wapi_EnableScrollBar()
   wapi_EndDialog()
   wapi_EndDoc()
   wapi_EndPage()
   wapi_ExtTextOut()
   wapi_FillRect()
   wapi_FindWindow()
   wapi_FormatMessage()
   wapi_FreeLibrary()
   wapi_GetACP()
   wapi_GetActiveWindow()
   wapi_GetBkColor()
   wapi_GetBkMode()
   wapi_GetCommandLine()
   wapi_GetCurrentProcess()
   wapi_GetCurrentProcessId()
   wapi_GetCurrentThread()
   wapi_GetCurrentThreadId()
   wapi_GetDesktopWindow()
   wapi_GetDeviceCaps()
   wapi_GetDialogBaseUnits()
   wapi_GetDlgItem()
   wapi_GetDlgItemText()
   wapi_GetKeyboardLayout()
   wapi_GetKeyboardLayoutName()
   wapi_GetKeyState()
   wapi_GetLastError()
   wapi_GetLongPathName()
   wapi_GetMapMode()
   wapi_GetMenu()
   wapi_GetMenuDefaultItem()
   wapi_GetMenuItemCount()
   wapi_GetMenuItemId()
   wapi_GetMenuState()
   wapi_GetModuleHandle()
   wapi_GetOEMCP()
   wapi_GetProcAddress()
   wapi_GetScrollInfo()
   wapi_GetScrollPos()
   wapi_GetScrollRange()
   wapi_GetShortPathName()
   wapi_GetSubMenu()
   wapi_GetSysColor()
   wapi_GetSystemDirectory()
   wapi_GetSystemMenu()
   wapi_GetSystemMetrics()
   wapi_GetTextAlign()
   wapi_GetTextColor()
   wapi_GetTextFace()
   wapi_GetVolumeInformation()
   wapi_GetWindowsDirectory()
   wapi_ImageList_Add()
   wapi_ImageList_AddMasked()
   wapi_ImageList_BeginDrag()
   wapi_ImageList_Copy()
   wapi_ImageList_Create()
   wapi_ImageList_Destroy()
   wapi_ImageList_DragEnter()
   wapi_ImageList_DragLeave()
   wapi_ImageList_DragMove()
   wapi_ImageList_DragShowNolock()
   wapi_ImageList_Draw()
   wapi_ImageList_DrawEx()
   wapi_ImageList_Duplicate()
   wapi_ImageList_GetBkColor()
   wapi_ImageList_GetIcon()
   wapi_ImageList_GetIconSize()
   wapi_ImageList_GetImageCount()
   wapi_ImageList_GetImageInfo()
   wapi_ImageList_LoadImage()
   wapi_ImageList_Merge()
   wapi_ImageList_Remove()
   wapi_ImageList_Replace()
   wapi_ImageList_ReplaceIcon()
   wapi_ImageList_SetBkColor()
   wapi_ImageList_SetDragCursorImage()
   wapi_ImageList_SetIconSize()
   wapi_ImageList_SetImageCount()
   wapi_InsertMenu()
   wapi_IsIconic()
   wapi_IsMenu()
   wapi_IsUserAnAdmin()
   wapi_IsValidCodePage()
   wapi_IsWindow()
   wapi_IsZoomed()
   wapi_LineTo()
   wapi_LoadImage()
   wapi_LoadLibrary()
   wapi_LoadMenu()
   wapi_MessageBeep()
   wapi_MessageBox()
   wapi_MoveToEx()
   wapi_MulDiv()
   wapi_OpenMutex()
   wapi_OutputDebugString()
   wapi_PlaySound()
   wapi_QueryPerformanceCounter()
   wapi_QueryPerformanceFrequency()
   wapi_Rectangle()
   wapi_ReleaseMutex()
   wapi_RemoveFontResource()
   wapi_RemoveFontResourceEx()
   wapi_RemoveMenu()
   wapi_ResetDC()
   wapi_RoundRect()
   wapi_SelectObject()
   wapi_SetActiveWindow()
   wapi_SetBkColor()
   wapi_SetBkMode()
   wapi_SetDlgItemText()
   wapi_SetErrorMode()
   wapi_SetFocus()
   wapi_SetLastError()
   wapi_SetMapMode()
   wapi_SetMenu()
   wapi_SetMenuDefaultItem()
   wapi_SetProcessWorkingSetSize()
   wapi_SetScrollInfo()
   wapi_SetScrollPos()
   wapi_SetScrollRange()
   wapi_SetTextAlign()
   wapi_SetTextColor()
   wapi_SetWindowPos()
   wapi_ShellExecute()
   wapi_ShowScrollBar()
   wapi_Sleep()
   wapi_StartDoc()
   wapi_StartPage()
   wapi_TabCtrl_AddItem()
   wapi_TabCtrl_AdjustRect()
   wapi_TabCtrl_Create()
   wapi_TabCtrl_DeleteAllItems()
   wapi_TabCtrl_DeleteItem()
   wapi_TabCtrl_DeselectAll()
   wapi_TabCtrl_GetCurFocus()
   wapi_TabCtrl_GetCurSel()
   wapi_TabCtrl_GetExtendedStyle()
   wapi_TabCtrl_GetImageList()
   wapi_TabCtrl_GetItem()
   wapi_TabCtrl_GetItemCount()
   wapi_TabCtrl_GetItemRect()
   wapi_TabCtrl_GetRowCount()
   wapi_TabCtrl_GetToolTips()
   wapi_TabCtrl_GetUnicodeFormat()
   wapi_TabCtrl_HighlightItem()
   wapi_TabCtrl_HitTest()
   wapi_TabCtrl_InsertItem()
   wapi_TabCtrl_RemoveImage()
   wapi_TabCtrl_SetCurFocus()
   wapi_TabCtrl_SetCurSel()
   wapi_TabCtrl_SetExtendedStyle()
   wapi_TabCtrl_SetImageList()
   wapi_TabCtrl_SetItem()
   wapi_TabCtrl_SetItemExtra()
   wapi_TabCtrl_SetItemSize()
   wapi_TabCtrl_SetMinTabWidth()
   wapi_TabCtrl_SetPadding()
   wapi_TabCtrl_SetToolTips()
   wapi_TabCtrl_SetUnicodeFormat()
   wapi_TextOut()
   wapi_TrackPopupMenu()
   wapi_TreeView_CreateDragImage()
   wapi_TreeView_DeleteAllItems()
   wapi_TreeView_EditLabel()
   wapi_TreeView_EndEditLabelNow()
   wapi_TreeView_EnsureVisible()
   wapi_TreeView_Expand()
   wapi_TreeView_GetBkColor()
   wapi_TreeView_GetCheckState()
   wapi_TreeView_GetChild()
   wapi_TreeView_GetCount()
   wapi_TreeView_GetDropHilight()
   wapi_TreeView_GetEditControl()
   wapi_TreeView_GetFirstVisible()
   wapi_TreeView_GetImageList()
   wapi_TreeView_GetIndent()
   wapi_TreeView_GetInsertMarkColor()
   wapi_TreeView_GetISearchString()
   wapi_TreeView_GetItem()
   wapi_TreeView_GetItemHeight()
   wapi_TreeView_GetItemRect()
   wapi_TreeView_GetItemState()
   wapi_TreeView_GetLastVisible()
   wapi_TreeView_GetLineColor()
   wapi_TreeView_GetNextItem()
   wapi_TreeView_GetNextSibling()
   wapi_TreeView_GetNextVisible()
   wapi_TreeView_GetParent()
   wapi_TreeView_GetPrevSibling()
   wapi_TreeView_GetPrevVisible()
   wapi_TreeView_GetRoot()
   wapi_TreeView_GetScrollTime()
   wapi_TreeView_GetSelection()
   wapi_TreeView_GetTextColor()
   wapi_TreeView_GetToolTips()
   wapi_TreeView_GetUnicodeFormat()
   wapi_TreeView_GetVisibleCount()
   wapi_TreeView_HitTest()
   wapi_TreeView_InsertItem()
   wapi_TreeView_Select()
   wapi_TreeView_SelectDropTarget()
   wapi_TreeView_SelectItem()
   wapi_TreeView_SelectSetFirstVisible()
   wapi_TreeView_SetBkColor()
   wapi_TreeView_SetCheckState()
   wapi_TreeView_SetImageList()
   wapi_TreeView_SetIndent()
   wapi_TreeView_SetInsertMark()
   wapi_TreeView_SetInsertMarkColor()
   wapi_TreeView_SetItem()
   wapi_TreeView_SetItemHeight()
   wapi_TreeView_SetItemState()
   wapi_TreeView_SetLineColor()
   wapi_TreeView_SetScrollTime()
   wapi_TreeView_SetTextColor()
   wapi_TreeView_SetToolTips()
   wapi_TreeView_SetUnicodeFormat()
   wapi_TreeView_SortChildren()
   wapi_WaitForMultipleObjects()
   wapi_WaitForMultipleObjectsEx()
   wapi_WaitForSingleObject()
   wapi_WaitForSingleObjectEx()
   wapi_WNetGetLastError()
   __wapi_DEVMODE_Get()
   __wapi_DEVMODE_New()
   __wapi_DEVMODE_Set()
N├║cleo Harbour (instalado):
   __wapi_GetACP()
   __wapi_GetConsoleOutputCP()
   __wapi_GetOEMCP()
Saudações,
Itamar M. Lins Jr.

Funções com API do Windows

Enviado: 13 Ago 2014 12:55
por JoséQuintas
Complementando, o próprio Harbour pode ajudar, sabendo-se parte do nome da API.
hbmk2 -find findwindow

Funções com API do Windows

Enviado: 13 Ago 2014 13:02
por Jairo Maia
E complementando um pouco mais, o comando -find funciona apenas a partir da versão 3.2.