Exemplo n.º 1
0
        public static string LogUserData(string URL, string OS, string BrowserName, string BrowserVersion, string screenHeight, string screenWidth)
        {
            DataAccessBase base2 = new DataAccessBase(connectionString);

            return(base2.ScalarTxt(string.Format("INSERT INTO [dbo].[userActivity]([date],[userId],[pageTitle],[OS],[browserVersion],[browserName],[screenHeight],[screenWidth]) OUTPUT Inserted.ID  VALUES ('{0}',{1},N'{2}','{3}',{4},'{5}',{6},{7})", new object[] { DateTime.Now, SPContext.Current.Web.CurrentUser.ID, URL, OS, BrowserVersion, BrowserName, screenHeight, screenWidth })).ToString());
        }