Этот баннер — требование Роскомнадзора для исполнения 152 ФЗ.
«На сайте осуществляется обработка файлов cookie, необходимых для работы сайта, а также для анализа использования сайта и улучшения предоставляемых сервисов с использованием метрической программы Яндекс.Метрика. Продолжая использовать сайт, вы даёте согласие с использованием данных технологий».
Политика конфиденциальности
|
|
|
ASP.NET 2.0 : Проблемы...
|
|||
|---|---|---|---|
|
#18+
Всем бодрого времени суток. У меня такая проблема: Создается подключение в событии Page_Load:protected void Page_Init(object sender, EventArgs e) { SqlDataSource adapter; adapter = new SqlDataSource("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=G:\\Vadim\\ktos_db\\Данные.mdb;Persist Security Info=True;Password=alexBR;User ID=al;Jet OLEDB:System database=G:\\Vadim\\ktos_db\\wg.mdw;Jet OLEDB:Database Password=alexBR", "SЕLECT Сокращение FROM Категория"); DropDownList1.DataSource = adapter; DropDownList1.DataBind(); } Но в этом самом DropDownList1 обсолютно ничего не отображается. Если же пробовать через Через DropDownList1.DataSourceID и adapter.ID="ktos", то появляется ошибка: The DataSourceID of 'DropDownList1' must be the ID of a control of type IDataSource. A control with ID 'ktos' could not be found. Как можно избавится от ошибки? Заранее спасибо. ... |
|||
|
:
Нравится:
Не нравится:
|
|||
| 19.07.2006, 08:20 |
|
||
|
ASP.NET 2.0 : Проблемы...
|
|||
|---|---|---|---|
|
#18+
Код: plaintext 1. 2. 3. 4. ... |
|||
|
:
Нравится:
Не нравится:
|
|||
| 19.07.2006, 10:19 |
|
||
|
ASP.NET 2.0 : Проблемы...
|
|||
|---|---|---|---|
|
#18+
Это не помогло... Решил поэксперементированить с GridVew. Писал тоже самое : adapter.ID = "ktos"; GridView1.DataSource = adapter; GridView1.DataBind(); А в итоге на странице : Unable to find the requested .Net Framework Data Provider. It may not be installed. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.ArgumentException: Unable to find the requested .Net Framework Data Provider. It may not be installed. Source Error: Line 18: adapter.ID = "ktos"; Line 19: GridView1.DataSource = adapter; Line 20: GridView1.DataBind(); Line 21: Line 22: Source File: c:\Inetpub\wwwroot\KtosTest\Default.aspx Line: 20 Stack Trace: [ArgumentException: Unable to find the requested .Net Framework Data Provider. It may not be installed.] System.Data.Common.DbProviderFactories.GetFactory(String providerInvariantName) +1371991 System.Web.UI.WebControls.SqlDataSource.GetDbProviderFactory() +63 System.Web.UI.WebControls.SqlDataSource.GetDbProviderFactorySecure() +19 System.Web.UI.WebControls.SqlDataSourceView.ExecuteSelect(DataSourceSelectArguments arguments) +120 System.Web.UI.DataSourceView.Select(DataSourceSelectArguments arguments, DataSourceViewSelectCallback callback) +17 System.Web.UI.WebControls.DataBoundControl.PerformSelect() +149 System.Web.UI.WebControls.BaseDataBoundControl.DataBind() +70 System.Web.UI.WebControls.GridView.DataBind() +4 ASP.default_aspx.Page_Init(Object sender, EventArgs e) in c:\Inetpub\wwwroot\KtosTest\Default.aspx:20 System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) +15 System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +34 System.Web.UI.Control.OnInit(EventArgs e) +2069676 System.Web.UI.Page.OnInit(EventArgs e) +9 System.Web.UI.Control.InitRecursive(Control namingContainer) +321 System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +692 -------------------------------------------------------------------------------- Version Information: Microsoft .NET Framework Version:2.0.50727.42; ASP.NET Version:2.0.50727.42 ... |
|||
|
:
Нравится:
Не нравится:
|
|||
| 20.07.2006, 10:47 |
|
||
|
|

start [/forum/topic.php?desktop=1&fid=18&tid=1391504]: |
0ms |
get settings: |
7ms |
get forum list: |
10ms |
check forum access: |
2ms |
check topic access: |
2ms |
track hit: |
125ms |
get topic data: |
7ms |
get forum data: |
2ms |
get page messages: |
27ms |
get tp. blocked users: |
1ms |
| others: | 250ms |
| total: | 433ms |

| 0 / 0 |
