not want a column to be updated
I have a column in my SharePoint List which I want not to be updated by users, Is there any way i can do that
Respuestas
Hi, Ashish
You can also create new Editform using SPD, and change SharePoint:FormField ControlMode property from “edit” to "Display”.
For creating a custom list form with SPD , please refer to:http://office.microsoft.com/en-us/sharepointdesigner/HA101191111033.aspx
Or you can simply use JavaScript to hide this field control or set it “read-only” in Editform.aspx.
Here is also a resolved thread similar to your problem, hope this can help.
o Best Regards
-Aaron- Marcado como respuestaAaron Han - MSFTModeradorviernes, 04 de diciembre de 2009 2:22
Todas las respuestas
- In Field definition you can put ShowInEditForm="FALSE" or ReadOnly="TRUE" - depends on your case
- But I guess that will make all the columns non-editable... I want just only one column not to be updated not all...
Is there a way I can put "READONLY="TRUE" for individual column
I appreciate your Reply - I'm talking you about individual column:
<Field ID="{1D802171-8293-4d13-9939-682087427B53}" Name="Group" StaticName="Group" DisplayName="Group" Type="Text" ReadOnly="TRUE" Hidden="FALSE" Required="FALSE" Sealed="TRUE" DisplaceOnUpgrade="TRUE" SourceID="http://schemas.microsoft.com/sharepoint/v3" />
or
<Field ID="{1D802171-8293-4d13-9939-682087427B53}" Name="Group" StaticName="Group" DisplayName="Group" Type="Text" Hidden="FALSE" ShowInEditForm="FALSE" Required="FALSE" Sealed="TRUE" DisplaceOnUpgrade="TRUE" SourceID="http://schemas.microsoft.com/sharepoint/v3" />
from where I can open this field defination to edit.....
Hi, Ashish
You can also create new Editform using SPD, and change SharePoint:FormField ControlMode property from “edit” to "Display”.
For creating a custom list form with SPD , please refer to:http://office.microsoft.com/en-us/sharepointdesigner/HA101191111033.aspx
Or you can simply use JavaScript to hide this field control or set it “read-only” in Editform.aspx.
Here is also a resolved thread similar to your problem, hope this can help.
o Best Regards
-Aaron- Marcado como respuestaAaron Han - MSFTModeradorviernes, 04 de diciembre de 2009 2:22
- Hi Aaron,
Thanks for your reply it helped in my project. But what i want to know now is that in ur solution you are making the whole form non editable...so is there any way to only make few columns non editable?
Only through SP Designer.
I really need this solution please help.
Thanks in advance. Hi, Ashish
Please correct me if I miss something.
You can also create new Editform using SPD, and change SharePoint:FormField ControlMode property from “edit” to "Display”.For creating a custom list form with SPD , please refer to:http://office.microsoft.com/en-us/sharepointdesigner/HA101191111033.aspx
Or you can simply use JavaScript to hide this field control or set it “read-only” in Editform.aspx.
These solutions are using SP Designer and for one list only.Best Regards
-AaronDid you try event handler?
http://msdn.microsoft.com/en-us/library/microsoft.sharepoint.spitemeventreceiver.itemupdating.aspx
Juan Pablo.
surpoint.blogspot.com
geeks.ms/blogs/jpussacq
excelza.blogspot.com- Hi Aaron,
Ya the two ways you suggested are using Sharepoint Designer.
But the problem with the first one is that it makes the whole EditForm.aspx non editable not a specific column. So is there a way by which i can make a single column non editable.
And the problem with second one is that i can't find field control in EditForm.aspx? Can you please tell me the Java script code for this?
Thanks Aaron for the reply. - Hi Juan,
The problem is that i am not supposed to use Event Handlers for this.
The only way i am allowed is through SP Designer, so do u have any way to answer this?
Thanks in advance. - Chek this blog. It has some ideas to hide fields (SharePoint Branding Series 2). I think it can help you:
http://www.cleverworkarounds.com/
Juan Pablo.
surpoint.blogspot.com
geeks.ms/blogs/jpussacq
excelza.blogspot.com - Hi Juan,
Thank you so much. This is exactly i wanted. This link is the solution for my problem: http://www.cleverworkarounds.com/2008/02/07/more-sharepoint-branding-customisation-using-javascript-part-1/
BUT the problem is i dont know where to insert the code?
Where should i insert this code:
function getTagFromIdentifierAndTitle(tagName, identifier, title)
{
var len = identifier.length;
var tags = document.getElementsByTagName(tagName);
for (var i=0; i < tags.length; i++)
{
var tempString = tags[i].id;
if (tags[i].title == title && (identifier == "" || tempString.indexOf(identifier) == tempString.length - len))
{
return tags[i];
}
}
return null ;
}
All i can do is make changes to EditForm.aspx to get the output out. How should i proceed...
PLEASE HELP.
Thanks in advance. - You can insert the code in a Content Editor Web Part. Normally you use the button "Edit Page" to do that, but in a NewForm.aspx or EdidForm.aspx the botton does not exists. So use this trick:
Add this parameter to the url:
... /NewForm.aspx?toolpaneview=2
More info here:
http://translate.google.com/translate?client=tmpg&hl=es&u=http%3A%2F%2Fsurpoint.blogspot.com%2F2009%2F12%2Ftrucos-en-las-urls-de-sharepoint-parte.html&langpair=es|en
If you need more help, tell me please.
Bye.
Juan Pablo.
surpoint.blogspot.com
geeks.ms/blogs/jpussacq
excelza.blogspot.com