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

 
 
Опции темы Поиск в этой теме Опции просмотра
Старый 20.09.2005, 17:33   #1  
Ace of Database is offline
Ace of Database
Участник
Аватар для Ace of Database
 
870 / 637 (23) +++++++
Регистрация: 14.10.2004
Еще раз про пользовательские настройки форм
Привет всем!

Почему-то нельзя добавить в форму "Закупка" из Расчетов с Поставщиками поля во все группы контролов, которые принадлежат вкладке "Строки".

Когда открываешь пользовательские настройки формы, то в дереве видно, что у вкладки с именем TabLine, нарисован замок. Такой же замок нарисован у всех дочерних для этой вкладки контролов.

Свойство AllowUserSetup у вкладки установлено в Yes.

В чем может быть дело?
Старый 20.09.2005, 17:48   #2  
MironovI is offline
MironovI
Участник
 
724 / 77 (4) ++++
Регистрация: 30.05.2005
У Tab формы перекрыт метод TabChange - если его убить - будет вам счастье.. много счасться
За это сообщение автора поблагодарили: decoder (1).
Старый 20.09.2005, 17:50   #3  
Delfins is offline
Delfins
Участник
 
320 / 39 (2) +++
Регистрация: 20.09.2005
Адрес: Riga, Latvia
Странно,.. у меня тоже...

Может где какой Class `поправляет` значение
Старый 20.09.2005, 17:54   #4  
Delfins is offline
Delfins
Участник
 
320 / 39 (2) +++
Регистрация: 20.09.2005
Адрес: Riga, Latvia
MironovI, mozhet znajesh pochemu takoj plohoj super(...) ??
Старый 20.09.2005, 18:01   #5  
MironovI is offline
MironovI
Участник
 
724 / 77 (4) ++++
Регистрация: 30.05.2005
Смысл в том, что перекрывая TabChange мы "насильственно" управляем поведением формы, которая изначально IntelliMorf.. ну или как-то так.. - вобщем поскольку гарантировать нормальную работу после этого система не может - пользовательские настройки лочит. Как вариант - смотреть код TabChange и переносить его куда-нить, а метод убивать..
За это сообщение автора поблагодарили: Gustav (3).
Старый 20.09.2005, 18:06   #6  
Ace of Database is offline
Ace of Database
Участник
Аватар для Ace of Database
 
870 / 637 (23) +++++++
Регистрация: 14.10.2004
Спасибо, MironovI
Там метод tabChanged для номенклатуры-основного средства показывает группу контролов Asset_RU, а для остальных номенклатур прячет эту группу.

Наверное, придется это перекинуть куда-нибудь в PurchLine_DS.active(), а tabChanged удалить.
Старый 21.09.2005, 06:30   #7  
Peter Savintsev is offline
Peter Savintsev
Участник
 
246 / 119 (4) +++++
Регистрация: 14.12.2001
Я этот код переносил в pageActivated для 2-го TabPage.
Старый 21.09.2005, 09:58   #8  
sukhanchik is offline
sukhanchik
Administrator
Аватар для sukhanchik
MCBMSS
Злыдни
Лучший по профессии 2015
Лучший по профессии AXAWARD 2013
Лучший по профессии 2011
Лучший по профессии 2009
 
3,283 / 3491 (123) ++++++++++
Регистрация: 13.06.2004
Адрес: Москва
Руководство разработчика, раздел Coding for user setup of forms:

Coding for user setup of forms
Restraints on user setup due to coding style
In order for user setup to work, it is important that the code is independent of the actual positioning of the control, meaning that the developer must not use any information on the position of the control or assume that the ordering of controls is retained.

In some cases, the kernel will automatically restrict the user setup level. This is due to overridden methods on the control, which consider the position of the control.

Tab controls
If either of the below methods are overridden, the user setup level of “tab controls” cannot be higher than restricted, regardless of the property value.

tabChange

tabChanged

The reason for this is that these methods receive integer values for the FromTab and ToTab parameters.

public void tabChanged(int _FromTab, int _ToTab)

Because it cannot be certain what the exact values of these tabs are, the methods will lose focus on the index of the tab, and focus is put on the tab as a parameter. If the tab pages are reordered by the user, the parameters passed to these functions will lose their meaning. Therefore, it is possible to either override these methods, or allow for full customization of layout and content.

The following methods on the “tab page control” should be used instead:

pageActivated

allowPageDeactivate

These methods do not pass any information on the current positioning of the tab page, and therefore the code should be independent of the positioning.

MenuButton control
User setup level for this control is limited to “restricted” if the clicked method is overridden. This is because this method is usually used to add menu-items from code, and this does not work well with user setup of forms.

Coding style
When a data bound control is added to the form, a new control of the correct type is created, and the properties Name, Datasource, DataField, Label, and HelpText are set.

Because the control is automatically added by the system, the developer cannot add custom code to the control, but the control can use the code defined on the data source and the data source fields. This is why it is so important that the code from the controls is moved to the datasources. Note that lookup now can be coded on the datasource field.

Names of controls
To determine which control has been moved, it is crucial that a control can be identified by a unique name. Currently the setup information is packed with the control name and the control type, but control’s name should be unique.

Controls bound to fields in the auto fieldgroups are automatically given the name:

<groupName>_<FieldName> for data fields

<groupName>_M_<FieldName> for display methods

Therefore, these names should be avoided elsewhere in the system.

When the user creates new controls, they are automatically given a name which contains the user id and a counter number, so name clashes should be avoided.

Тут достаточно подробно описаны все нюансы доступности пользовательской настройки
__________________
Возможно сделать все. Вопрос времени
Старый 21.09.2005, 10:46   #9  
belugin is offline
belugin
Участник
Аватар для belugin
Сотрудники Microsoft Dynamics
Лучший по профессии 2017
Лучший по профессии 2015
Лучший по профессии 2014
Лучший по профессии 2011
Лучший по профессии 2009
 
4,622 / 2925 (107) +++++++++
Регистрация: 16.01.2004
Записей в блоге: 5
и тут подборка ссылок:
http://erpkb.com/Axapta/Pol'zovatel'skajaNastrojjkaInterfejjsa
 

Похожие темы
Тема Автор Раздел Ответов Посл. сообщение
Пользовательские настройки и модификация форм olesh DAX: Программирование 6 30.03.2017 10:54
И снова про пользовательские настройки форм Ace of Database DAX: Администрирование 4 01.12.2006 12:05
Слетают пользовательские настройки wit DAX: Функционал 0 22.06.2006 10:58
Пользовательские настройки и точки останова loka DAX: Программирование 5 27.04.2005 14:48
Можно ли загрузить пользовательские настройки одновременно для нескольких форм? zlata DAX: Функционал 2 08.12.2003 10:58

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

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

Рейтинг@Mail.ru
Часовой пояс GMT +3, время: 05:30.
Powered by vBulletin® v3.8.5. Перевод: zCarot
Контактная информация, Реклама.