Integration with Existing DB

Last post 07-23-2008, 1:33 PM by Adam. 1 replies.
Sort Posts: Previous Next
  •  07-17-2008, 1:34 AM 42279

    Integration with Existing DB

    hi,
    i am having some issues with integration of webmessenger with my Asp.net Website.
     
    I am developing website in asp.net 2.0 , which having some predefined users and i am authenticating them on my website simply by matching their credentials from the DB---- no membership features used. I did same as wat stated in developers guide. I executed scripts for Db ( CuteChat4 ), Added respected Cutesoft_client files and dll in bin folder. & customized my Chat provider as follows :-
     

    Imports Microsoft.VisualBasic

    Public Class MMSCHATPROVIDER
     
    Inherits CuteChat.ChatProvider
    Public Function GetLogonUser()
     
    Dim username As String = HttpContext.Current.Session("DisplayFirstName").ToString

    Return username

    End Function

    Public Overrides Function GetConnectionString() As String

    Dim conn As String = System.Configuration.ConfigurationSettings.AppSettings("strCon")

    Return conn

    End Function

    Public Overrides Function GetLogonIdentity() As CuteChat.AppChatIdentity

    Return New CuteChat.AppChatIdentity(HttpContext.Current.Session("DisplayFirstName").ToString.ToUpper, False, HttpContext.Current.Session("USER_EMP_CODE").ToString, HttpContext.Current.Request.UserHostAddress)

    End Function

    Public Overrides Function GetUserInfo(ByVal loginName As String, ByRef nickName As String, ByRef isAdmin As Boolean) As Boolean

    If HttpContext.Current.Session("DisplayFirstName").ToString = "admin" Then

    isAdmin = True

    Return True

    Else

    isAdmin = False

    Return True

    End If

    End Function

    Public Overrides Function FindUserLoginName(ByVal nickName As String) As String

    Try

    Return HttpContext.Current.Session("DisplayFirstName").ToString

    Catch ex As Exception

    Return Nothing

    End Try

    End Function

    Public Overrides Function ValidateUser(ByVal loginName As String, ByVal password As String) As Boolean

    Return True

    End Function

    End Class
     
     
    but when i executed my code , my user got logged with no issues , but not able to add diff contacts ,
     
    Plz help me as fast as u can ..
    thanks
    Prashant
View as RSS news feed in XML