open vlookup link in new tab with different view?

Home Forums vLooup for SharePoint open vlookup link in new tab with different view?

Tagged: 

Viewing 1 reply thread
  • Author
    Posts
    • #14501
      Jeff Lynch
      Participant

        I am using a discussion list as the vLookup for Products. When a client clicks the edit or view button they get the OOTB list view. When you go to the discussion board and open it, there is a different page called /flat.aspx that is opened and it displays a more traditional discussion format.

        Can we launch that view from in the vLookup?

      • #14543
        Alexander Bautz
        Keymaster

          Hi,
          Sorry for the delay – I get a lot of questions and sometimes fall a bit behind. You should remove the “view” and “edit” buttons from vLookup and add a custom link like this:

          Add the field “FileDirRef” to the ViewFields section in vLookup, and add this to the “Special configuration”:

          {"function":"buildLinkToFlatView"}

          Then add this to the Custom JS:

          function buildLinkToFlatView(a,b){
              return "<a href='"+a+"/flat.aspx?RootFolder="+a+"/"+b.get_item("Title")+"' target='_blank'>Link</a>";
          }

          See attached images.

          Let me know how this works out.

          Alexander

      Viewing 1 reply thread
      • You must be logged in to reply to this topic.