AXForum  
Вернуться   AXForum > Microsoft Dynamics AX > DAX Blogs
All
Забыли пароль?
Зарегистрироваться Правила Справка Пользователи Сообщения за день Поиск

 
 
Опции темы Поиск в этой теме Опции просмотра
Старый 13.08.2010, 21:06   #1  
Blog bot is offline
Blog bot
Участник
 
25,644 / 848 (80) +++++++
Регистрация: 28.10.2006
sumitax: Use of ViewState in User control
Источник: http://sumitax.wordpress.com/2010/07...-user-control/
==============

During development of user controls in EP, if  you wish to preserve the state(value) of  Page Level variables , you can use ViewState available in EP Framework in Ax2009. This is useful because Enterprise portal by default is stateless and if data  need to persisted across various postbacks events  in web control for example in a Dataset, ViewState comes as a handy option.

Scenario :  When a button is clicked on user control or user goes to next page in a Web control which uses a wizard , then a postback event is fired and value of page level variables is lost.

Usage : Use the following code to store the variable under ViewState

 ViewState[“InvoiceId”] = invoiceId; 

And to retrieve the value , use code below

invoiceId = ViewState[“InvoiceId”]




Источник: http://sumitax.wordpress.com/2010/07...-user-control/
__________________
Расскажите о новых и интересных блогах по Microsoft Dynamics, напишите личное сообщение администратору.
 

Похожие темы
Тема Автор Раздел Ответов Посл. сообщение
sumitax: Calling external applications from User control in EP Blog bot DAX Blogs 0 13.08.2010 21:06
emeadaxsupport: Dynamics User Control is shown as hidden in Dynamics Ax 2009 Enterprise Portal Blog bot DAX Blogs 0 13.05.2010 01:05
Solutions Monkey: 64bit machine - VS EP add-in not deploying user control to SharePoint while saving Blog bot DAX Blogs 0 06.01.2010 08:19
Solutions Monkey: Redirecting in EP user control to download a file Blog bot DAX Blogs 0 11.09.2009 15:05
Inside Dynamics AX 4.0: The Security Framework Blog bot DAX Blogs 0 31.10.2007 11:40

Ваши права в разделе
Вы не можете создавать новые темы
Вы не можете отвечать в темах
Вы не можете прикреплять вложения
Вы не можете редактировать свои сообщения

BB коды Вкл.
Смайлы Вкл.
[IMG] код Вкл.
HTML код Выкл.
Быстрый переход

Рейтинг@Mail.ru
Часовой пояс GMT +3, время: 22:07.