I want to hide 'Workspace' checkbox while creating new calendar event. How
can it be done?
I looked into following alternatives:
1. Site Content Type: Event - Workspace column is not selectable. There are
two other options that are not clickable too, I dont want to perform any
activity on those two.
Any help or help pointer will be appreciated.
Thanks
Atul
"Atul Shukla" <pya...@gmail.com> wrote in message
news:1EAE77D5-D02F-4E7A...@microsoft.com...
Why not give it here as well?
Some people use off-line newsgroup readers and this reply doesn't help
them at all.
Mike Walsh
WSS FAQ http://www.wssv3faq.com / http://wss.collutions.com
No private e-mail questions please
http://moblog-banditben.blogspot.com/2008/10/disabling-workspaces-from-sharepoint.html
Cheers,
Paul
http://www.directsharepoint.com/2011/05/hiding-workspace-checkbox-while.html
>> On Wednesday, November 05, 2008 3:35 PM Atul Shukla wrote:
>> I found the solution by myself, and published on to my blog at
>> http://atulsh.blogspot.com/
>>> On Friday, November 07, 2008 2:29 AM Mike Walsh wrote:
>>> > I found the solution by myself, and published on to my blog at
>>> > http://atulsh.blogspot.com/
>>>
>>> Why not give it here as well?
>>>
>>> Some people use off-line newsgroup readers and this reply doesn't help
>>> them at all.
>>>
>>> Mike Walsh
>>> WSS FAQ http://www.wssv3faq.com / http://wss.collutions.com
>>> No private e-mail questions please
>>>
>>> Atul Shukla wrote:
>>>> On Monday, November 10, 2008 12:42 PM Atul Shukla wrote:
>>>> This is a multi-part message in MIME format.
>>>>
>>>> ------=_NextPart_000_002B_01C94318.9E140CC0
>>>> Content-Type: text/plain;
>>>> charset="iso-8859-1"
>>>> Content-Transfer-Encoding: quoted-printable
>>>>
>>>> Hi Mike,
>>>>
>>>> I thought that the content (findings and solution) is huge and hence =
>>>> posted on the blog. Per your comments, posting the solution here:
>>>>
>>>> Somebody asked me about hiding a field called 'Workspace' from Calendar: =
>>>> New Event or Edit existing event.
>>>> I was wondering that there should be some decent way to hide any field =
>>>> available on 'New' or 'Edit' page.
>>>> I googled around, and I found couple of responses, forexample,
>>>> 1. Modifying the NewForm.aspx page in SharePoint Designer 2007, hiding =
>>>> existing List Form Web Part, and then adding Custom List Form. Then =
>>>> delete the Workspace row from the form.
>>>>
>>>> Let me talk about the dis-advantages of this option:
>>>> a. Attach File will NOT work. You need to investigate further to make it =
>>>> work. Still painful process.
>>>> b. Try to create a 'Recurring' event, it will not work as expected.
>>>>
>>>> Considering these advantages, I thought that this is very tedious =
>>>> process, and one has to make the changes to all calendar lists. And then =
>>>> this change is required to be done on NewForm.aspx and EditForm.aspx. =
>>>> How about that? So it is really very painful process.
>>>>
>>>> 2. Another option is again, modifying the NewForm.aspx or EditForm.aspx, =
>>>> and add following script (However, it didnt work for me though), but it =
>>>> is worth adding it here, just in case, if people are trying to solve the =
>>>> problemin this manner.
>>>> <script language=3D'javascript' type=3D'text/javascript' >
>>>> var toolbar =3D document.getElementByName("<name attribute value>"); =
>>>> toolbar.parentNode.parentNode.parentNode.style.display =3D 'none'; =
>>>> toolbar.parentNode.parentNode.style.display =3D 'none';
>>>> <script>
>>>>
>>>> This can be added in asp:content =
>>>> ContentPlaceHolderId=3D"PlaceHolderTitleAreaClass".
>>>> Once again as I said that it didnt work for me, but it can be done this =
>>>> way too.
>>>>
>>>> 3. Recommended way. First thing is that it is a feature, and can be =
>>>> found (12 Hive folder) at C:\Program Files\Common Files\Microsoft =
>>>> Shared\web server extensions\12\Template\Features\EventsList. Yes, it is =
>>>> event list feature. Now the modifications are required in schema.xml =
>>>> that can be found under Events folder (folder location, once again, is =
>>>> ..\12\TEMPLATE\FEATURES\EventsList\Events). This file can be modified in =
>>>> notepad.exe.
>>>> While looking into the Calendar List Settings in Internet Explorer, I =
>>>> noticed that this field 'Workspace' is of type 'Cross Project Link'. =
>>>> This is important to remember, and search 'CrossProjectLink' in =
>>>> schema.xml file. I noticed there is only one instance of it.
>>>> Secondly, the field is SharePoint field so looked for the corresponding =
>>>> class which is SPField. I looked into SPField Class Members on MSDN and =
>>>> found a couple of interesting properties (and used two of them), for =
>>>> example, ShowInDisplayForm, ShowInEditForm, ShowInListSettings, =
>>>> ShowInNewForm, ShowInVersionHistory, ShowInViewForms. I was interested =
>>>> in ShowInEditForm and ShowInNewForm properties only. So in schema.xml =
>>>> file, for Field of Type=3D"CrossProjectLink", added these two properties =
>>>> as attributes, and set the value=3D"FALSE".
>>>> IMPORTANT: attribute value should be set as ShowInNewForm=3D"FALSE" =
>>>> (case sensitive). If you set the value as ShowInNewForm=3D"false", it =
>>>> will not work, so be careful here.
>>>> My final <Field> is looked like:
>>>> <Field ID=3D"{08fc65f9-48eb-4e99-bd61-5946c439e691}" =
>>>> Type=3D"CrossProjectLink" Name=3D"WorkspaceLink" Format=3D"EventList" =
>>>> DisplayName=3D"$Resources:core,Workspace;" DisplayImage=3D"mtgicon.gif" =
>>>> HeaderImage=3D"mtgicnhd.gif" ClassInfo=3D"Icon" =
>>>> Title=3D"$Resources:core,Meeting_Workspace;" Filterable=3D"TRUE" =
>>>> Sealed=3D"TRUE" SourceID=3D"http://schemas.microsoft.com/sharepoint/v3" =
>>>> StaticName=3D"WorkspaceLink" ShowInEditForm=3D"FALSE" =
>>>> ShowInNewForm=3D"FALSE">
>>>> As mentioned, I added only two attributes.
>>>> Save the schema.xml file.
>>>>
>>>> Now the task is to publish the feature with changes. And since the =
>>>> feature is already installed and activated, so it is mandatory to =
>>>> de-activate it and then un-install it.
>>>>
>>>> To smoothen the process I wrote two batch files one each for =
>>>> de-activate, un-install and install, activate:
>>>> script for uninstallfeature.bat
>>>>
>>>> path=3D"C:\Program Files\Common Files\Microsoft Shared\web server =
>>>> extensions\12\BIN"
>>>> cd\
>>>> cd "C:\Program Files\Common Files\Microsoft Shared\web server =
>>>> extensions\12\BIN"
>>>> stsadm.exe -o deactivatefeature -filename EventsList\Feature.xml -url =
>>>> http://moss2007:8551/sites/Demo1
>>>> stsadm.exe -o uninstallfeature -filename EventsList\Feature.xml -force
>>>> cd\
>>>>
>>>> It is straight forward to understand, however, if you want instructions =
>>>> for the same, can send me request.
>>>>
>>>> script for installfeature.bat
>>>>
>>>> path=3D"C:\Program Files\Common Files\Microsoft Shared\web server =
>>>> extensions\12\BIN"
>>>> cd\
>>>> cd "C:\Program Files\Common Files\Microsoft Shared\web server =
>>>> extensions\12\BIN"
>>>> stsadm.exe -o installfeature -filename EventsList\Feature.xml
>>>> stsadm.exe -o activatefeature -filename EventsList\Feature.xml -url =
>>>> http://moss2007:8551/sites/demo1
>>>> cd\
>>>>
>>>> URL is required to install the feature, in this script, I am deploying =
>>>> the feature for a specific website.
>>>> Dont forget to do IISRESET
>>>>
>>>> I am done, and when I tried to create or edit a calendar event, I don't =
>>>> see 'Workspace' option in there. I double checked that attach file is =
>>>> working, and I am able to create a 'Recurring' event too.
>>>> It is really very useful tip for me, so thought let me add it here for =
>>>> future reference too.=20
>>>>
>>>> You can find the content at =
>>>> http://atulsh.blogspot.com/2008/11/calendar-new-event-hide-workspace-from=
>>>> .html
>>>>
>>>> Thanks
>>>> Atul
>>>>
>>>>
>>>> "Mike Walsh" <englant...@hotmail.com> wrote in message =
>>>> news:u5uBVqKQ...@TK2MSFTNGP04.phx.gbl...
>>>>
>>>> event.=20
>>>> to=20
>>>> ------=_NextPart_000_002B_01C94318.9E140CC0
>>>> Content-Type: text/html;
>>>> charset="iso-8859-1"
>>>> Content-Transfer-Encoding: quoted-printable
>>>>
>>>> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
>>>> <HTML><HEAD>
>>>> <META http-equiv=3DContent-Type content=3D"text/html; =
>>>> charset=3Diso-8859-1">
>>>> <META content=3D"MSHTML 6.00.6001.18148" name=3DGENERATOR>
>>>> <STYLE></STYLE>
>>>> </HEAD>
>>>> <BODY>
>>>> <DIV><FONT face=3DArial size=3D2>Hi Mike,</FONT></DIV>
>>>> <DIV><FONT face=3DArial size=3D2></FONT> </DIV>
>>>> <DIV><FONT face=3DArial size=3D2>I thought that the content (findings =
>>>> and solution)=20
>>>> is huge and hence posted on the blog. Per your comments, posting the =
>>>> solution=20
>>>> here:</FONT></DIV>
>>>> <DIV><FONT face=3DArial size=3D2></FONT> </DIV>
>>>> <DIV><SPAN style=3D"FONT-FAMILY: arial">Somebody asked me about hiding a =
>>>> field=20
>>>> called 'Workspace' from Calendar: New Event or Edit existing event.<BR>I =
>>>> was=20
>>>> wondering that there should be some decent way to hide any field =
>>>> available on=20
>>>> 'New' or 'Edit' page.<BR>I googled around, and I found couple of =
>>>> responses,=20
>>>> forexample,<BR>1. Modifying the NewForm.aspx page in SharePoint Designer =
>>>> 2007,=20
>>>> hiding existing List Form Web Part, and then adding Custom List Form. =
>>>> Then=20
>>>> delete the Workspace row from the form.<BR><BR>Let me talk about the=20
>>>> dis-advantages of this option:<BR><SPAN style=3D"COLOR: =
>>>> File will NOT work. You need to investigate further to make it work. =
>>>> Still=20
>>>> painful process.<BR><SPAN style=3D"COLOR: #ff6666">b.</SPAN> Try to =
>>>> create a=20
>>>> 'Recurring' event, it will not work as expected.<BR><BR>Considering =
>>>> these=20
>>>> advantages, I thought that this is very tedious process, and one has to =
>>>> make the=20
>>>> changes to all calendar lists. And then this change is required to be =
>>>> done on=20
>>>> NewForm.aspx and EditForm.aspx. How about that? So it is really very =
>>>> painful=20
>>>> process.<BR><BR>2. Another option is again, modifying the NewForm.aspx =
>>>> or=20
>>>> EditForm.aspx, and add following script (However, it didnt work for me =
>>>> though),=20
>>>> but it is worth adding it here, just in case, if people are trying to =
>>>> solve the=20
>>>> problemin this manner.<BR><script language=3D'javascript'=20
>>>> type=3D'text/javascript' ><BR>var toolbar =3D =
>>>> document.getElementByName("<name=20
>>>> attribute value><NAME>");=20
>>>> toolbar.parentNode.parentNode.parentNode.style.display =3D 'none';=20
>>>> toolbar.parentNode.parentNode.style.display =3D=20
>>>> 'none';<BR><script><BR><BR>This can be added in asp:content=20
>>>> ContentPlaceHolderId=3D"PlaceHolderTitleAreaClass".<BR>Once again as I =
>>>> said that=20
>>>> it didnt work for me, but it can be done this way too.<BR><BR><SPAN=20
>>>> style=3D"COLOR: #cc0000"><STRONG>3. Recommended way.</STRONG></SPAN> =
>>>> First thing=20
>>>> is that it is a feature, and can be found (12 Hive folder) at <SPAN=20
>>>> style=3D"COLOR: #990000">C:\Program Files\Common Files\Microsoft =
>>>> Shared\web server=20
>>>> extensions\12\Template\Features\EventsList</SPAN>. Yes, it is event list =
>>>>
>>>> feature. Now the modifications are required in schema.xml that can be =
>>>> found=20
>>>> under Events folder (folder location, once again, is=20
>>>> ..\12\TEMPLATE\FEATURES\EventsList\Events). This file can be modified in =
>>>>
>>>> notepad.exe.<BR>While looking into the Calendar List Settings in =
>>>> Internet=20
>>>> Explorer, I noticed that this field 'Workspace' is of type 'Cross =
>>>> Project Link'.=20
>>>> This is important to remember, and search 'CrossProjectLink' in =
>>>> schema.xml file.=20
>>>> I noticed there is only one instance of it.<BR>Secondly, the field is =
>>>> SharePoint=20
>>>> field so looked for the corresponding class which is SPField. I looked =
>>>> into=20
>>>> SPField Class Members on </SPAN><A=20
>>>> href=3D"http://msdn.microsoft.com/en-us/library/microsoft.sharepoint.spfi=
>>>> eld_members.aspx"><SPAN=20
>>>> style=3D"FONT-FAMILY: arial"><FONT =
>>>> color=3D#336688>MSDN</FONT></SPAN></A><SPAN=20
>>>> style=3D"FONT-FAMILY: arial"> and found a couple of interesting =
>>>> properties (and=20
>>>> used two of them), for example, <SPAN style=3D"COLOR: =
>>>> ShowInEditForm, ShowInListSettings, ShowInNewForm, ShowInVersionHistory, =
>>>>
>>>> ShowInViewForms</SPAN>. I was interested in ShowInEditForm and =
>>>> ShowInNewForm=20
>>>> properties only. So in schema.xml file, for Field of =
>>>> Type=3D"CrossProjectLink",=20
>>>> added these two properties as attributes, and set the =
>>>> value=3D"FALSE".<BR><SPAN=20
>>>> style=3D"COLOR: #ff0000">IMPORTANT:</SPAN> attribute value should be set =
>>>> as=20
>>>> ShowInNewForm=3D"FALSE" (case sensitive). If you set the value as=20
>>>> ShowInNewForm=3D"false", it will not work, so be careful here.<BR>My =
>>>> final=20
>>>> <Field> is looked like:<BR><Field=20
>>>> ID=3D"{08fc65f9-48eb-4e99-bd61-5946c439e691}" Type=3D"CrossProjectLink"=20
>>>> Name=3D"WorkspaceLink" Format=3D"EventList" =
>>>> DisplayName=3D"$Resources:core,Workspace;"=20
>>>> DisplayImage=3D"mtgicon.gif" HeaderImage=3D"mtgicnhd.gif" =
>>>> ClassInfo=3D"Icon"=20
>>>> Title=3D"$Resources:core,Meeting_Workspace;" Filterable=3D"TRUE" =
>>>> Sealed=3D"TRUE"=20
>>>> SourceID=3D"</SPAN><A =
>>>> href=3D"http://schemas.microsoft.com/sharepoint/v3"><SPAN=20
>>>> style=3D"FONT-FAMILY: arial"><FONT=20
>>>> color=3D#336688>http://schemas.microsoft.com/sharepoint/v3</FONT></SPAN><=
>>>> /A><SPAN=20
>>>> style=3D"FONT-FAMILY: arial">" StaticName=3D"WorkspaceLink" <SPAN=20
>>>> style=3D"COLOR: #ff6666">ShowInEditForm=3D"FALSE"=20
>>>> ShowInNewForm=3D"FALSE"</SPAN>><BR>As mentioned, I added only two=20
>>>> attributes.<BR><SPAN style=3D"COLOR: #cc0000"><STRONG>Save the =
>>>> schema.xml=20
>>>> file.</STRONG></SPAN><BR><BR>Now the task is to publish the feature with =
>>>>
>>>> changes. And since the feature is already installed and activated, so it =
>>>> is=20
>>>> mandatory to de-activate it and then un-install it.<BR><BR>To smoothen =
>>>> the=20
>>>> process I wrote two batch files one each for de-activate, un-install and =
>>>>
>>>> install, activate:<BR></SPAN><SPAN style=3D"FONT-FAMILY: =
>>>> arial"><STRONG>script for=20
>>>> <SPAN=20
>>>> style=3D"COLOR: =
>>>> Files\Common Files\Microsoft Shared\web server =
>>>> extensions\12\BIN"<BR>cd\<BR>cd=20
>>>> "C:\Program Files\Common Files\Microsoft Shared\web server=20
>>>> extensions\12\BIN"<BR>stsadm.exe -o deactivatefeature -filename=20
>>>> EventsList\Feature.xml -url </SPAN><A=20
>>>> href=3D"http://moss2007:8551/sites/Demo1"><SPAN style=3D"FONT-FAMILY: =
>>>> arial"><FONT=20
>>>> color=3D#336688>http://moss2007:8551/sites/Demo1</FONT></SPAN></A><SPAN=20
>>>> style=3D"FONT-FAMILY: arial"><BR>stsadm.exe -o uninstallfeature =
>>>> -filename=20
>>>> EventsList\Feature.xml -force<BR>cd\<BR><BR>It is straight forward to=20
>>>> understand, however, if you want instructions for the same, can send me=20
>>>> request.<BR><BR></SPAN><SPAN style=3D"FONT-FAMILY: arial"><STRONG>script =
>>>> for <SPAN=20
>>>> style=3D"COLOR: =
>>>> Files\Common Files\Microsoft Shared\web server =
>>>> extensions\12\BIN"<BR>cd\<BR>cd=20
>>>> "C:\Program Files\Common Files\Microsoft Shared\web server=20
>>>> extensions\12\BIN"<BR>stsadm.exe -o installfeature -filename=20
>>>> EventsList\Feature.xml<BR>stsadm.exe -o activatefeature -filename=20
>>>> EventsList\Feature.xml -url </SPAN><A=20
>>>> href=3D"http://moss2007:8551/sites/demo1"><SPAN style=3D"FONT-FAMILY: =
>>>> arial"><FONT=20
>>>> color=3D#336688>http://moss2007:8551/sites/demo1</FONT></SPAN></A><SPAN=20
>>>> style=3D"FONT-FAMILY: arial"><BR>cd\<BR><BR>URL is required to install =
>>>> the=20
>>>> feature, in this script, I am deploying the feature for a specific=20
>>>> website.<BR>Dont forget to do <SPAN=20
>>>> style=3D"COLOR: #ff0000">IISRESET</SPAN><BR><BR><STRONG>I am =
>>>> done</STRONG>, and=20
>>>> when I tried to create or edit a calendar event, I don't see 'Workspace' =
>>>> option=20
>>>> in there. I double checked that attach file is working, and I am able to =
>>>> create=20
>>>> a 'Recurring' event too.<BR>It is really very useful tip for me, so =
>>>> thought let=20
>>>> me add it here for future reference too. </SPAN></DIV>
>>>> <DIV><SPAN style=3D"FONT-FAMILY: arial"></SPAN> </DIV>
>>>> <DIV><SPAN style=3D"FONT-FAMILY: arial">You can find the content at <A=20
>>>> href=3D"http://atulsh.blogspot.com/2008/11/calendar-new-event-hide-worksp=
>>>> ace-from.html">http://atulsh.blogspot.com/2008/11/calendar-new-event-hide=
>>>> -workspace-from.html</A></SPAN></DIV>
>>>> <DIV><SPAN style=3D"FONT-FAMILY: arial"></SPAN> </DIV>
>>>> <DIV><SPAN style=3D"FONT-FAMILY: arial">Thanks</SPAN></DIV>
>>>> <DIV><SPAN style=3D"FONT-FAMILY: arial">Atul</SPAN></DIV>
>>>> <DIV><SPAN style=3D"FONT-FAMILY: arial"></SPAN> </DIV>
>>>> <DIV><FONT face=3DArial size=3D2></FONT> </DIV>
>>>> <DIV><FONT face=3DArial size=3D2>"Mike Walsh" <</FONT><A=20
>>>> href=3D"mailto:englant...@hotmail.com"><FONT face=3DArial=20
>>>> size=3D2>englant...@hotmail.com</FONT></A><FONT face=3DArial =
>>>> size=3D2>> wrote=20
>>>> in message </FONT><A =
>>>> href=3D"news:u5uBVqKQ...@TK2MSFTNGP04.phx.gbl"><FONT=20
>>>> face=3DArial =
>>>> size=3D2>news:u5uBVqKQ...@TK2MSFTNGP04.phx.gbl</FONT></A><FONT=20
>>>> face=3DArial size=3D2>...</FONT></DIV><FONT face=3DArial size=3D2>> =
>>>> > I found the=20
>>>> solution by myself, and published on to my blog at<BR>> > =
>>>> </FONT><A=20
>>>> href=3D"http://atulsh.blogspot.com/"><FONT face=3DArial=20
>>>> size=3D2>http://atulsh.blogspot.com/</FONT></A><BR><FONT face=3DArial =
>>>> size=3D2>>=20
>>>> <BR>> Why not give it here as well?<BR>> <BR>> Some people use =
>>>> off-line=20
>>>> newsgroup readers and this reply doesn't help <BR>> them at =
>>>> all.<BR>>=20
>>>> <BR>> Mike Walsh<BR>> WSS FAQ </FONT><A=20
>>>> href=3D"http://www.wssv3faq.com"><FONT face=3DArial=20
>>>> size=3D2>http://www.wssv3faq.com</FONT></A><FONT face=3DArial size=3D2> =
>>>> / </FONT><A=20
>>>> href=3D"http://wss.collutions.com"><FONT face=3DArial=20
>>>> size=3D2>http://wss.collutions.com</FONT></A><BR><FONT face=3DArial =
>>>> size=3D2>> No=20
>>>> private e-mail questions please<BR>> <BR>> Atul Shukla =
>>>> wrote:<BR>>>=20
>>>> I found the solution by myself, and published on to my blog =
>>>> at<BR>>>=20
>>>> </FONT><A href=3D"http://atulsh.blogspot.com/"><FONT face=3DArial=20
>>>> size=3D2>http://atulsh.blogspot.com/</FONT></A><BR><FONT face=3DArial=20
>>>> size=3D2>>> <BR>>> "Atul Shukla" <</FONT><A=20
>>>> href=3D"mailto:pya...@gmail.com"><FONT face=3DArial=20
>>>> size=3D2>pya...@gmail.com</FONT></A><FONT face=3DArial size=3D2>> =
>>>> wrote in message=20
>>>> <BR>>> </FONT><A=20
>>>> href=3D"news:1EAE77D5-D02F-4E7A...@microsoft.com"><FONT =
>>>> face=3DArial=20
>>>> size=3D2>news:1EAE77D5-D02F-4E7A...@microsoft.com</FONT></=
>>>> A><FONT=20
>>>> face=3DArial size=3D2>...<BR>>>> =
>>>> Hi,<BR>>>><BR>>>> I want=20
>>>> to hide 'Workspace' checkbox while creating new calendar event. =
>>>> <BR>>>>=20
>>>> How can it be done?<BR>>>><BR>>>> I looked into =
>>>> following=20
>>>> alternatives:<BR>>>> 1. Site Content Type: Event - Workspace =
>>>> column is=20
>>>> not selectable. <BR>>>> There are two other options that are =
>>>> not=20
>>>> clickable too, I dont want to <BR>>>> perform any activity on =
>>>> those=20
>>>> two.<BR>>>><BR>>>><BR>>>> Any help or help =
>>>> pointer=20
>>>> will be appreciated.<BR>>>><BR>>>> =
>>>> Thanks<BR>>>> Atul=20
>>>> <BR>>></FONT></BODY></HTML>
>>>>
>>>> ------=_NextPart_000_002B_01C94318.9E140CC0--