none
How to get column name "Name (linked to document with edit menu)" in the Form Library columns along with other system columns like Created or Modified?

    Question

  • We are OOB Shop.

    I would like to create a calculated column in the Form library with condition: If Fiscal Year is 2015-2016 then use "<label for="ShouldDisplayLinkFilename">Name (linked to document with edit menu)" else use "Reference Name Link" column.</label>

    However, I am unable to see the column titled "<label for="ShouldDisplayLinkFilename">Name (linked to document with edit menu)"</label> in my calculated column options. If I could possible bring this column with the other columns in the library, perhaps then I can see it and use it in my calculated column formula.

    Thanks.<label for="ShouldDisplayLinkFilename"></label>


    SRAEngineer

    Friday, March 03, 2017 6:58 PM

Answers

  • Hi SRAEngineer,

    We cannot use a hyperlink field in the calculated formula.

    As a workaround, create a SharePoint Designer Workflow, and make it start when the item is created and modified.

    Using the workflow, we can add condition to check if the “FiscalYear” equals “2015-2016”. Then update the field (such as a hyperlink filed) based on the condition result.

    Best Regards,

    Linda Zhang


    Please remember to mark the replies as answers if they help.
    If you have feedback for TechNet Subscriber Support, contact tnmff@microsoft.com

    Friday, March 10, 2017 1:29 AM
    Moderator

All replies

  • Hi,

    Please check this following

    https://social.technet.microsoft.com/Forums/office/en-US/04cbc391-2e2b-4dd6-b7e2-f733a549f50c/make-a-custom-column-linked-to-document-with-edit-menu-other-than-name-column-which-is-default-in?forum=sharepointsearchprevious


    Please remember to click Mark as Answer on the answer if it helps you

    Friday, March 03, 2017 8:08 PM
  • Thank you!

    However, I am a newbie and we are an OOB shop. But, little XML tweaking could work. I am unclear of things mentioned in the post you are referring to, though. A Data View – means what? Where – in SP Designer? Is this a URL, a view or a column update?

    Can I know the steps to do this suggested change?

    ahref="/sites/MySite/_layouts/FormServer.aspx?XmlLocation={@FileRef.urlencodeasurl}&amp;OpenIn=browser"><xsl:value-of select="@MyColumn"/></a>

    Thanks!


    SRAEngineer

    Friday, March 03, 2017 9:15 PM
  • Hi SRAEngineer,

    The internal name of “Name (linked to document with edit menu)” is “LinkFilename”. We cannot use this column in the Calculated column.

    As a workaround, we can combine text and render it as a hyperlink in the Calculated column.

    If Fiscal Year is 2015-2016, display the link:

    "<a href='/sites/team/form/"&[Title]&"'>"&[Title]&"</a>"


    Else, only display "Reference Name Link" column.

    For example:

    =IF([Field 1]="123","<a href='/sites/team/form/"&[Title]&"'>"&[Title]&"</a>",[Reference Name Link])

    Then return value in Number, Currency or Date and Time formula.


    Note: Please change the “href” value in the formula to the URL of you form library.

    Information about rendering hyperlinks in Calculated column. It also fits in SharePoint 2013.

    https://devdotnotes.wordpress.com/2012/01/29/sharepoint-caculated-column-and-hyperlink-no-workflow-or-script-needed/

    To learn more about Calculated column formulas, read the article below:

    https://msdn.microsoft.com/en-us/library/office/bb862071%28v=office.14%29.aspx?f=255&MSPPError=-2147217396

    Best regards,

    Linda Zhang


    Please remember to mark the replies as answers if they help.
    If you have feedback for TechNet Subscriber Support, contact tnmff@microsoft.com

    Tuesday, March 07, 2017 9:35 AM
    Moderator
  • Hi Linda:

    Thank you for the detailed explanation. However, my Reference Name Link column (in my case it is named as "AppNameLink1516") is with Hyperlink data type and I am unable to see it when I create a calculated column titled "NameLink" per your suggestion with output as Number. Any workaround for that? If I typed in the name in the formula instead of selecting from the list, the formula gives me an error.

    My formula for my calculated column titled "NameLink" is:

    IF([FiscalYear]="2015-2016",[AppNameLink1516],("<a href='https://collab.pde.pa.gov/CCCB/CapApp"&[Title]&"'>"&[Title]&"</a>"))


    SRAEngineer

    Wednesday, March 08, 2017 4:14 PM
  • Hi SRAEngineer,

    You should not use parentheses “()” for the link in the formula.

    Please use the following formula:

    IF([FiscalYear]="2015-2016",[AppNameLink1516],"<a href='https://collab.pde.pa.gov/CCCB/CapApp"&[Title]&"'>"&[Title]&"</a>")


    Learn more about Calculated column formulas.

    Best Regards,

    Linda Zhang


    Please remember to mark the replies as answers if they help.
    If you have feedback for TechNet Subscriber Support, contact tnmff@microsoft.com

    Thursday, March 09, 2017 1:35 AM
    Moderator
  • Thank you for that correction Linda!

    IF([FiscalYear]="2015-2016",[AppNameLink1516],"<ahref='https://collab.pde.pa.gov/CCCB/CapApp"&[Title]&"'>"&[Title]&"</a>")

    I updated my formula as above and the system still gives me an error. I feel that, that is because I am unable to see the Hyperlink Column AppNameLink1516 and I believe when I type it in, it does not resolve because of its data type being Hyperlink and that is what gives me an error as stated below.

    Sorry, something went wrong

    One or more column references are not allowed, because the columns are defined as a data type that is not supported in formulas.

    Troubleshoot issues with Microsoft SharePoint Foundation.

    Correlation ID: 8a56dc9d-89ca-10c4-3d4a-a89ef6c72226

    Date and Time: 3/9/2017 8:22:07 AM

    I am not sure how to avoid that data type? Unless I copy that as a text, then use it in the calculated formula and somehow figure out that the resulting text when clicked it dynamically becomes a hyperlink. If not, it seems that there is no way in OOB environment, one can use a calculated formula for selecting between the two hyperlinks columns...

    I did learn a lot and I thank you for your support.

    SRA


    SRAEngineer

    Thursday, March 09, 2017 1:37 PM
  • Hi SRAEngineer,

    We cannot use a hyperlink field in the calculated formula.

    As a workaround, create a SharePoint Designer Workflow, and make it start when the item is created and modified.

    Using the workflow, we can add condition to check if the “FiscalYear” equals “2015-2016”. Then update the field (such as a hyperlink filed) based on the condition result.

    Best Regards,

    Linda Zhang


    Please remember to mark the replies as answers if they help.
    If you have feedback for TechNet Subscriber Support, contact tnmff@microsoft.com

    Friday, March 10, 2017 1:29 AM
    Moderator
  • Thank you Linda!

    This solutiuon will work...

    Regards,

    Wednesday, March 15, 2017 4:21 PM
  • Hi SRAEngineer,

    If you think my reply is helpful, you can mark it as answer. It will help others.

    Best regards,

    Linda Zhang


    Please remember to mark the replies as answers if they help.
    If you have feedback for TechNet Subscriber Support, contact tnmff@microsoft.com

    Thursday, March 16, 2017 1:22 AM
    Moderator
  • Hi Linda:

    Since your solution was already marked as answer by Victoria Xia (Moderator), the option to mark it as answer is not available to me!

    See above: "Proposed as answer by                             Victoria Xia<abbr class="affil">Microsoft contingent staff, Moderator</abbr>                         Monday, March 13, 2017 11:26 AM"

    Regardless, I thank you for your support!

    Thursday, March 16, 2017 12:21 PM
  • Hi SRAEngineer,

    You are using another user account (SRA Engineer) that is not the thread owner (SRAEngineer).

    Only the thread owner and the users have permissions can mark the reply as an answer. Please switch back to the original user account (thread owner "SRAEngineer") and then the “Mark as answer” option displays under each reply.


    Best regards,

    Linda Zhang


    Please remember to mark the replies as answers if they help.
    If you have feedback for TechNet Subscriber Support, contact tnmff@microsoft.com

    Friday, March 17, 2017 1:09 AM
    Moderator
  • Thank you for that clarification. how can I merge both the accounts SRAEngineer and SRA Engineer? Both are mine and inadvertently opened the second one by accident.  Can you help?

    Thank you.


    SRAEngineer

    Friday, March 17, 2017 11:57 AM
  • Hi SRAEngineer,

    As the issue is related to accounts, not for SharePoint product, I suggest you contact support on the following site.

    https://support.microsoft.com/en-us/products/microsoft-account

    You will get more expert assistance with your issue.

    Thanks for your understanding.

    Best regards,

    Linda Zhang


    Please remember to mark the replies as answers if they help.
    If you have feedback for TechNet Subscriber Support, contact tnmff@microsoft.com

    Monday, March 20, 2017 12:57 PM
    Moderator