Offline message

Last post 06-25-2009, 2:41 PM by mcselasvegas. 9 replies.
Sort Posts: Previous Next
  •  06-23-2009, 7:49 PM 53431

    Offline message

    Hi There,
     
    I am wondering how the Instant messanger keeps track of which offline message was read by the user...
    I noticed that if you log in and have an offline message, the system will popopen that message... Once read the message will not appear as offline message again, even though marked in the database as offline message...
     
    I am writing some cutom code prompting my users that they have offline messages ie (3) Offline messages. but can not figure out how to mark the messages as read once the user logged in and reviewed there messages.
     
    any help would be great....
  •  06-23-2009, 9:31 PM 53433 in reply to 53431

    Re: Offline message

    Hi,
     
    CuteChat just use a date filed to store the last time the user check the offline message.
     
    When the user checked the offline message , all message before that time would be read.
     
    We are currently working on feature that mention the users there's offline message even they do not open messenger.
     
    Regards,
    Terry
  •  06-24-2009, 8:01 AM 53457 in reply to 53433

    Re: Offline message

    Hi Terry,
     
    Thank you for your swift reply...
    How is cutechat doing that? do you compare the date of last login with the MsgTime in the InstantMessage table?
    Or is there another date field that I am overlooking? in which table should I be looking for that date field.
     
    Thank you,
    Oliver
  •  06-25-2009, 6:30 AM 53502 in reply to 53457

    Re: Offline message

    Hi Terry,
     
    I know you guys are busy but could you please answer my last question briefly, since it is holding up the implementation.
    We are paying customers and just recently bought the domain license for IM
     
    Thank you,
    Oliver
  •  06-25-2009, 8:44 AM 53510 in reply to 53502

    Re: Offline message

    Is this the field that keeps track of it?
    InstantActivateTime:633815083716871840
  •  06-25-2009, 8:46 AM 53511 in reply to 53510

    Re: Offline message

    How do I decifer this record?
     
    InstantActivateTime:633815091349297127
  •  06-25-2009, 10:01 AM 53522 in reply to 53510

    Re: Offline message

    Hi,
     
    Yes. it's stored in the ServerProperties field.
     
    You can deserialize it using this method:
     
    NameValueCollection ChatUtility.GetProperties(string)
     
    Regards,
    Terry
  •  06-25-2009, 11:58 AM 53529 in reply to 53522

    Re: Offline message

    Hi Terry,
     
    sorry for my lack of knowledge but how do I get a Date out of this string  "InstantActivateTime:633815108295813936" ?
     
    Dim myCol As New NameValueCollection()
    myCol = CuteChat.ChatUtility.GetProperties("InstantActivateTime:633815108295813936")

    Dim s As String

    For Each s In myCol.AllKeys

    Dim MyStuff As String = myCol(s)

    Next s

    does not give me a date that i can use to see if a message was read or not...
    I guess what i don't know is how to deserialize the string...
    any help would be great

     
     
  •  06-25-2009, 1:43 PM 53535 in reply to 53529

    Re: Offline message

    Hi
    Dim nvc as NameValueCollection = ChatUtility.GetProperties("InstantActivateTime:633815108295813936")
     
    Dim timestr=nvc("InstantActivateTime")
     
    if timestr is nothing then
       'no such key/value
    else
       Dim time=new DateTime(Convert.ToInt64(nvc("InstantActivateTime")))
    end
     
    Regards,
    Terry
     
  •  06-25-2009, 2:41 PM 53536 in reply to 53535

    Re: Offline message

    Hi Terry,
     
    That got the job done... your help is very much appreciated...
     
    Oliver
View as RSS news feed in XML