access rights problems

Collapse
X
 
  • Time
  • Show
Clear All
new posts

  • charvi
    replied
    Originally posted by jamesd0142
    In vb.net you can retrieve the username like this:

    [code=vbnet]
    Declare Function GetUserName Lib "advapi32.d ll" Alias _
    "GetUserNam eA" (ByVal lpBuffer As String, _
    ByRef nSize As Integer) As Integer

    Public Function GetUserName() As String
    Dim iReturn As Integer
    Dim userName As String
    userName = New String(CChar(" "), 50)
    iReturn = GetUserName(use rName, 50)
    GetUserName = userName.Substr ing(0, userName.IndexO f(Chr(0)))
    End Function
    [/code]
    how can i retreive user name in vb6

    Leave a comment:


  • jamesd0142
    replied
    In vb.net you can retrieve the username like this:

    [code=vbnet]
    Declare Function GetUserName Lib "advapi32.d ll" Alias _
    "GetUserNam eA" (ByVal lpBuffer As String, _
    ByRef nSize As Integer) As Integer

    Public Function GetUserName() As String
    Dim iReturn As Integer
    Dim userName As String
    userName = New String(CChar(" "), 50)
    iReturn = GetUserName(use rName, 50)
    GetUserName = userName.Substr ing(0, userName.IndexO f(Chr(0)))
    End Function
    [/code]

    Leave a comment:


  • charvi
    replied
    Originally posted by debasisdas
    From where you get the employee name ?

    Is it stored in database table ?
    It is maintained in the server.i dont know exactly where the name is stord this name is the login name when we login to the system

    Leave a comment:


  • debasisdas
    replied
    From where you get the employee name ?

    Is it stored in database table ?

    Leave a comment:


  • charvi
    replied
    Originally posted by debasisdas
    You are storing user names in database tables ?
    how do i get user names when i login to computer please can u explain in detail

    Leave a comment:


  • debasisdas
    replied
    You are storing user names in database tables ?

    Leave a comment:


  • jamesd0142
    replied
    Originally posted by charvi
    I have adeveloped a time sheet project where each employee time sheet is maintained.Now since i want to use in network when i login to the system with a name for eg Smitha.i want have accessonly to all records by smitha.my project is in vb and ms access please help me


    suppose you could detect the user profile name, and create a sql statement according to that...

    Leave a comment:


  • charvi
    started a topic access rights problems

    access rights problems

    I have adeveloped a time sheet project where each employee time sheet is maintained.Now since i want to use in network when i login to the system with a name for eg Smitha.i want have accessonly to all records by smitha.my project is in vb and ms access please help me
Working...