2019年9月25日 星期三

asp.net webmethod 使用session 做資料交換的問題

實作上跨 webmethod 常常不能取得 System.Web.HttpContext.Current.Session 內的資料
例如在 webmethod1 寫入然後在 webmethod2 讀取時會是null
改用 System.Web.HttpContext.Current.Cache 則ok

沒有留言:

批次檔正確處理中文

1. 確定檔案編碼為 UTF-8 2. 開頭先執行 chcp 65001