The SqlDataSource control enables you to use a Web control to access data located in a relational database, including Microsoft SQL Server and Oracle databases. The SqlDataSource control uses ADO.NET classes to interact with any database supported by ADO.NET. You can use the SqlDataSource control ...

learn more… | top users | synonyms

2
votes
0answers
95 views

Automatic creation of parameters with the SqlDataSource Control

I've recently converted an existing web application from 3.5 to framework 4.0 and noticed a page stopped working - with an "incorrect number of parameters" error. Page is fairly simple and has a ...
2
votes
0answers
106 views

Dreamweaver data source won't work after the first try on Mac OS X

I have a problem with the Adobe Dreamweaver CS5 version 11. I am running Mac OS X Leopard. One fine day I found out about Adobe Dreamweaver's quick (& dirty) automated back-end programming. I ...
2
votes
0answers
475 views

Can I use an <asp:SessionParameter Direction=“Output”/> to *set* a variable?

If I have a SqlDataSource with InsertCommand="INSERT [Applications] ([UserID]) VALUES (@UserID);SELECT @ApplicationID=SCOPE_IDENTITY()" Can I use a SessionParameter to store the returned value? ...
1
vote
0answers
17 views

filter sqldatasource and display values that not equals filterexpression

I just want to filter my sqldatasource and display all values that not equals the filterexpression. Somehow like this: SqlDataSource1.FilterExpression != "something='something'"; Is there ...
1
vote
0answers
102 views

Why HikariCP datasource in spring throwing “HikariCP Housekeeping Timer” exception?

In my Spring application I'm using HikariCP as my datasource. It's working fine. But one strange thing is happening.I'm sharing the scenarios here: I have a login page where username and password ...
1
vote
0answers
204 views

How to filter using a dropdown in a gridview and display all values when none is selected

I have a web page with 3 values (1 text box, and 2 drop-downs) and displays result in a gridview. This is working great when the value that I want to search is in the drop-down. However, if the user ...
1
vote
0answers
115 views

SqlDataSource updating different fields with one UpdateCommand

I have a SqlDataSource that I would like to use for updating. I would be using two similar update commands, and I was wondering how I could do this in one SqlDataSource. I know how to do 'normal' ...
1
vote
0answers
667 views

getting return value from aspx sqldatasource

I've used the insert command through the code front in aspx and the output parameter is: asp:Parameter Name="ReturnCustomerID" Type="String" Direction="Output" and in the codebehind (C#) for ...
1
vote
0answers
123 views

adding order by to select command from webconfig

Hello I have an sql data source (below) and the select command is in the webconfig it is a simple select...from... . I use this select command a few times but the ORDER BY changes. Is there anyway to ...
1
vote
0answers
165 views

Set number of pages in gridview with custom source

Here is the scenario: I have gridView with sorting on TemplateField headers - SortExpression is set and gridView_Sorting function implemented. I store sorting values and directions in ViewState. I ...
1
vote
0answers
105 views

databinding with parameters to oracle via sql

We have a linked server set up in SQL Server to an oracle server. I need to populate a gridview with some data. But I find that when I use a parameter with the datasource the query is very slow. ...
1
vote
0answers
1k views

Insert database row via ASP.net 4.5 GridView on-board functionality?

I would like to insert a database entry by using standard functions of my GridView and SqlDataSource. Has there been any update on this topic since the dirty workarounds some versions ago (e.g. see ...
1
vote
0answers
241 views

nested repeater each with sqldatasource

<asp:HiddenField ID="hfOrderState" Value="1" runat="server" /> <asp:SqlDataSource ID="ReadyOrders" runat="server" EnableCaching="true" DataSourceMode="DataSet" ...
1
vote
0answers
155 views

How to make SQLDataSource insert into view instead of the underlying table?

We have replaced 20 tables with a consolidated table, that separates each set of data via a "set id" (all the records for table "A" have a set_id of 1, table "B" is 2, etc.). We then built views on ...
1
vote
0answers
228 views

Trouble handling exceptions with a SqlDataSource

I having trouble handling exception of a SqlDataSource. The SqlDataSource is currently being used by my ListView. My code doesn't seem to display an error message even though it looks correct to me. I ...
1
vote
0answers
400 views

how to use a procedure with Default parameter in gridview ASP.NET VS in sqldatasource

I want to use a stored procedure that can make some parameters with null value and then test it if the parameter is null or not and do some coding , the procedure is working fine ... but when i want ...
1
vote
0answers
546 views

SqlDataSource + Disabled Viewstate = Double DataBind

Here's a test page (.NET 4) I built to show the symptom I'm experiencing: <%@ Page Language="C#" AutoEventWireup="true" ViewStateMode="Disabled" %> <script runat="server"> protected ...
1
vote
0answers
755 views

java connection pool autocommit

I'm using for the first time the connection pool in java. The application that I'm writing is a web application deployed on oracle glassfish 3.1 and the resource connection pool is handled by it. I ...
1
vote
0answers
290 views

How to see foreign key value when showing a database in a DataGridView

I'm building a Windows forms application that connects to a database. I used the generate database from model function in Visual Studio 2010 to create the database in SQL Server. I have two tables: ...
1
vote
0answers
851 views

ASP.NET BoundFields not setting UpdateParameters

I have a few bound fields, but they don't seem to be setting the UpdateParameters for my SQL statement. I do have some code that runs on SqlDataSource Update to set UpdateParameters for non bound ...
0
votes
0answers
12 views

How can I add to SqlDataSource SELECT statement in code in Visual Studio for Web?

I have a data source SqlDataSource1 with SELECT * FROM [Locations] as the select statement built in when I created the DataSource. During run time I want to load the source with only DriverID = ...
0
votes
0answers
25 views

DataSource or DataSourceID cannot be defined on '___' when it uses model binding. .net VB

To start off I want to say that my sqldatasource and grid view were working until I decided to add the UpdateMethod to the GridView. After adding this and setting it to a sub in the codebehind I get ...
0
votes
0answers
27 views

Using a CheckBoxList as paramater for SqlDataSource

I'm trying to populate a GridView based on a CheckBoxList on the same page. The GridView works well, however, I can't find a way to only use the values from the CBL. I searched and tried a few things, ...
0
votes
0answers
19 views

dbo table not showing up in SqlDataSource control setup UI in Visual Studio

I have a database with two different tables, one of which I want to assign to a SqlDataSource control on my ASP.NET webform. When I go to the tasks menu (clicking on the arrow on the control in design ...
0
votes
0answers
24 views

Gridview Sum the Columns

I am trying to sum the columns into the footer in a Gridview. Each Gridview row has a separate sum for each column. Error Code on line "presum1 = Convert.ToDouble(TempTxt1.Text);": Input string was ...
0
votes
0answers
28 views

How can I make a button filter my table based off of dropdown choice? (.Net)

I'm trying to make a program in Visual Studio using asp.net that displays the results of a SQL Database in an HTML repeater table. I'm attempting to filter the data within the table so that you are ...
0
votes
0answers
19 views

Does The Order In Which SQLDataSource Parameters Are Specified When Calling A Stored Procedure Matter?

If I'm calling a Stored Procedure in a Microsoft SQL Server database which requires parameters, using an SQLDataSource control on an ASP.NET page, do I have to pass the parameter values from the ...
0
votes
0answers
13 views

DataRowView does not contain a property with the name 'FormID'

I am having trouble using the data value within a listbox. The DataValueField and SelectedValue always shows an error for the property FormID. <asp:ListBox ID="ListBox1" runat="server" ...
0
votes
0answers
55 views

GridView + DataKeyNames + BoundField, “must declare the scalar variable @…”

I'm trying to used Gridview, with sqldatasource and updatecommand. My update command has 3 parameters, 2 of them works fine, but the one of the ID fails. I tried all combinations of DataKeyNames + ...
0
votes
0answers
60 views

GridView Row Count after FilterExpression and Paging

I was using below code to count total row, But total row is not updating with filter expression. protected void SqlDataSource1_Selected(object sender, SqlDataSourceStatusEventArgs e) { int ...
0
votes
0answers
38 views

Sqldatasource connect Oracle database with parameters, code behind not working

I need set 3 parameters in SQLDatasource, binding source to the gridview. If I remove the parameters, and directly choose datasource from design view, it shows data correctly. I guess after pass ...
0
votes
0answers
143 views

Bind columns from two tables of a database into one gridview (Nonprogrammatically) ASP.NET

There are several answers to this question across the internet but every one is programmatically, which is more complicated than necessary. There's a way to do it in visual studio with the built in ...
0
votes
0answers
70 views

Object reference not set to instance of an object gridView datasource

So I have been looking in to this over and over trying to find something on it. I am trying to set my Grid View dataSourceID manually. My GridView ("GridView1") is inside of a FormView ("FormView1"). ...
0
votes
0answers
48 views

Context.User.Identity.GetUserId() doesn't return any value

Why the following code doesn't return any data? There are values in the database for Context.User.Identity.GetUserId() ASPX markup: <asp:SqlDataSource ID="owner_information" runat="server" ...
0
votes
0answers
41 views

Passing Context.User.Identity.GetUserId() to an SQL statement returns no data

I have the following code but it doesn't seem to work. The <%= Context.User.Identity.GetUserId() %> has a value in the database but it's not returning any data..... Thanks <asp:SqlDataSource ...
0
votes
0answers
25 views

How to exclude NULL values from DataBinder.Eval

I am trying to pull data from the same table where, one column only has about 10 values (Which I want to be bound to the header of my accordion menu in Asp.net) and the other column has over 100 ...
0
votes
0answers
57 views

How to set listitems to DropDownList in from database table without being exposed for SQL Injection?

All the other columns in GridView are using DataFields. GridView is populated visa DataSource property and DataTable. this.GridView2.DataSource = dTable; There's a DropDownList to be shown for ...
0
votes
0answers
90 views

How to fix connection leak error in glassfish 3.1.2?

I am seeing the below error in glassfish console: WARNING: RAR5117 : Failed to obtain/create connection from connection pool [ ftpinboundpool ]. Reason : ...
0
votes
0answers
44 views

SQL Query fails in Visual Studio

I need to display data on a chart from a database. As far as I can tell, the chart has to be bound to a DataSource which in my case is a SqlDataSource. My query to get this data is: SELECT A.a, A.b, ...
0
votes
0answers
27 views

ASP.NET GridView show edit button only if SQLDataSource value is specific

I have a GridView with auto generated Edit buttons, linked to an SQLDatasource with a "State" column in a table called "Leaves", Is there anyway that the Edit button appears only if the "State" of ...
0
votes
0answers
79 views

Dynamically update GridView results based on text entered into a textbox

I would like to dynamically update the results of a GridView based on characters that are entered into a textbox. My code currently works but only fires the update when the textbox loses focus or the ...
0
votes
0answers
31 views

ASP.Net Get Cookie values through SqlDataSource

I am trying to pass some of my cookie values into the sqldatasource as parameters. I've put the cookie name which is correct, but how do I get specific values of the cookie. Eg. name of cookie or ...
0
votes
0answers
145 views

Context variable cannot be resolved to a type MS SQL Server 2008 Tomcat 7 DataSource

I am trying to create a connection to an MS SQL Database using the context.xml and web.xml files but I am getting the following error: An error occurred at line: 26 in the jsp file: ...
0
votes
0answers
214 views

RadioButton selection changing dropdownlist datasource

This should be terribly straightforward, but I'm missing something. I've got a dropdownlist populated by a SQLDataSource which has its SelectCommand set from code behind. Upon initial page load, I ...
0
votes
0answers
47 views

C# Basic Active View Index Coding - Adding an Update View

I am attempting to do the code for an Update view on a multiview task. The directions are as follows: What is the index of the Update command in the RBL? If this index is selected, then before ...
0
votes
0answers
155 views

When adding to the database in the code behind the databound GridView does not update

I am attempting to allow users to add items to a table in a database and would like the user to be able to see the update reflected in a DataBound GridView below. However, while the database is ...
0
votes
0answers
33 views

SqlDataSource with MySQL using MySQL Connector for .Net

I am stuck in configuring SqlDataSource Object for MySQL Connector 6.8.3 (.Net Client). I have done the following so far. <asp:SqlDataSource ID="SDS_Orders" ...
0
votes
0answers
80 views

SQldatasource update not working

I am using templates in gridview. In 1 template I took a checkbox and in the footer templates I took a button. I want to perform an update action when the button is clicked on checked entries in the ...
0
votes
0answers
360 views

ASP.Net server side validation before insert Data to GridView

Im trying to build a simple App with ASP.Net. my Database has 3 tables: tblSong with columns: ID(PK, Unity), Title, ArtistId(FK), GenreId(FK) tblArtist: ID(PK, Unity) Artist tblGenre: ID(PK) Genre ...
0
votes
0answers
53 views

Sql Stored Procedure Help Request

I am very new in stored procedure. Developing own web application and for new requirement need to convert my SqlDataSource to Stored Procedure.. Here is my SqlDatasource and my first StoredProcedure ...