locked
MVC query string RRS feed

  • Question

  • Firstly, sorry if this is in the wrong spot, but I don't understand the new forum setup at all.

    What I've got is a MVC page that lists a bunch of things, let's say orders.  The page can be filtered by customer or item.  You can also click a link to create a new order.  What I want to do is pass the query string from the index to the create (if it is present).

    I thought I could do this

        @Html.ActionLink("Create New", "Create", "Orders", Context.Request.QueryString)
    
    But the query string gets encoded so will not work.
    • Moved by CoolDadTx Friday, November 13, 2020 2:31 PM ASP.NET related
    Thursday, November 12, 2020 7:02 PM

All replies

  • Hi Wild.Bill,

    Thank you for posting here.

    Since this thread is related to MVC, so I suggest that you can ask this question in the ASP.Net forum.

    Best Regards,

    Timon


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Friday, November 13, 2020 1:19 AM