Author: Aymeric

Show/Hide a Sharepoint fields in the NewForm, EditForm and DispForm

With the Sharepoint WebServices it’s possible to hide a field into the NewForm, the Editform and/or the DispForm. You’ll need to use JavaScript with jQuery and SPServices. It’s the UpdateList service that will do the trick. Once you have loaded the both librairies you can use the below code: var fieldsToUpdate = ‘<Fields>’; fieldsToUpdate += […]

Delete a User Custom Action from Sharepoint [JavaScript]

The MSDN documentation is a nightmare…. For example Microsoft provides an example to create a User Custom Action for Sharepoint, however there is no code about how to delete it. So here is the code to use to delete the usercustomaction just created with the above example: var siteUrl = ‘/site collection/site/’; function deleteUserCustomAction() { […]

Dynamically inject a CSS code into the page [JavaScript]

Mozilla created a function that permits to inject some CSS into the document: addStylesheetRules() But if you use jQuery you may want to use this function: function injectCSS(rule) { $(“head”).append(‘<style>’ + rule + ‘</style>’) } // example injectCSS(“div { padding:5px }”)

Tiny AJAX

This is a very tiny javascript code to do an AJAX Request: /* m: method (“get”, “post”) u: url a: async (true) or sync (false) c: callback (with ‘xhr’ as a parameter) d: post_data (the data to post) */ function tiny_ajax(m,u,a,c,d){with(new(this.XMLHttpRequest||ActiveXObject)(“Microsoft.XMLHTTP”))onreadystatechange=function(){readyState^4||c(this)},open(m,u,a),send(d)} And an example: tiny_ajax(‘get’, ‘http://www.google.com’, true, function(xhr) { alert(xhr.responseText) })

Se connecter à son réseau local via le VPN de la Freebox Revolution

Grâce aux dernières mises à jour de la Freebox Revolution, il est maintenant possible de se connecter à son réseau local depuis l’extérieur. Cela peut être utile pour, par exemple, accéder à un ordinateur de son réseau, etc. On va d’abord ouvrir l’accès à sa Freebox depuis l’extérieur. Pour ce faire, se rendre sur http://mafreebox.freebox.fr/ […]

Redémarrer un ordinateur à distance

Tout d’abord, sur l’ordinateur qu’on souhaite faire redémarrer, il faut se rendre dans : Panneau de Configuration → Réseau et Internet → Centre réseau et partage → Modifier les paramètres de partage avancés puis Activer le partage de fichiers et d’imprimantes dans “Privé” : Ensuite il faut ouvrir la base de registre avec la commande […]

How to change the Firefox portable main window icon? [Astuce]

If you use Firefox Portable in the same time as the regular Firefox, then it can be annoying to see the same icons for the both Firefox. You can easily change the icon for the main window of the portable version of Firefox. Just find the .ico you want to use and place it into […]