|
If you just want to use that function in multiple pages then what you can so is place that function in a class file and then call it from the pages where ever you want.
Best Regards,
Apurva Kaushal
|
|
|
|
|
Can I implement lostfocus, gotfocus and keypress events in ASP.Net as in VB6.0
Nandini Sharma
|
|
|
|
|
Those events occur in the browser, so you use client script, i.e. Javascript, to handle them. They are named onfocus, onblur and onkeypress.
---
b { font-weight: normal; }
|
|
|
|
|
hi dear
i am trying to calculate the total amount of memory and cpu used while using string and stringbuilder.
i am trying this way ...
calling a method in one button click and writin to response.
Process myprocess=Process.GetCurrentProcess();
string str=null;
for (int i=0;i<=10000;i++)
{
str+="Hello1";
str+="Hello2";
}
Response.Write("using string : "+myprocess.WorkingSet.ToString()+" ");
and calling another method on another button click and writing to response.
Process myprocess=Process.GetCurrentProcess();
StringBuilder str=new StringBuilder();
for (int i=0;i<=10000;i++)
{
str.Append("Hello1");
str.Append("Hello2");
}
Response.Write("using stringbuilder : "+myprocess.WorkingSet.ToString()+" ");
but i am not getting the appropriate answer as it is showing the stringuilder is using much memory then string...
i have calculated the total time using two date time variables initialising them before starting and end of loop and then subtracting and getting the milliseconds of difference in between them. one more thing that i am calling both the functions after restarting the page.
please help out me guys, i need the solution of this problem very urgently!!!!!!!!!!!!!!!!!!!!!!!!1
regards
vishal sharma
Thanks & Regards
Vishal Sharma
vishalsharma556@yahoo.co.in
|
|
|
|
|
Don't do this:
Process myprocess = Process.GetCurrentProcess();
Just replace all of the myprocess lines with Process.GetCurrentProcess() . The data in myprocess doesn't change.
|
|
|
|
|
Hi,
we use PostBackUrl passing values of controls from one page to anther page in encrypted way(FORM)
can i use same method to pass the values of variable in code Behind of page 1 to code Behind of page 2?
any one explain
thanks a lot....
|
|
|
|
|
In your second page, look at using PreviousPage.FindControl() passing it the control ID of the control you want the data from in the first page. You'll have to typecast it to the proper control type to get the data, but this does work. I don't believe that this encrypts the data, but it is not visible in the URL.
-Matt
------------------------------------------
The 3 great virtues of a programmer:
Laziness, Impatience, and Hubris.
--Larry Wall
|
|
|
|
|
This is good
But I mean how I can pass the values of variable in code behind of page 1 to page 2
thanks
|
|
|
|
|
If all you want is to pass the value of a variable, just use your Session object:
Session["variable_name"] = myVariable;
And then in your second page
string myVariable = Session["variable_name"].ToString();
If this is not feasible because you don't want to use cookies (which Session uses by default), there is a way to enable cookieless sessions.
-Matt
------------------------------------------
The 3 great virtues of a programmer:
Laziness, Impatience, and Hubris.
--Larry Wall
|
|
|
|
|
sir,
What's the difference between session.clear and session.abandon ?
Thanks.
|
|
|
|
|
Session.Clear stays in the same session.
Session.Abandon dumps the current session and starts a new session.
Sincerely,
Elina
Life is great!!!
Enjoy every moment of it!
|
|
|
|
|
Hope u r all fine
I have a problem concerning sorting in a datagrid.
I have a bound column that gets its value from 2 database fields -FirstName & LastName-
When I write in the sort expression of that column "FirstName" it sorts properly but when I write "FirstName,LastName" it doesn't sort..
So how can I sort using these 2 columns together??
Thanks a lot in advance
|
|
|
|
|
You cant sort the data in the database with two columns. Alternatively what you can do is make the combination of the two columns and then in sort it there in temporary sorage such as dataset.
Best Regards,
Apurva Kaushal
|
|
|
|
|
try to use dataview for sorting...
Thanks & Regards
Vishal Sharma
vishalsharma556@yahoo.co.in
|
|
|
|
|
<advertisements>
<ad>
<imageurl>915a.swf
<navigateurl>http://www.mashhad915.com
<alternatetext>mobile
<keyword>A
<impressions>Technology
This is the caption for Ad#1
<ad>
<imageurl>mahak.swf
<navigateurl>http://www.mashhad915.com
<alternatetext>mobile
<keyword>A
<impressions>Technology
This is the caption for Ad#1
|
|
|
|
|
Anyone knows how to add the thousand (comma) separator to bound columns that contain numbers in a GridView control?
Mohamed El Gohary
|
|
|
|
|
you can use DataFormatString for that purpose.
Best Regards,
Apurva Kaushal
|
|
|
|
|
Thanks, the point is that I tried it before and it never worked though the format string was a right one. The point is that are there any options that I should turn on to make it work.
Mohamed El Gohary
|
|
|
|
|
|
How can i display in a dropdownlist more than 3 values?any custom built dropdownlist facility available or what exactly i need to use to do this,
I have no idea of doing this,Give me an idea with some code.Thanks in advance.
am i need to use Grid for this???Give me correct idea?
kissy
|
|
|
|
|
I could not understand the problem, do you want to three different display values ?
if so then you can combine the 3 into one and then display it in the drop down list.
Best Regards,
Apurva Kaushal
|
|
|
|
|
Here i need to display more than 3 columns at a time in a dropdown list.
Together display how it is???
id,name,age,class with the respective heddings i have to display,How???
kissy
|
|
|
|
|
AFAIK this is not possible to display three different text with three separate headers.
Best Regards,
Apurva Kaushal
|
|
|
|
|
Hi dears,
I want to start programming a Messenger application like yahoo messenger,...!
But I dont know how to start or which features should I know?
I really tanks if sombody can help me!
www.behzadi.net
|
|
|
|
|
furza_milan wrote: But I dont know how to start or which features should I know?
If you don't know even where you want to go, how will you know if you get there?
First, what features do you want? (Inlcude in the list even the most obvious and basic features you can think of)
|
|
|
|