Загружен inetmgr.exe В левой области отображен treeview с названием серверов
| Код | Var NodeID, ParentID: HTreeItem; TN, TN2 : TTreeNode; i : integer; bres : integer; Handle: HWND; // хэндл treeview cItem: HTreeItem;
// Выполняется определение cItem 2-ой ветки. ... Handle := .......; cItem := TreeView_GetRoot(Handle); TN := GetNode(Handle, cItem); // Result := GetFirstNode;
I := 1; while (I <> 0) do begin NodeID := TreeView_GetChild(Handle, cItem); if NodeID = nil then NodeID := TreeView_GetNextSibling(Handle, cItem); ParentID := cItem; while (NodeID = nil) and (ParentID <> nil) do begin ParentID := TreeView_GetParent(Handle, ParentID); NodeID := TreeView_GetNextSibling(Handle, ParentID); end; TN := GetNode(Handle, NodeID); cItem := NodeID; Dec(I); end;
bres :=SendMessage(Handle, TVM_SELECTITEM, TVGN_CARET, Longint(cItem));
|
Выдается сообщение
an outgoing call cannot be made since the application is dispatching an input-synchronous call
PS При использовании этого кода на Explore - никаких проблем...
Заранее спасибо !!
M Girder | Пользуйся тегом CODE! |
|