3

I have a aspx page. On some processing on the page, I am attaching some values to the url with javascript.

Ex:
http://localhost:8080/Default.aspx#value1

Now I do a postback, How do I get the url with javascript appended values(#value1)?

Scath
  • 3,777
  • 10
  • 29
  • 40

3 Answers3

2

Have you tried using:

request.RawURL
Carlos Landeras
  • 11,025
  • 11
  • 56
  • 82
2

try this Page.ClientQueryString

Rahul
  • 5,603
  • 6
  • 34
  • 57
Hitesh
  • 37
  • 7
0

Request.RawURL will not work either,

The RawUrl property returns the portion of the URL that does not contain the website address.

e.g. In www.example.com/home/account, rawurl will return

/home/account only.

you need to reserve your url before making a postback.

Jens Kloster
  • 11,099
  • 5
  • 40
  • 54