How to pass list as a parameter in response.redirect

后端 未结 3 2027
予麋鹿
予麋鹿 2021-01-26 10:28

Prob1:I have 2 lists which i want to access in the next page which i will be redirecting. Current result, When i pass my result, in the url it shows the List data type.

<
3条回答
  •  悲&欢浪女
    2021-01-26 10:55

    Prob 1: You need to comma-separate your list values. Need more info to give you exact code as I have no idea if this is asp.net or asp.net mvc or something else. If, say, this is redirecting to another action in asp.net mvc your receiver action param needs to be a List and you redirect to /Receiver?param1=value1,value2,value3 ...

    Hopefully that answers your question

    Prob 2: Cant redirect from an ajax request. Need to return something special and handle it on the front-end.

提交回复
热议问题