473,385 Members | 1,844 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

DataSource Parameter

Ben
I'm having difficulty getting a parameter value used in an Object Data
Source that populates a GridView control. Here's the overview:

GridView 1 has a button on it which the user clicks to drill down into data
subordinate to the record they're looking at. When the button is clicked,
GridView2 is supposed to populate with data from another table, filtered by
a field on the row in GridView1 whose button was clicked.

Right now the only way I can get it working is to have the key field for
GridView2 stored as a Session variable (done in the RowCommand event of
GridView1 when the button is clicked), and then tell the Object Data Source
for GridView2 that the key is that session variable (that's done when
configuring the object data source).

Is there a way to tell the Object Data Source to get its value from, say, a
property of the Page? According to the dropdown list in the Configure Data
Source / Define Parameters window, my only choices are "None", "Cookie",
"Control", "Form", "Profile", "QueryString", and "Session". I tried 'Form',
using a public property to store the parameter value, but couldn't get that
to work.

Other than Session, is there another way?

Thanks.
Ben
Jan 2 '07 #1
0 1104

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: no-spam | last post by:
Hello group, I have some questions concerning configuring and using a JNDI DataSource with PostgreSQL and Apache Tomcat. Currently, I belive I have successfully configured a "basic" DataSource....
0
by: David | last post by:
In ASP.NET 2.0, is it possible to use a control that's on a Master Page as a select parameter in a content page's datasource control? For example, the Master Page has a drop down list of...
3
by: David | last post by:
In ASP.NET 2.0, is it possible to use a control that's on a Master Page as a select parameter in a content page's datasource control? On the content page in the VWD Configure Data Source wizard...
2
by: Not Me | last post by:
Hi, I'm a little confused with working with parameters for a datasource - specifically when it comes to naming them. For example <asp:parameter Name="surname" type="String" /> this...
1
by: sck10 | last post by:
Hello, I have a GridView that has AutoGenerateSelectButton="true". When the "Select" link is clicked, it opens a FormView with the appropriate data. Below is the following SelectParameter that...
1
by: sck10 | last post by:
Hello, I have two datasources. The first one pulls data from a Stored Procedure. The second one from an SQL String. They both get there parameter value from a GridView...
6
by: WebBuilder451 | last post by:
I have a drop down list of saved searches for a user and i'm trying to use the datasource control to populate the ddl. The select value in the storedproc is the user.Identity.name. How can i use...
2
by: =?Utf-8?B?QnJldA==?= | last post by:
I am a VB and SQL developer but new to ASP.Net world. I have a SQL Datasource that returns an ID of the Current user. I've setup a second SQL Datasource that performs a SELECT statement to a table...
4
by: Brad Baker | last post by:
I'm trying to set a formview datasource parameter dynamically on page_load using the following code: public void Page_Load(object sender, EventArgs e) { SqlParameter param = new SqlParameter();...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.