ObjectDataSource control acts as a data interface for databound controls such as: GridView, Repeater, FormView and DetailsView.
Questions tagged [objectdatasource]
618 questions
2
votes
2 answers
Optimal databasesystem for filters
I am building a website that implements filters that can be applied to a dataset. Allow me to explain these filters. In this case it will be a website with houses.
Number of rooms:
2 or less ( 2271 )
3 or more ( 4283 )
4 or more ( 2223…

Fokko Driesprong
- 2,075
- 19
- 31
2
votes
1 answer
DotNetNuke: ObjectDataSource for GridView not being found
As a follow-up to a previous question about GridView and DotNetNuke, I'm having a little more trouble getting things to act correctly. Right now I have a simple GridView in my ascx file and I bind the data to the GridView in my .cs file like…

AlexMax
- 1,204
- 14
- 36
2
votes
1 answer
ASP.NET ObjectDatasource use code-behind property
Is it possible to use a page-property as Datasource/DataSourceID for a ListBox or other controls like a Telerik RadCombobox?
I'm having a issue to bind data to a Telerik RadCombobox defined in a FilterTemplate of a RadGrid. I created a property in…

thomasvdb
- 739
- 1
- 11
- 32
2
votes
2 answers
Using Linq for ObjectDataSource: How to transform datetime using ToShortTimeString?
I am accessing a business class using an ObjectDataSource and trying to produce output that makes sense to the user. The return values describe a Class (as in Classroom and teaching, not software). I would like to show the time of the class as a…

Mark Brittingham
- 28,545
- 12
- 80
- 110
2
votes
3 answers
ListView + ObjectDataSource SelectMethod called twice when EnableViewState="false"
Note: This question has been completely modified now that I have a simpler example.
I have set up a sample page which only has a ListView and ObjectDataSource. The first time the page comes up (!IsPostBack), my GetList method is called once. After…

Nelson Rothermel
- 9,436
- 8
- 62
- 81
2
votes
1 answer
What attribute combo qualifies a class as a Data Component for ASP.NET?
When I use the wizard to configure an ObjectDataSource control, it presents a list of candiate business objects. This is of course quite long in even a small project, but it can be fileterd to only show Data Components.
How can I decorate my…

ProfK
- 49,207
- 121
- 399
- 775
2
votes
0 answers
Data binding order in ASP.NET
suppose following code:

Afshar Mohebi
- 10,479
- 17
- 82
- 126
2
votes
2 answers
GridView and objectDataSource
I have a grid view that bounded to an object data source that select data from type of student
public class student
{
int id;
string name;
int age;
public List GetAllStudents()
{
// Here I'm retrieving a list of…

Amira Elsayed Ismail
- 9,216
- 30
- 92
- 175
2
votes
2 answers
Can you get a DataTable from an ObjectDataSource?
If I have an ObjectDataSource defined at design time, can I get a DataTable from that ObjectDataSource at runtime? I have a method that returns a DataTable that I am using for the Select method property of the ObjectDataSource.

Xaisoft
- 45,655
- 87
- 279
- 432
2
votes
1 answer
.Net ObjectDataSource error: Object does not match target type
I have an ObjectDataSource on a page that is producing the error "Object does not match target type" when its Insert method is invoked. From Googling this message, I believe this the message is deceptive and I'm actually getting a null reference…

Treighton
- 111
- 2
- 9
2
votes
1 answer
How do I stop my ObjectDataSource from binding twice?
This has been covered a couple of times, without a suitable answer:
ObjectDataSource firing twice, or on its own
ObjectDataSource created twice when control is changed
I have created a custom paging data class that is used with an…

clifgriffin
- 2,008
- 3
- 21
- 41
2
votes
1 answer
How to handle Object Data Source Exception handling in DotNetNuke
I've created several DNN (5.2.3) modules and I'm finding that if an error happens on the object data source (ODS) DNN will then show that error to everyone. A sample (though not a ODS specific error in this case) is shown below. This has no meaning…

thames
- 5,833
- 6
- 38
- 45
2
votes
2 answers
VB.Net: How to use an Object data source in report (.rdlc)
My question is similar to this one but I'm having some problems with the actual implementation.
I've got a report (.rdlc) in the business layer of a 3-tier app.
I've got an object in the BL (EmployeeManager) which has a GetEmployees(Expression as…

Basic
- 26,321
- 24
- 115
- 201
2
votes
1 answer
Dynamically add columns to Gridview using different datasource than what is bound
Tell me if this is even possible:
I have a gridview bound to an ObjectDataSource providing me with data from a database. I'm filling the Objectdatasource using Linq-to-entities. Typical setup where I'm supplying the columns and rows.
Below I have a…

isorfir
- 771
- 2
- 8
- 19
2
votes
1 answer
Why does ObjectDataSource require an optional parameter of a function?
This ObjectDataSource will return an error when connecting to the following function:
Function with optional parameter:
Public…

Tony L.
- 17,638
- 8
- 69
- 66