Гость
Целевая тема:
Создать новую тему:
Автор:
Форумы / ASP.NET [игнор отключен] [закрыт для гостей] / Dropdownlist не работает в listview / 1 сообщений из 1, страница 1 из 1
29.12.2014, 19:38
    #38846027
Dmitriy78781
Гость
Скрыть профиль Поместить в игнор-лист Сообщения автора в теме
Dropdownlist не работает в listview
Здравствуйте. Пытаюсь вставить dropdownlist в listview но при попытки корректировки выдает ошибку Failed to load viewstate. The control tree into which viewstate is being loaded must match the control tree that was used to save viewstate during the previous request. For example, when adding controls dynamically, the controls added during a post-back must match the type and position of the controls added during the initial request
Код: c#
1.
2.
3.
4.
5.
6.
7.
8.
9.
10.
11.
12.
13.
14.
15.
16.
17.
18.
19.
20.
21.
22.
23.
24.
25.
26.
27.
28.
29.
30.
31.
32.
33.
34.
35.
36.
37.
38.
39.
40.
41.
42.
43.
44.
45.
46.
47.
48.
49.
50.
51.
52.
53.
54.
55.
56.
57.
58.
59.
60.
61.
62.
63.
64.
65.
66.
67.
68.
69.
70.
71.
72.
73.
74.
75.
76.
77.
78.
79.
80.
81.
82.
83.
84.
<EditItemTemplate>
                    <span style="">
                    <asp:TextBox ID="tb_UserId" runat="server" Text='<%# Bind("UserId") %>' visible="false"/>
                    

                    
                    <asp:TextBox ID="tb_UserName" runat="server" 
                        Text='<%# Bind("UserName") %>' visible="false"/>
                    

                    Фамилия:
                    <asp:TextBox ID="tb_Surname" runat="server" Text='<%# Bind("Surname") %>' />
                    

                    Имя:
                    <asp:TextBox ID="tb_Name" runat="server" Text='<%# Bind("Name") %>' />
                    

                    
                    <asp:TextBox ID="tb_DataBirthday" runat="server" 
                        Text='<%# Bind("DataBirthday") %>' visible="false"/>
                    
                    
                    <asp:TextBox ID="tb_Nationality" runat="server" 
                        Text='<%# Bind("Nationality") %>' visible="false"/>
                    
                    Страна:
                        
                   <asp:TextBox ID="tb_Country" runat="server" Text='<%# Bind("Country") %>' />
                    
                        <asp:DropDownList ID="DropDownList1" runat="server"
                        DataTextField="name" DataValueField="id" SelectedValue='<%# Bind("Country") %>'>
                        </asp:DropDownList>
                    

                    Область:
                    <asp:TextBox ID="tb_Region" runat="server" Text='<%# Bind("Region") %>' />
                    

                    Город:
                    <asp:TextBox ID="tb_City" runat="server" Text='<%# Bind("City") %>' />
                    

                    Образование:
                    <asp:TextBox ID="tb_Education" runat="server" 
                        Text='<%# Bind("Education") %>' />
                    

                    Специальность:
                    <asp:TextBox ID="tb_Occupation" runat="server" 
                        Text='<%# Bind("Occupation") %>' />
                    

                    Мобильный:
                    <asp:TextBox ID="tb_Mobile" runat="server" Text='<%# Bind("Mobile") %>' />
                    

                    <asp:TextBox ID="tb_Email" runat="server" Text='<%# Bind("Email") %>' visible="false"/>
                    
                    Рост:
                    <asp:TextBox ID="tb_Height" runat="server" Text='<%# Bind("Height") %>' />
                    

                    Вес:
                    <asp:TextBox ID="tb_Weight" runat="server" Text='<%# Bind("Weight") %>' />
                    

                    О себе:
                    

                    <asp:TextBox ID="tb_About" runat="server" Text='<%# Bind("About") %>' Height="125px" 
                    Width="285px" TextMode="MultiLine" />
                    

                    <asp:Button ID="UpdateButton" runat="server" CommandName="Update" 
                        Text="Сохранить" />
                    <asp:Button ID="CancelButton" runat="server" CommandName="Cancel" 
                        Text="Закрыть" />
                    

                    

                    </span>
                </EditItemTemplate>
...
Рейтинг: 0 / 0
Форумы / ASP.NET [игнор отключен] [закрыт для гостей] / Dropdownlist не работает в listview / 1 сообщений из 1, страница 1 из 1
Найденые пользователи ...
Разблокировать пользователей ...
Читали форум (0):
Пользователи онлайн (0):
x
x
Закрыть


Просмотр
0 / 0
Close
Debug Console [Select Text]