https://stackoverflow.com/questions/14956027/how-to-pass-values-across-the-pages-in-asp-net-without-using-session

You can pass values from one page to another by followings..

Response.Redirect
Cookies
Application Variables
HttpContext

Response.Redirect

SET :

Response.Redirect("Defaultaspx?Name=Pandian");

GET :

string Name = Request.QueryString["Name"];

Cookies

SET :

HttpCookie cookName = new HttpCookie("Name");
cookName.Value = "Pandian";

GET :

string name = Request.Cookies["Name"].Value;

Application Variables

SET :

Application["Name"] = "pandian";

GET :

string Name = Application["Name"].ToString();

Refer the full content here : Pass values from one to another

Note:

for the cookies, and the Application. Especial the Application is not working if you use webgarden or webfarm !. And the application variables are a simple Dictionary<> that exist only for compatibility with the old asp and is not to be used. Also the cookies are not for transfer data from page to page like that. Very bad design, not good practice.

How to pass values across the pages in ASP.net without using Session的更多相关文章

  1. Creating Help Pages for ASP.NET Web API -摘自网络

    When you create a web API, it is often useful to create a help page, so that other developers will k ...

  2. Razor Pages with ASP.NET Core 2

    With ASP.NET Core 2 we get another way of building web applications. It’s one of those new things th ...

  3. [RxJS] Implement RxJS `mergeMap` through inner Observables to Subscribe and Pass Values Through

    Understanding sources and subscribers makes it much easier to understand what's going on with mergeM ...

  4. Introduction to Razor Pages in ASP.NET Core

    https://docs.microsoft.com/en-us/aspnet/core/mvc/razor-pages/ 从ASP.NET Core 2.0.0版本之后,添加了新的特性Razor p ...

  5. [Angular 2] Passing Template Input Values to Reducers

    Angular 2 allows you to pass values from inputs simply by referencing them in the template and passi ...

  6. Transferring Data Between ASP.NET Web Pages

    14 July 2012 20:24 http://www.mikesdotnetting.com/article/192/transferring-data-between-asp-net-web- ...

  7. Customizing Site-Wide Behavior for ASP.NET Web Pages (Razor) Sites

    Customizing Site-Wide Behavior for ASP.NET Web Pages (Razor) Sites By Tom FitzMacken|February 17, 20 ...

  8. 使用ASP.NET Web API Help Pages 创建在线接口文档

    操作步骤 1.新建Web API项目 2.在项目Areas文件夹下找到以下文件,取消注释图中代码. 3.右键解决方案,属性,如图设置. 4.运行程序,点击右上角API 接口列表: 详情-无参数: 详情 ...

  9. Demystifying ASP.NET MVC 5 Error Pages and Error Logging

    出处:http://dusted.codes/demystifying-aspnet-mvc-5-error-pages-and-error-logging Error pages and error ...

随机推荐

  1. ecshop注册用户增加手机验证功能

    1.去掉“用户名”注册 a.去掉提交 user_passport.dwt页面去掉 <input name="username" type="text" s ...

  2. 手把手教你用Pytorch-Transformers——实战(二)

    本文是<手把手教你用Pytorch-Transformers>的第二篇,主要讲实战 手把手教你用Pytorch-Transformers——部分源码解读及相关说明(一) 使用 PyTorc ...

  3. 用jmeter监控服务器资源

    jmeter可以监控服务器CPU.内存等性能参数,只需要安装一些插件,比其他方法更简单  1.下载需要的jmeter插件 如图上面两个是jmeter插件,可以再下面的链接中下载: https://jm ...

  4. Django 数据库多字段同时关联一个表为外键的解决办法

    多个字段对应一个外键时,会报错,如: class Storehouse_list(models.Model):#库位列表 nid = models.AutoField(primary_key=True ...

  5. HDU2188选拔自愿者

    悼念512汶川大地震遇难同胞--选拔志愿者 Time Limit: 1000/1000 MS (Java/Others)    Memory Limit: 32768/32768 K (Java/Ot ...

  6. mysql的sql语句优化方法面试题总结

    mysql的sql语句优化方法面试题总结 不要写一些没有意义的查询,如需要生成一个空表结构: select col1,col2 into #t from t where 1=0 这类代码不会返回任何结 ...

  7. 2019-5-28-VisualStudio-扩展开发

    title author date CreateTime categories VisualStudio 扩展开发 lindexi 2019-05-28 19:51:49 +0800 2018-2-1 ...

  8. Linux--shell三剑客<sed>--07

    1.sed(stream editor): 作为行编辑器,对文本进行编辑(以行为单位) 默认显示输出所有文件内容 注意:sed编辑文件,却不改变原文件 2.sed的工作原理: 指定一个文本文件,依次读 ...

  9. Taro -- 微信小程序登录

    Taro微信小程序登录 1.调用Taro.login()获取登录凭证code: 2.调用Taro.request()将code传到服务器: 3.服务器端调用微信登录校验接口(appid+appsecr ...

  10. Linux性能优化从入门到实战:16 文件系统篇:总结磁盘I/O指标/工具、问题定位和调优

    (1)磁盘 I/O 性能指标 文件系统和磁盘 I/O 指标对应的工具 文件系统和磁盘 I/O 工具对应的指标 (2)磁盘 I/O 问题定位分析思路 (3)I/O 性能优化思路 Step 1:首先采用 ...