List GUID?! When in doubt, you DECODE!

As much as I love using my SharePoint(online, offline, on-premise, on-cloud and everything else in between) sites, its lists, libraries…Ahem., apps and creating slick looking reporting solutions for anyone who is bored(aka moi) and wants to analyze the rows and rows of information gathered, I sometimes find very frustrated that my List name doesn’t work in my scripts! Arrggg…

I know you exist in my site! I know I typed the name right! I even put %20 for space
I know you exist in my site! I know I typed the name right! I even put %20 for space

After spending half hour trying to decode-encode-decode space and special characters with whatever I could gather from my dimly active neurons, the idea dawns. Let me just get the entire URL and decode it ha! That will teach the list to behave. and it did! its really a medical miracle! Yes, yes, there are several other ways to get it. I know, but this is cool too and I did it now and so I share.

Drama aside: Check out this site: http://meyerweb.com/eric/tools/dencoder/

Open up your SharePoint list whose GUID you want to retrieve

Right click on new item and  select properties
Right click on new item and select properties

Copy the entire URL from the properties and plug that into dencoder site > Decode and Voila!

{98B0A0E6-8CEE-4D49-B2D5-712750BC926C} cool eh!

So, yeah… a section of my script with GUID in it.

$(document).ready(function(){
alert(“document ready”);
var count=1;
var statusArray=[]; var valuesarray=[]; var countByStatus=[];
$().SPServices({
operation:”GetListItems”,
async:false,
listName:”{98B0A0E6-8CEE-4D49-B2D5-712750BC926C}“,
CAMLViewFields:””,
CAMLQuery: “”,
completefunc:processData
});

What to do with that you ask? Check it out @SPS_Events  I say.

-Swetha


Discover more from QubitSage Chronicles

Subscribe to get the latest posts sent to your email.

2 thoughts on “List GUID?! When in doubt, you DECODE!

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.