This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using (var client = new HttpClient()) | |
| { | |
| //Enable signon and read users' profile | |
| using (var request = new HttpRequestMessage(HttpMethod.Get, "https://graph.microsoft.com/beta/me")) | |
| { | |
| request.Headers.Add("Authorization", "Bearer " + token); | |
| request.Headers.Add("Accept", "application/json;odata.metadata=minimal"); | |
| using (var response = client.SendAsync(request).Result) | |
| { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <html> | |
| <head> | |
| <link rel="stylesheet" href="scrabble.css" type="text/css" /> | |
| <link rel="stylesheet" href="css/ui-dark.css" type="text/css" /> | |
| <script type="text/javascript" src="js/base.js" ></script> | |
| <script type="text/javascript" src="js/ui.js" ></script> | |
| <script type="text/javascript" src="scrabble.js" ></script> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // custom function to sort by asc/desc | |
| var sortOrders = {}; | |
| function sortResultsUsing(pattern, key, callback) { | |
| sortOrders[key] = (sortOrders[key] == "asc") ? "desc" : "asc"; | |
| $('tbody.results>tr').tsort(pattern, { order: sortOrders[key] }); | |
| callback(); | |
| } | |
| /* USAGE |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| private class MyServiceFilter implements ServiceFilter { | |
| @Override | |
| public void handleRequest(final ServiceFilterRequest request, final NextServiceFilterCallback nextServiceFilterCallback, | |
| final ServiceFilterResponseCallback responseCallback) { | |
| nextServiceFilterCallback.onNext(request, new ServiceFilterResponseCallback() { | |
| @Override | |
| public void onResponse(ServiceFilterResponse response, Exception exception) { | |
| if (exception != null) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| (function($){ | |
| $(document).ready(function(){ | |
| // Ensure that the SP.UserProfiles.js file is loaded before the custom code runs. | |
| SP.SOD.executeOrDelayUntilScriptLoaded(loadUserData, 'SP.UserProfiles.js'); | |
| }); | |
| var userProfileProperties; | |
| function loadUserData(){ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| CREATE TABLE UT_USERS (USERID INTEGER Not null primary key generated always as identity (start with 1, increment by 1),USERNAME VARCHAR(15) NOT NULL UNIQUE,PASSWORD VARCHAR(15) NOT NULL, LASTLOGIN TIMESTAMP) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using (ClientContext clientContext = new ClientContext("https://yoursite.sharepoint.com/")) | |
| { | |
| var passWord = new SecureString(); | |
| foreach (char c in "yourpassword".ToCharArray()) passWord.AppendChar(c); | |
| clientContext.Credentials = new SharePointOnlineCredentials("loginname@yoursite.onmicrosoft.com", passWord); | |
| Web web = clientContext.Web; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package visage.javafx.scene.effect; | |
| import visage.animation.Interpolator; | |
| import visage.animation.Timeline; | |
| import visage.javafx.geometry.Rectangle2D; | |
| import visage.javafx.stage.Stage; | |
| import visage.javafx.scene.Group; | |
| import visage.javafx.scene.Scene; | |
| import visage.javafx.scene.effect.*; | |
| import visage.javafx.scene.control.Button; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #For Visage Compilation/Build/Run | |
| command.compile.*.visage=visagec -d . $(FileNameExt) | |
| command.build.*.visage=visagec -d . *.visage | |
| command.go.*.visage=visage -cp . $(FileName) | |
| # jad = decompiled class files; pde = Processing.org sketch files | |
| file.patterns.visage=*.visage | |
| lexer.$(file.patterns.visage)=cpp | |
| word.characters.$(file.patterns.visage)=$(word.chars.cxx)$- |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <html> | |
| <head> | |
| <title>A Yammer App</title> | |
| <script src="https://assets.yammer.com/platform/yam.js"></script> | |
| <script> | |
| yam.config({appId: "APP-ID"}); | |
| </script> | |
| </head> | |
| <body> | |
| <button onclick='post()'>Post on Yammer!</button> |
NewerOlder