|
Try Google
I didn't get any requirements for the signature
|
|
|
|
|
u can do it open add fiel into the Application and when user log in increase it value by one ,also when the user loged out decrease that varialble
1-when application start
Application.Add("UsersCount",0);
2-when User is logged in
Application["UsersCount"]=(int)Application["UsersCount"]+1;
3-when user logged out
Application["UsersCount"]=(int)Application["UsersCount"]-1;
regards
|
|
|
|
|
And if your user does not log out but simply closes the browser window you have to track the last request time and flush the user out if the last request was earlier than the session timeout.
-^-^-^-^-^-
no risk no funk ................... please vote ------>
|
|
|
|
|
wEb GuRu... wrote: I need to count number of users signed in to their account area on current time. Furthermore I need to view information of all users currently onlin.
You can create an application variable that holds all data you need. When each session starts, Session_Start event will be fired on Global.asax . You need to increment your application variable count here. In session_end decrease this value. This is the easy approach. But there are some problems with this
1- Session_End is not reliable
2- It's will be fired only if you are using inproc mode.
I have done this by creating a HTTPModule . For session end, I used cache and set Session timeout for cache. You need to create a delegate for Cache end, this will be similar like your session_end, but reliable.
wEb GuRu... wrote: I think the main problem is handling the event when a user close its window.
This is a common issue. No events will be fired on server when user closes browser. You need to wait till the session/cache ends.
|
|
|
|
|
Hi,
I need your help in my project i am using asp.net ajax toolkit controls, in that calendar control, after selecting the date i want to close that popup calendar window.please anybody help me please...waiting for your reply...
thanks & regards
Alex.
|
|
|
|
|
R you displaying that CalendarExtendar control in same page or another popup window????
use self.close(); method
Best Regard
Pathan
---------------------------------------------------
|
|
|
|
|
hai,
i am using default calendar method.while clicking the textbox calendar control will be displayed just below the textbox....i want to close or disapper that calendar after selecting the date.
the code i wrote is
<cc1:datepickertextbox id="txtLogStartDate" runat="server" onkeydown="return false;" cssclass="entrytext">
<cc2:calendarextender id="defaultCalendarExtender" runat="server" targetcontrolid="txtLogStartDate">
help me ..
alex.
|
|
|
|
|
Where is code?????????????
Best Regard
pathan
---------------------------------------------------
|
|
|
|
|
hai,
I couldn't able to paste the code here...
what i did was
one textbox is added and one CalendarExtender ....i want like after the selection of date that calendar should be invisible.....hope u understand my problem...
regards
alex.
|
|
|
|
|
After selecting date when u press TAB its automatically closed calendar.You have no need any code to close it manually.
see Example here CalendarExtendar
I couldn't able to paste the code here...
Check Ignore HTML tags in this message CheckBox here
Best regard
Pathan
---------------------------------------------------
|
|
|
|
|
<asp:textbox ID="Textbox1" runat="server"></asp:textbox>
<cc2:CalendarExtender ID="CalendarExtender1" runat="server" TargetControlID="Textbox1" OnClientDateSelectionChanged='hideCalendar'>
</cc2:CalendarExtender>
i want to close the calendar after the selection of date....
|
|
|
|
|
See the exmaple here Calendar for "Calendar with an associated button:"
apply PopupButtonID="button" it will be closed calendar control
best Regard
Pathan
---------------------------------------------------
|
|
|
|
|
hi,
I accept that, but the problem with that control is if we click the button the popup will come then if the user click again into the button the page will refresh that's actualy a fault...
can you help me to solve that with this method that's actually my need.
what i want is the same thing as you told but page will not be refreshed again if we click again into the button..hope you understand my problem...
regards
alex.
|
|
|
|
|
Ya I understand ur problem.
But y did u used Button? Use HtmlImage control Instead of Button
<img src="filepath.gif" id="img" runat="server" />
this control will not be refreshed ur page.
OR If u want to use Button control then just use OnClientClick="return false;"
Hope this will be solved ur problem
Best Regard
Pathan
---------------------------------------------------
|
|
|
|
|
Hello Everyone,
Can we use a text box like "Rich Text Box" .......
Actually i've to provide facility like bold,italic,underline and etc to the use at feedback form in ASP.NET(1.1) with c#
Suggest me some ways
Thnx
Your Friend
|
|
|
|
|
Get It Rich Text Editor
Best Regard
Pathan
---------------------------------------------------
|
|
|
|
|
|
I have a databound GridView-component on an ASP.NET page.
I need to display 12 months in that GridView. Sometimes the Stored Procedure reutrns less than 12 months of data (incomplete year of data like current year).
In that case I need to add rows to the gridview with Monthname and some 0 values in other cells.
How can I achieve this?
I found out already:
GridViewRow row = new GridViewRow(rownum, -1, DataControlRowType.DataRow, DataControlRowState.Normal);
But how to add filled cells to the row and how to add the created row to the already databound GridView ?
|
|
|
|
|
Easy, use a dataAdapter to get a datatable. Add new rows to the table.
<br />
DataTable dt new DataTable();<br />
YourDataAdapter.fill(dt);<br />
<br />
DataRow r = dt.NewRow();<br />
dt.Rows.Add(r);<br />
<br />
<br />
grid.datasource = dt;<br />
grid.databind();<br />
To sort use a dataview, good luck.
I didn't get any requirements for the signature
|
|
|
|
|
It was a hussle but this works:
Int32 position = grdClaimsData.Rows.Count;
GridViewRow row;
for (Int32 orgRijnum = 0; orgRijnum < 12 - position; orgRijnum++)
{
Int32 plek = position + orgRijnum + 1;
row = new GridViewRow(orgRijnum, grdClaimsData.Rows.Count, DataControlRowType.EmptyDataRow, DataControlRowState.Normal);
row.Cells.Add(new TableCell());
String MaandNaam = String.Empty;
switch (plek)
{
case 1: MaandNaam = "January"; break;
case 2: MaandNaam = "February"; break;
case 3: MaandNaam = "March"; break;
case 4: MaandNaam = "April"; break;
case 5: MaandNaam = "May"; break;
case 6: MaandNaam = "June"; break;
case 7: MaandNaam = "July"; break;
case 8: MaandNaam = "Augustus"; break;
case 9: MaandNaam = "September"; break;
case 10: MaandNaam = "October"; break;
case 11: MaandNaam = "November"; break;
case 12: MaandNaam = "December"; break;
default: MaandNaam = "Don't know the month-error"; break;
}
row.Cells[0].Text = MaandNaam;
row.Cells[0].Font.Bold = true;
Int16 Waarde = 0;
for (int i = 1; i < 11; i++)
{
row.Cells.Add(new TableCell());
if (i > 4)
row.Cells[i].Text = Waarde.ToString("C");
else
row.Cells[i].Text = "0";
}
row.HorizontalAlign = HorizontalAlign.Right;
grdClaimsData.Controls[0].Controls.AddAt(plek, row);
}
|
|
|
|
|
Hello !!
Actually i wanted to know that how can I display the contents of a .txt file in a table column in asp.net
Martand
|
|
|
|
|
File.ReadAllText(Server.MapPath("content.txt"));
It returns the content of .txt file as string format
Best Regard
Pathan
---------------------------------------------------
|
|
|
|
|
Is this supported in vs.net 2003.I am getting an error and ReadAllText does not exist in vs.net 2003
Mrinal
|
|
|
|
|
have U Declare namespance "System.IO" for File class.
Best Regard
Pathan
---------------------------------------------------
|
|
|
|
|
Hi,
I have a dropdownlist.on it selectedindexchange event i want to call a java script function.
how i do it.
i am using VisualStudio 2005.
Plz Tell me answer for it.
thanking u to all
|
|
|
|