USUÁRIO:      SENHA:        SALVAR LOGIN ?    Adicione o VBWEB na sua lista de favoritos   Fale conosco 

 

  Fórum

  Visual Basic
Voltar
Autor Assunto:  posicionar no 1º item do listview
EdsonZanatta
PORTO FERREIRA
SP - BRASIL
Postada em 27/05/2004 22:29 hs            
Tem Jeito ?
     
Vaughyman
RIO DE JANEIRO
RJ - BRASIL
Postada em 27/05/2004 23:28 hs            
Depende de que jeito. Se vc já tiver um recordset aberto e quiser que haja foco no item relacionado numa listview, pode-se usar esse código.
 
Private Sub FocaItem()
lvwUnid.HideSelection = False
Dim LItem As ListItem, FindItem As String, NotFound As Boolean
' what to find
    FindItem = txtIdUnid.text   '("Find what?") 'Coloque aquio que vc quer achar na lista
' search in the list's Items
    Set LItem = lvwUnid.FindItem(FindItem, lvwText, , lvwPartial)
    If LItem Is Nothing Then
' if not found, then search for the same argument in the subitems
        Set LItem = lvwUnid.FindItem(FindItem, lvwSubItem, , lvwPartial)
        If LItem Is Nothing Then
            NotFound = True
        End If
    End If
' if the item was not found anywhere, do nothing
    If NotFound Then
        'MsgBox "Não foi encontrada nenhuma ocorrência para o texto digitado", vbInformation, _
                "Nenhuma ocorrência"
        Exit Sub
    Else
' else make the found item visible
        LItem.EnsureVisible
        LItem.Selected = True
        'Debug.Print LItem.Text
   
    End If
End Sub

"IF FUNCIONOU = TRUE THEN Emoções

     BLOQUEIE O POST

ELSE Emoções

    POST NOVAMENTE INFORMANDO O QUE ACONTECEU

ENDIF Emoções

     
Página(s): 1/1    


Seu Nome:

Seu eMail:

ALTERAR PARA MODO HTML
Mensagem:

[:)] = 
[:P] = 
[:(] = 
[;)] = 

HTML DESLIGADO

     
 VOLTAR

  



CyberWEB Network Ltda.    © Copyright 2000-2025   -   Todos os direitos reservados.
Powered by HostingZone - A melhor hospedagem para seu site
Topo da página