3

I have a web part in which I am displaying the item title as a link. I want user to redirect to the custom view which displays only that product information. I need to pass the query string parameter when user clicks on the link.

My code for view is:

<View BaseViewID="2" Type="HTML" WebPartZoneID="Main" DisplayName="$Resources:OPLBIntranet,procedureViewDisplayName;" MobileView="TRUE" SetupPath="pages\viewpage.aspx" ImageUrl="/_layouts/15/images/generic.png?rev=23" Url="procedures.aspx">
    <Toolbar Type="Standard" />
    <XslLink Default="TRUE">main.xsl</XslLink>
    <JSLink>clienttemplates.js</JSLink>
    <RowLimit Paged="TRUE">30</RowLimit>
    <ViewFields>
      <FieldRef Name="LinkTitle"></FieldRef>
      <FieldRef Name="oiplbDepartment"/>
      <FieldRef Name="oiplbQmsDocApprover1"/>
      <FieldRef Name="oiplbQmsDocApprover2"/>
    </ViewFields>
    <Query>
      <OrderBy>
        <FieldRef Name="ID"></FieldRef>
      </OrderBy>
    </Query>
    <ParameterBindings>
      <ParameterBinding Name="NoAnnouncements" Location="Resource(wss,noXinviewofY_LIST)" />
      <ParameterBinding Name="NoAnnouncementsHowTo" Location="Resource(wss,noXinviewofY_DEFAULT)" />
    </ParameterBindings>
</View>

I copied the view from the allitems.aspx view in List's schema file but I donot have much idea about how to bind parameters and configure the query based on parameter.

How do I configure the query and bind parameter?

1

You can add a Query String (URL) web part to the page, then configure the web part by choosing Edit -> Connections -> Send filter values to ...

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.