Problem: When opening a Form you get a message like this "A form template (.xsn) file can not be accessed. You may not have the required permissions to open the file."
Resolution: Can be permissions of course ... Otherwise can be a missing template.
If you deleted the template you have to restore or republish in order to open the Form.
;))
Monday, August 22, 2011
Wednesday, August 3, 2011
Remove column title ContentType
Problem : If you add one contentType to a list, Title column is automatically added.
If you need to remove only the column Title, you can't cause remove button is hidden.
Solution:
Run a simple power shell script.
$web = Get-SPWeb http://server
$list = $web.Lists["Lib"]
$f= $list.Fields["Title"]
$ct =$list.ContentTypes["New Folder"]
$ct.FieldLinks.Delete($f.InternalName)
$ct.Update()
Now you have a contentType without Title column ;))
If you need to remove only the column Title, you can't cause remove button is hidden.
Solution:
Run a simple power shell script.
$web = Get-SPWeb http://server
$list = $web.Lists["Lib"]
$f= $list.Fields["Title"]
$ct =$list.ContentTypes["New Folder"]
$ct.FieldLinks.Delete($f.InternalName)
$ct.Update()
Now you have a contentType without Title column ;))
Labels:
Column,
content type,
Sharepoint,
Sharepoint 2010
Monday, August 1, 2011
Como eliminar a coluna de site imagem da página ou imagem de rollup ou imagem de contacto
Problema: Quando a queremos eliminar a coluna de site imagem da página ou imagem de rollup ou imagem de contacto, não aparece o botão.
Resolução: Apenas é possível mostrar o botão eliminar com execução de código.
PowerShell:
$web = Get-SPWeb http://server
$list = $web.Lists["Documentos"]
$field = $list.Fields["Page Image"] ou
$field = $list.Fields["Rollup image"] ou
$field = $list.Fields["Contact image"]
$field.AllowDeletion = “true”
$field.Update()
Ou pelo Visual Studio:
using(SPSite site = new SPSite("http://server"))
{
using(SPWeb web = site.OpenWeb())
{
SPList list = web.Lists.TryGetList("Documentos");
SPField field = list.Fields["Page Image"];
SPField field2 = list.Fields["Rollup image"];
SPField field3 = list.Fields["Contact image"];
field.AllowDeletion = true;
field.Update();
}
}
Agora o botão eliminar já aparece nas opções da coluna ;)
Resolução: Apenas é possível mostrar o botão eliminar com execução de código.
PowerShell:
$web = Get-SPWeb http://server
$list = $web.Lists["Documentos"]
$field = $list.Fields["Page Image"] ou
$field = $list.Fields["Rollup image"] ou
$field = $list.Fields["Contact image"]
$field.AllowDeletion = “true”
$field.Update()
Ou pelo Visual Studio:
using(SPSite site = new SPSite("http://server"))
{
using(SPWeb web = site.OpenWeb())
{
SPList list = web.Lists.TryGetList("Documentos");
SPField field = list.Fields["Page Image"];
SPField field2 = list.Fields["Rollup image"];
SPField field3 = list.Fields["Contact image"];
field.AllowDeletion = true;
field.Update();
}
}
Agora o botão eliminar já aparece nas opções da coluna ;)
Labels:
Coluna,
PowerShell,
programmatically,
Sharepoint 2010,
Visual Studio
Não é possível eliminar a coluna porque esta faz actualmente parte de um índice de coluna composto.
Problema deve ao facto de esta coluna está a ser usada para indexar conteúdo.
Assim sendo está terá que ser removida do índice e só depois poderá ser eliminada.
1- Ir as definições da biblioteca
2- Selecionar Colunas com índice.
3- Remover todas as opções que contenha a coluna em questão.
4- Eliminar/Delete a coluna.
Assim sendo está terá que ser removida do índice e só depois poderá ser eliminada.
1- Ir as definições da biblioteca
2- Selecionar Colunas com índice.
3- Remover todas as opções que contenha a coluna em questão.
4- Eliminar/Delete a coluna.
Labels:
Coluna,
Erros,
Sharepoint 2010
Thursday, July 21, 2011
An error occurred while trying to fetch data from your SharePoint site. Unexpected response from the server. The content type of the response is ''
Problema: Ao abrir Windows SharePoint Designer 2007/2010, aparece o seguinte erro:
An error occurred while trying to fetch data from your SharePoint site. Unexpected response from the server. The content type of the response is "". The status code is "OK"
Solução: Extend your web application Central Administration -> Application Management -> Manage Web Applications -> Select and click Extentd
An error occurred while trying to fetch data from your SharePoint site. Unexpected response from the server. The content type of the response is "". The status code is "OK"
Solução: Extend your web application Central Administration -> Application Management -> Manage Web Applications -> Select and click Extentd
Labels:
Erros,
Sharepoint 2010,
Sharepoint Designer
Saturday, July 16, 2011
Internal Name of Column Type / Tipo
Humm Levei uns bons minutos para encontrar o nome interno da Coluna Tipo/Type...
Vou partilhar para poupar tempo aos próximos.
Internal Name of Column Type is "DocIcon".
Utilizei para esconder essa mesma coluna.
view.ViewFields.Delete("DocIcon");
Vou partilhar para poupar tempo aos próximos.
Internal Name of Column Type is "DocIcon".
Utilizei para esconder essa mesma coluna.
view.ViewFields.Delete("DocIcon");
Labels:
Internal Name,
programmatically,
Sharepoint,
Sharepoint 2010
DefaultView.ViewFields not working
Comando DefaultView.ViewFields não funciona se usado dessa forma.
Exemplos:
list.DefaultView.ViewFields.Delete("something"); or
list.DefaultView.ViewFields.Add("something");
É necessário a criação de uma variável para o DefaultView!!!
SPView view = list.DefaultView;
view.ViewFields.Delete("something");
view.Update();
;)
Exemplos:
list.DefaultView.ViewFields.Delete("something"); or
list.DefaultView.ViewFields.Add("something");
É necessário a criação de uma variável para o DefaultView!!!
SPView view = list.DefaultView;
view.ViewFields.Delete("something");
view.Update();
;)
Labels:
programmatically,
Sharepoint,
Sharepoint 2010,
Views,
Visual Studio
Subscribe to:
Posts (Atom)