CFF KB - Carrz-Fox-Fire Promotions Knowledge Base

CFF KB is all about 1 thing: The Sharing of Knowledge and the Power we gain from it.
  • Breadrumbs:
  • 'mycookie' is not declared. It may be inaccessible due to its protection level.

  • CFF Knowledge Base - Share With Facebook CFF Knowledge Base - Share on Twitter CFF Knowledge Base - Share on Reddit CFF Knowledge Base - Share on Digg It CFF Knowledge Base - Share on Stumble Upon It CFF Knowledge Base - Share on Delicious
    Share With Friends (Updated 6-8-2010)
  • Article ID:
    7286
  • Date Created
    Saturday, March 15, 2025
  • Last Updated
    Saturday, March 15, 2025
  • This Article Has been Viewed
    54 times
  • Short Desc
    ' is not declared. It may be inaccessible due to its protection level.
  • Details
    When reading from a cookie, you have to make sure you wrap the cookie and name and value In double quotes.
  • Recreate Issue
     
    Dim strcsun As String = Context.Request.Cookies(mycookie)("User")


    In the above, we can see that the cookie name mycookie
    Is not enclosed in double quotes. "mycookie"
  • Resolve Issue
     
    Dim strcsun As String = Context.Request.Cookies("mycookie")("User")


    Enclosing the cookie name with double quotes. "mycookie"
    Resolves this issue.