Stump the Panel Topic: Visual Status Field http://www.endusersharepoint.com/STP/ SharePoint QA en Mon, 13 Jul 2009 01:53:11 +0000 david m on "Visual Status Field" http://www.endusersharepoint.com/STP/topic/visual-status-field#post-8247 Wed, 08 Jul 2009 10:02:24 +0000 david m 8247@http://www.endusersharepoint.com/STP/ <p>Hello Eric,</p> <p>I THINK I GOT IT!!!</p> <p>Couldn't have done it without you.</p> <p>Thank you so much.</p> <p>Dave M </p> david m on "Visual Status Field" http://www.endusersharepoint.com/STP/topic/visual-status-field#post-8245 Wed, 08 Jul 2009 09:50:38 +0000 david m 8245@http://www.endusersharepoint.com/STP/ <p>Hi Eric,</p> <p>Again, thanks for the reply - its great working with you. I applied the script you sent and am still getting text only. </p> <p>Is this script for: "How to Convert HTML text to Graph in SharePoint Calculated Column"?</p> <p>Thanks</p> <p>Dave M </p> eric on "Visual Status Field" http://www.endusersharepoint.com/STP/topic/visual-status-field#post-8241 Wed, 08 Jul 2009 08:32:30 +0000 eric 8241@http://www.endusersharepoint.com/STP/ <p>That script doesn't look anything like the text2html script I have. I've looked at my implementation and have the following:</p> <p>&lt;script type="text/javascript"&gt;<br /> //make a fn for reuse<br /> $.calcHTML = function() {<br /> //loop through TDs moving text node to html<br /> $("td.ms-vb2,td[id$='Calculated'],td.ms-stylebody,td.ms-formbody").filter(":contains(&lt;DIV)").each(function(){<br /> $(this).html($(this).text());<br /> });<br /> };<br /> //call calcHTML on DOM ready for ungrouped rows<br /> $(function() {<br /> $.calcHTML();<br /> if (showpreview1) { //check for preview script<br /> $("td.ms-vb-title").bind("mouseover", function(){<br /> showpreview1(this);<br /> $.calcHTML();<br /> });<br /> }<br /> });<br /> //replace ExpGroupRenderData, call calcHTML for grouped rows<br /> function ExpGroupRenderData(htmlToRender, groupName, isLoaded) {<br /> $("#tbod"+groupName+"_").attr("isloaded",isLoaded).html(htmlToRender).show("fast",$.calcHTML());<br /> }<br /> &lt;/script&gt; </p> david m on "Visual Status Field" http://www.endusersharepoint.com/STP/topic/visual-status-field#post-8240 Wed, 08 Jul 2009 07:30:28 +0000 david m 8240@http://www.endusersharepoint.com/STP/ <p>Hello Eric,<br /> I'm going to take you up on your offer. And Thank You.<br /> I've got the "visual Status" column up ( as above).<br /> I've loaded up the following script in the CEWP source Editor:</p> <p>&lt;script type=”text/javascript”&gt;<br /> //ORIGINAL CONCEPT, CHRISTOPHE HUMBERT<br /> //<br /> // Convert HTML text to Graph in SharePoint Calculated Column<br /> // Author: Christophe Humbert<br /> // Site: <a href="http://pathtosharepoint.wordpress.com/" rel="nofollow">http://pathtosharepoint.wordpress.com/</a><br /> // Feedback and questions: <a href="mailto:[email protected]">[email protected]</a><br /> //<br /> var theTDs = document.getElementsByTagName(“TD”);<br /> var 1=0;<br /> var TDContent = “ “;<br /> while (1 &lt; the TDs.length)<br /> {<br /> try<br /> {<br /> TDcontent = the TDs [1] . innerText | | the TDs [1] . textContent;<br /> if ((TDContent.indexOf(“&lt;DIV”) == 0) &#38;&#38; (TDcontent.indexOf<br /> (“&lt;/DIV&gt;”) &gt;= 0)) {<br /> theTDs [1] . innerHTML = TDContent;<br /> }<br /> }<br /> catch (err) { }<br /> 1=1+1;<br /> }<br /> &lt;/script&gt;</p> <p>&lt;script type=”text/javascript”&gt;<br /> // TURN OFF FILTERING – PAUL GRENIER<br /> //<br /> // Turn Off Filtering Capabilities in Specific Columns<br /> // Author: Paul Grenier, AutoSponge, Administrator: Stump the Panel<br /> // Site: <a href="http://autosponge.spaces.live.com/default.aspx" rel="nofollow">http://autosponge.spaces.live.com/default.aspx</a><br /> // Feedback and questions:<br /> <a href="http://www.endusersharepoint.com/STP/topic.php?id=345&#38;page=2" rel="nofollow">http://www.endusersharepoint.com/STP/topic.php?id=345&#38;page=2</a><br /> //<br /> _spBodyOnLoadFunctionNames.push(“filterOff”);</p> <p>function filterOff ( ) {<br /> var a = [‘Visual Status’ , ‘High Priority’];<br /> var tags = document.getElementsByTagName(“TABLE”) ;<br /> for (var 1=0; 1 &lt; tags.length; 1++) {<br /> if (tags [1] . textContent) {<br /> var name = tags [1] . textContent;<br /> }else{<br /> var name = tags[1] . innerText; //for IE<br /> }<br /> if (name in oc(a)){<br /> tags[1] .setAttribute(“Filterable”,”FALSE”);<br /> }<br /> }<br /> }<br /> function oc(a)<br /> {<br /> var o = {};<br /> for(var 1=0;1&lt;a.length;1++)<br /> {<br /> o[a[1]]=’’;<br /> }<br /> return o;<br /> }<br /> &lt;/script&gt;</p> <p>and I'm showing text on my list still (no graph). </p> <p>If possible, can you take a moment to see if my script is correct or is there something else I need to add?</p> <p>Thank You so much.</p> <p>dave m. </p> eric on "Visual Status Field" http://www.endusersharepoint.com/STP/topic/visual-status-field#post-8231 Tue, 07 Jul 2009 16:45:12 +0000 eric 8231@http://www.endusersharepoint.com/STP/ <p>Not a problem, I've deployed the solution so I can assist if needed. </p> david m on "Visual Status Field" http://www.endusersharepoint.com/STP/topic/visual-status-field#post-8229 Tue, 07 Jul 2009 16:19:09 +0000 david m 8229@http://www.endusersharepoint.com/STP/ <p>Hello Eric,</p> <p>That Worked! -- Thank You so much. Now I can work on the CEWP script.</p> <p>Hopefully that will go with no problems. If not I hope you don't mind if I ask for your assistance again.</p> <p>Very Best Regards</p> <p>David </p> eric on "Visual Status Field" http://www.endusersharepoint.com/STP/topic/visual-status-field#post-8222 Tue, 07 Jul 2009 15:42:59 +0000 eric 8222@http://www.endusersharepoint.com/STP/ <p>Whoops, try removing the = after the opening parenthisis. Sorry about that.</p> <p>=CONCATENATE("&lt;DIV Style='background-color:#CC0000;'&gt;&lt;DIV style='background-color:#333333; width:",([% Complete]*100), "%;'&gt; &lt;/DIV&gt;&lt;/DIV&gt;") </p> david m on "Visual Status Field" http://www.endusersharepoint.com/STP/topic/visual-status-field#post-8220 Tue, 07 Jul 2009 15:35:39 +0000 david m 8220@http://www.endusersharepoint.com/STP/ <p>Thank you for the reply Eric. I tried your solution and got: "The formula contains a syntax error or is not supported."</p> <p>Can you offer a plan "B" that I might try?</p> <p>Thanks again. </p> eric on "Visual Status Field" http://www.endusersharepoint.com/STP/topic/visual-status-field#post-8154 Thu, 02 Jul 2009 15:20:39 +0000 eric 8154@http://www.endusersharepoint.com/STP/ <p>See if this does it for you:<br /> =CONCATENATE(="&lt;DIV Style='background-color:#CC0000;'&gt;&lt;DIV style='background-color:#333333; width:",([% Complete]*100), "%;'&gt; &lt;/DIV&gt;&lt;/DIV&gt;") </p> DWM on "Visual Status Field" http://www.endusersharepoint.com/STP/topic/visual-status-field#post-8147 Thu, 02 Jul 2009 12:18:17 +0000 DWM 8147@http://www.endusersharepoint.com/STP/ <p>I've duplicated the script for the calculated field called "Visual Status" that was shown on the 6/29 Dashboard Indicator ScreenCast. I keep getting a sytax error -- Can you possibly tell me where I'm wrong on this?</p> <p>=”&lt;DIV Style=’background-color:#CC0000;’&gt;&lt;DIV style=’background-color:#333333;<br /> width:”&#38;([% Complete]*100) &#38; “%;’&gt; &lt;/DIV&gt;&lt;/DIV&gt;” </p> <p>I have the " % Complete" field already added as well.</p> <p>Thanks in advance for your time and assistance. </p>