473,326 Members | 2,173 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,326 software developers and data experts.

Define SqlDatSource in another function?

<asp:SqlDataSource ID="sqlCapBudgetItems" runat="server"
ConnectionString="<%$ ConnectionStrings:NETWebConnectionString %>"
SelectCommand="SELECT * FROM [CapitalBudgets] WHERE ([ApplicationID] =
@ApplicationID)">

<SelectParameters>

<asp:Parameter DefaultValue="5477" Name="ApplicationID" Type="Int32" />

</SelectParameters>

</asp:SqlDataSource>

Looking at the sample above, can I define the actual value of the
asp:parameter to something else in another sub? The 5477 value is just for
testing but can I dynamically change this to whatever I want. I've tinkered
with some syntax but nothing is working so far. For example....

sub page_load()

My Sub()

end sub

My Sub()

'Look up user's ID record and change value of asp:Parameter
DefaultValue to user's ID so I can load GridView with user data.

End Sub

Thanks!!

(VB.NET 2)


Mar 29 '06 #1
0 802

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

Similar topics

97
by: s | last post by:
Can I do this: #define MYSTRING "ABC" .. .. .. char mychar = MYSTRING; .. .. ..
34
by: Dennis | last post by:
I would like to dynamically allocate in a sub a 2 dimensional Array float *myarray = new float ; of course I get an error. How do you allocate a 2D array using the New operator? I...
18
by: Bryan Parkoff | last post by:
"#define" can only be inside the global scope before main() function. "#if" can be tested after "#define" is executed. The problem is that "#define" can't be inside main() function. I do not wish...
2
by: FAN | last post by:
I want to define some function in python script dynamicly and call them later, but I get some problem. I have tried the following: ################################## # code...
42
by: baumann | last post by:
hi all, typedef int (*pfunc)(int , int); pfunc a_func; i know it's ok, but how can define a_func without typedef statement? thanks .
2
by: FBM | last post by:
Hi, I am preparing project for submission and i'd like to allow the print out of debug messages. I know that with something like #define DEBUG #ifdef DEBUG print(X); #endif
4
by: adnan.yalin | last post by:
Could you suggest solutions to a problem currently I have? Problem: Let's say I have many different commands and I call a different function for each (void handle_command_1(*data), void...
6
by: wongjoekmeu | last post by:
I need to rewrite some typedef to #define. For instance I rewrote typedef void* handle to #define handle void* But I saw for instance another typedef in my code which I don't understand,...
1
by: Lambda | last post by:
I'd like to define a std::map: map<struct term, vector<size_t. The definition of the structure is: struct term { string word; size_t freq; }; the freq is the size() of vector<size_t>.
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
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...

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.