473,385 Members | 1,620 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

What's the API for read/write cookie

I need to create cookies in user's machine from my ASP.Net
code and I also need to read them. How do I do that? What
is the API (name space?) for this in APS.Net?

Thanks
Nov 18 '05 #1
1 1532
You can write cookies with the Response Object
Response.Cookies("cookieName") = myObject

You can read cookies with the Request Object
myObj = Request.Cookies("cookieName")

"feng" <an*******@discussions.microsoft.com> wrote in message
news:71****************************@phx.gbl...
I need to create cookies in user's machine from my ASP.Net
code and I also need to read them. How do I do that? What
is the API (name space?) for this in APS.Net?

Thanks

Nov 18 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: | last post by:
How does one read and write the cookie expiration date. At the moment my code is returning a value BUT a garbled value: '//Write cookie... Response.Cookies("Propsect").Expires = Date() + 1 ...
0
by: bb | last post by:
Hello In my Session_OnStart in Global.asa, I am setting some cookies. One of them, I set as follows: dim UserID UserID = Request.ServerVariables("LOGON_USER") Response.Cookies("User")("ID")...
4
by: Aki | last post by:
Hi, I have a problem with writing cookies in IE. The code works fine in Netscape 7.2, Opera 8 and Firefox 1.04. In IE 6 the cookie isn't written. I run WinXP SP2. I'm trying to show a...
16
by: ben beroukhim | last post by:
I have huge number of legacy code which use standard files functions. I would like to pass a memory pointer rather than a FILE pointer. I am trying to use FILEs in the code to refer to memory...
7
by: Øyvind Isaksen | last post by:
Hello! Have a site that contains both ASP (3.0) and ASP.NET files. When I log inn, my login.asp write info to a cookie to use for authentication in my asp.net files. One of the things I write to...
15
by: Edwin Knoppert | last post by:
I have searched but info is limitted. In my test app i used a non persistant cookie for forms authentication. slidingExpiration is set to true On run and close and rerun the login remains ok....
18
by: cj | last post by:
members of this type are safe for multithreaded operations. Instance members are not guaranteed to be thread-safe. I'm under the impression before you can use a class you have to make an...
1
by: conan1212 | last post by:
Can you tell me how to read and write a cookie by javascript. I think javascript can do, do you think as. Yours hopeful.
3
by: Mark1234567 | last post by:
I wonder if you can help me with the following: What is the Javascript code to store a site-wide cookie? (I want to record whether a person has been to my site before). What would be the code...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.