Closed Thread
Results 1 to 2 of 2

Validação de Usuário, login e senha

  1. #1
    Registered User
    Join Date
    05-28-2020
    Location
    brasil
    MS-Off Ver
    2016
    Posts
    8

    Validação de Usuário, login e senha

    Boa noite amigos ... Estou meio frustrado com um problema, depois de muito tentar, não consigo fazer com o botão Entrar (valide the usurário) clicando nele nada faz.

    Consigo executar a Primeira ea Segunda parte do roteiro com Sucesso, mais uma Terceira parte nada Acontece

    segue o código * Abaixo *. (Legenda:. Form_Loguin * / Text_Login ea Aba fazer Excel ficou com o Nome de Acesso)

    agradeço a Ajuda'

    procedimento para o botão entrar





    Sub Entrar()

    Usuario = Form_Loguin.Text_Login
    Senha = Form_Loguin.Text_Senha

    'primeira parte -verifica os capos vazios

    If Form_Loguin.Text_Login = "" Then
    MsgBox "Entre com o Nome de Usuário", vbInformation, "USUÁRIO"

    Exit Sub

    End If
    If Form_Loguin.Text_Senha = "" Then
    MsgBox "Entre Com a Senha do Usuário", vbInformation, "SENHA"

    Exit Sub

    End If

    'Segunda parte - Verifica se é administador e se for entra

    If Form_Loguin.Text_Login = "ADMIN" And Form_Loguin.Text_Senha = "ADMIN" Then
    MsgBox "Bem vindo Administrador", vbOKOnly, "ACESSO LIBERADO"

    Sheets("Login").Select

    Exit Sub

    End If

    'Terceira parte - Verifica se o usuário e senha estão no banco de dados (daqui em diante,nada acontece)

    linha = 2

    Do Until Sheets("Login").Cells(linha, 1) = ""

    If Sheets("Login").Cells(linha, 1) = Form_Loguin.Text_Login And Sheets("Login").Cells(linha, 2) = Form_Loguin.Text_Senha Then

    MsgBox "Bem Vindo" & Usuario, vbOKOnly, "ACESSO LIBERADO"

    Unload Form_Loguin
    Sheets("Home").Select

    Exit Sub

    End If
    linha = linha + 1
    Loop

    End Sub

  2. #2
    Forum Moderator alansidman's Avatar
    Join Date
    02-02-2010
    Location
    Steamboat Springs, CO
    MS-Off Ver
    MS Office 365 Version 2404 Win 11 Home 64 Bit
    Posts
    23,855

    Re: Validação de Usuário, login e senha

    Administrative Note:

    Welcome to the forum.

    Unfortunately, this is a duplicate thread, and you are allowed only ONE thread per issue here.

    Please see Forum Rule #5 about thread duplication.

    I am closing this thread, but you may continue here in the original thread: https://www.excelforum.com/non-engli...uario-vba.html
    Alan עַם יִשְׂרָאֵל חַי


    Change an Ugly Report with Power Query
    Database Normalization
    Complete Guide to Power Query
    Man's Mind Stretched to New Dimensions Never Returns to Its Original Form

Closed Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Validação de De login e usuário vba
    By leegrj in forum Non English Excel
    Replies: 1
    Last Post: 05-31-2020, 09:34 PM
  2. [SOLVED] VBA Macro to capture the First Login & Last Logout with Total Login Hours Delivered
    By Yadavgiri in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 05-08-2020, 01:02 PM
  3. Need help in login vba code to unhide specific sheets depends on login info
    By AlaaEddin95 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 05-12-2019, 08:19 PM
  4. Create login screen with multiple login id and password
    By anilpatni1234 in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 08-01-2018, 10:14 AM
  5. Replies: 1
    Last Post: 04-30-2017, 08:26 PM
  6. Senha
    By XANDEMAT in forum Non English Excel
    Replies: 1
    Last Post: 03-07-2014, 07:10 AM
  7. Senha
    By XANDEMAT in forum Excel - New Users/Basics
    Replies: 1
    Last Post: 03-07-2014, 07:10 AM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1