Loading...

RE: List Settings for qListView

RE: List Settings for qListView

#6130
Anonymous
Anonymous
Participant

the problem is that with the oob wp hidden – once a newbie hits this page (when compared to other pages) – they have to click on browse to make the list tools "appear".  I think that is the concern/question.  I tried to add something in script to enable the list tools w/out clicking browse – but it didn't work either – just wondering if anyone has discovered a different method.  Here is what I tried in a CEWP

method 1:

<script>
//Set focus on our list web part make sure the WPQ# is correct
var webPart = document.getElementById('WebPartWPQ1');
WpClick({target: webPart});

//Prevent it from losing focus
SP.Ribbon.WebPartComponent.$3_1.deselectWebPartAndZone = function() { };
</script>

method 2:

<script>
//make sure the WPQ# is correct

setTimeout(function() {
    var elem = document.getElementById("MSOZoneCell_WebPartWPQ2");
    if(elem != null) {
        var dummyevent = new Array();
        dummyevent["target"] = elem;
        dummyevent["srcElement"] = elem;
        WpClick(dummyevent);
    }
}, 2000);
</script>