473,386 Members | 1,610 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,386 software developers and data experts.

How to programmatically change a Select Parameter

I'm working with VB.NET and ASP.NET 2.0. I've set up a Gridview. I want to
select on an integer field, lets say Invoice Number. I've added a text
control and Submit button to the page, and configured the datasource to
filter on this textbox control. It works fine in a default manner, no rows
are returned if the textbox is empty, and a single row is returned if a valid
Invoice Number is entered in the textbox. How can I program the gridview to
return all rows if nothing is entered in the text box?
Jul 1 '06 #1
1 2248
Fred,

I still did not use the gridview, but mostly are the complex data controls
completely dependend from their datasource, therefore if it is a datatable,
than it is just the complete column, however all kind of other answers can
be possible.

Cor

"Fred" <Fr**@discussions.microsoft.comschreef in bericht
news:D1**********************************@microsof t.com...
I'm working with VB.NET and ASP.NET 2.0. I've set up a Gridview. I want
to
select on an integer field, lets say Invoice Number. I've added a text
control and Submit button to the page, and configured the datasource to
filter on this textbox control. It works fine in a default manner, no
rows
are returned if the textbox is empty, and a single row is returned if a
valid
Invoice Number is entered in the textbox. How can I program the gridview
to
return all rows if nothing is entered in the text box?

Jul 2 '06 #2

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

Similar topics

18
by: NickName | last post by:
The following example may further clarify the question, Select fieldA, filedB, fieldC >From tblX Where fieldD = Forms!formName!controlName What I'd like to know is how to determine or get...
18
by: Julia Hu | last post by:
Hi, I have a datagrid, and in different rows I need to programmatically bind different type of controls and load data into these controls. For example,in the first row I need to bind data into a...
1
by: fuchs.markus | last post by:
Hello, on my page, I have a DetailsViewControl connected to a SqlDataSource. Now when I dynamically set the FilterExpression and FilterParameters - for example in a OnClick-EventHandler of a...
3
by: avezina | last post by:
We would like to use those new cool features of Asp.Net 2.0 like the ObjectDataSource in our project. I tried few basics examples and its work well. Let's say I have a page that displays a...
2
by: Charles Calvert | last post by:
I've checked the Google Groups archives and the web and not found the answer, though I've found hints that it's possible. How can I programmatically change the color scheme on Windows XP? I...
2
by: JJ | last post by:
How can I set an ObjectDataSource's Parameter programmatically? The slight complication here is that I want to set this NOT in the 'Selecting' method of the ObjectDataSource, but elsewhere. I...
0
by: cht13er | last post by:
Good day all, I'm a newish VBA coder who was taught from Google Groups - so thanks to you all very much! I have run into a minor problem, I hope you can give me some help ... I'm running office...
4
by: =?Utf-8?B?UGFycm90?= | last post by:
I cannot programmatically select a row in datagridview control. I use the following instruction to change the selection of a row dataGridView2.ClearSelection(); dataGridView2.Rows.Selected =...
6
by: Andrew Jocelyn | last post by:
Hi How do I programmatically change (read/write) the values in this app.config file at runtime? Specifically I want to change the client endpoint address but it would be nice to change other...
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: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
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: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
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: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...

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.