none
Can I change Type of Default SharePoint Columns?

    Question

  • My question is Simple. I want to Change Type of SharePoint Default Column like Title. I want to Change its type from Singe Line of Text to Look Up. Is it Possible?

    Ritesh Goswami


    • Edited by Ritesh Goswami Tuesday, January 01, 2013 5:45 AM Additional Fields
    Tuesday, January 01, 2013 5:44 AM

Answers

  • Can you Please try this code, Its a power shell script...

    $site = Get-SPSite -Identity "http://serverName/"
    $web = $site.RootWeb
    $field=$web.Fields["Title"]
    $field.Type= "Choice"
    $field.Update($true)
    $web.Dispose()
    $site.Dispose()

    It will make Title Column to be choice type and you can update it as your need.


    -Amar Trivedi

    • Marked as answer by Ritesh Goswami Tuesday, January 01, 2013 6:58 AM
    Tuesday, January 01, 2013 6:58 AM
  •    SPSite site = properties.Feature.Parent as SPSite;
                SPWeb web = site.RootWeb;
                SPField field = web.Fields["Title"];
                field.Type = SPFieldType.Choice;
                field.Update();
    This Code Just Solved My Problem.
    • Marked as answer by Ritesh Goswami Tuesday, January 01, 2013 7:17 AM
    • Edited by Ritesh Goswami Tuesday, January 01, 2013 7:26 AM Change in Grammer
    Tuesday, January 01, 2013 7:16 AM

All replies

  • Can you Please try this code, Its a power shell script...

    $site = Get-SPSite -Identity "http://serverName/"
    $web = $site.RootWeb
    $field=$web.Fields["Title"]
    $field.Type= "Choice"
    $field.Update($true)
    $web.Dispose()
    $site.Dispose()

    It will make Title Column to be choice type and you can update it as your need.


    -Amar Trivedi

    • Marked as answer by Ritesh Goswami Tuesday, January 01, 2013 6:58 AM
    Tuesday, January 01, 2013 6:58 AM
  •    SPSite site = properties.Feature.Parent as SPSite;
                SPWeb web = site.RootWeb;
                SPField field = web.Fields["Title"];
                field.Type = SPFieldType.Choice;
                field.Update();
    This Code Just Solved My Problem.
    • Marked as answer by Ritesh Goswami Tuesday, January 01, 2013 7:17 AM
    • Edited by Ritesh Goswami Tuesday, January 01, 2013 7:26 AM Change in Grammer
    Tuesday, January 01, 2013 7:16 AM
  • Thanx Amar,

    It just Solved my Problem.


    Ritesh Goswami

    Tuesday, January 01, 2013 7:17 AM