|
I have developed a website. If i use Internet 7.0 , i am able to open multiple instances of the application and my session variables are getting mixed up. Some one told me that i can Use GUID. Is there any other better method. If i have to use GUID. How to use GUID?
Plz help me
Mads
|
|
|
|
|
It's not very likely that the session variables gets mixed up, it's more likely that you mix up which session each window belongs to.
I haven't yet tested exactly how IE 7 handles browser sessions. I know that using IE 6 you can open separate instances of the browser, and each instance is it's own session. You can open several windows from each instance, and each window in one instance belongs to the same session.
Using firefox you can only open one instance (trying to open another will open a new window in the same instance), so all windows will be in the same session.
The session id is stored as a temporary cookie in the browser instance. You can display the Session.SessionID value in the page during testing, so that you can track what session each window belongs to.
---
single minded; short sighted; long gone;
|
|
|
|
|
Hi
I made an application in ASP.net 2.0 with c#.
My problem is:-
I have created one WebUserControl.ascx and this WebUserControl.ascx contains one dropdown list.In dropdownlist I have added five items like 1,2,3,4 and 5.
Then, I create on Default.aspx which contains
<%@ Register Src="WebUserControl.ascx" TagName="WebUserControl" TagPrefix="uc1" %>
<title>Untitled Page
<uc1:webusercontrol id="WebUserControl1" runat="server">
<asp:checkbox id="CheckBox1" runat="server" autopostback="True">
<uc1:webusercontrol id="WebUserControl2" runat="server">
WebUserControl :-
<%@ Control Language="C#" AutoEventWireup="true" CodeFile="WebUserControl.ascx.cs" Inherits="WebUserControl" %>
<asp:dropdownlist id="DropDownList1" runat="server">
<asp:listitem>1
<asp:listitem>2
<asp:listitem>3
<asp:listitem>4
<asp:listitem>5
Now I would like to do when checkbox1 is true then
Select Index of DropDownList1 in WebUserControl2 should be 2.
I mean to say, how we can envoke or call event on Select of CheckBox1 ?
rajesh
|
|
|
|
|
Try accessing the dropdown using the properties.
public returntype propertyname
{
get{return dropdown1.selectedindex}
set{dropdown1.selectedindex=value}
}
so, while you are using checkboxes try to change this property!!
Just an idea not sure whether it would work or not?
Gautham
|
|
|
|
|
Write it in user control itself you can public property in user control
|
|
|
|
|
Hi
can anybody please let me know the regular expression the below scenario
1. Password should contain minimum of 6 characterss
2. Password should be alpha numeric
3. Password should contain atleast 2 numbers and 4 characters
4. Password shouldnot contain any special character
Thanks a lot in Advance
Thanks and Regards
Venkat
|
|
|
|
|
1 and 2 are simple (and 4 is covered by 2):
^[A-Za-z0-9]{6,}$
3 can perhaps be solved by adding a pair of zero-length lookaheads:
^(?=(.*\d){2})(?=(.*[A-Za-z]){4})[A-Za-z0-9]{6,}$
---
single minded; short sighted; long gone;
|
|
|
|
|
Hi,
I want to get only the Date part from the DateTime Field. I dont want the time to be displayed along with the date. How to get it?
I am using VB.net and it's a windows application.
My code is :
Dim grdToDate As String = currentRow.Cells(4).Value
Dim gridToDate As String = Format(currentRow.Cells(4).Value, "mm/dd/yyyy")
Dim AMCFrmDt As String = Format(AMCFromDate.Value, "mm/dd/yyyy")
But it is not giving methe proper result.
Thanks,
Riz
|
|
|
|
|
Check for any method like Date, grdToDate.Date???
Gautham
|
|
|
|
|
Dear Mam,
It may work fine I guess, please try it out. And tell me yesterday u have asked for disabling back button. Which was working fine. Please let me know.
Dim dt As Date = Date.Parse("<the given Date Time string>")
Dim strDate = dt.Month & "/" & dt.Day & "/" & dt.Year
Thank you.
Regards,
Aleem,
S/W Engineer
Akebono Soft Technologies
aleem_abdul@akebonosoft.com.
|
|
|
|
|
Hi,
I believe 'mm' format Specifier is for Minute.
Try use 'MM' for month instead of 'mm'. Hopefully it gives you the right value
Regards,
Jay
|
|
|
|
|
this is in c# u convertthis into vb and try this will work,
string s=myDT.ToString("dd")
if u have msdn in ur pc look for "DateTimeFormatInfo Class"
|
|
|
|
|
Iam searching for an online exam code using c#.NET or ASP.NET and this application read Questions randomly from a list of questions Stored in database like MSSQL2000
PLZ any one can help me to find this application because I Know this type of application available and done by professional programers like members of this Forum
|
|
|
|
|
Its not one or couple lines of code you will have to divide it into different tiers Such UI,Bussiness and Datbase -
Start from Scraching means collect all information then decide what you want then start from DataBAse or UI ?
|
|
|
|
|
No need to start new thread about the very same topic. There is modify button (or you could write another post) if you think you didnt express yourself well at previous thread.
Take a look at http://www.codeproject.com/aspnet/xmlquiz.asp[^]. It's in ASP.NET 1.0 but could be helpful.
"Throughout human history, we have been dependent on machines to survive. Fate, it seems, is not without a sense of irony. " - Morpheus
|
|
|
|
|
i want some one help me to get online exam application by asp.net
|
|
|
|
|
Help in what way ? Do you want to write one? Go ahead, ask us when you have a specific question. Do you want to download one ? Search for one with google.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
|
OK - good luck.
Your question is too broad to answer. Do you know ASP.NET ? What have you written before ? Like I said, you need to ask specific questions. there's no way anyone can answer this one.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
Hi all,
This is Hari,
In my application I need to generate a report for different people and send it through mail as attachment, and my approach to this task is I will generate a report for single person ,And send it to his Mail ID and then I will delete the report and generates next person’s report and send it.
To send the report I am using SMTP server. I am able to send the mails if all the mail ids are correct, if the mail id of a person is incorrect in between I am able to handle the exception but I am not able to delete the report of that person the error I am getting is "Internal system error. Access to the path.... "Even I am not able to delete the file manually .How can I come out of this please help me.
Thamk
Harikrishna.H
hari@eilisys.com
|
|
|
|
|
Hi Hari,
Try to delete that file in "Finally" block of Try-Catch.
Trish
|
|
|
|
|
Hi,
I'm creating a search page with multiple fields to be searched. Some are textbox, some are drop-downlist.
I wrote a code to add in the select parameters to the sqlDataSource when a field is search. However, no result is being shown in the gridview.
The code is shown below, please advice on any mistakes I have made:
<pre>
Protected Sub Submit_Button_Click(ByVal sender As Object, ByVal e As System.Web.UI.ImageClickEventArgs)
Dim strSQL2 = ""
SqlDataSource1.SelectParameters.Clear()
If emp_id.Text <> "" Or name.Text <> "" Or country.SelectedItem.Value <> "" Or city.Text <> "" Or nearest.Text <> "" Or status.SelectedItem.Value <> "" Or agent.SelectedItem.Value <> "" Then
strSQL = "SELECT E.id, E.status, E.name as E_NAME, E.country, E.city, E.nearest1, E.nearest2, E.nearest3, E.nearest4, E.nearest5, E.email, E.mobile1, E.mobile2, E.home_no, E.msn, E.skype, E.moneybookers, E.agent_id, A.name as A_NAME, E.notes, E.suspend FROM employee as E left join employee as A on E.agent_id=A.id where "
If emp_id.Text <> "" Then
strSQL2 += "E.id=@id and "
SqlDataSource1.SelectParameters.Add(New Parameter("id", TypeCode.String, CType(emp_id.Text, String)))
End If
If name.Text <> "" Then
strSQL2 += "E.name=@name and "
SqlDataSource1.SelectParameters.Add(New Parameter("name", TypeCode.String, CType(name.Text, String)))
End If
If country.SelectedItem.Value <> "" Then
strSQL2 += "E.country=@country and "
SqlDataSource1.SelectParameters.Add(New Parameter("country", TypeCode.String, CType(country.SelectedItem.Value, String)))
End If
If city.Text <> "" Then
strSQL2 += "E.city=@city and "
SqlDataSource1.SelectParameters.Add(New Parameter("city", TypeCode.String, CType(city.Text, String)))
End If
If strSQL2 <> "" Then
strSQL += Left(strSQL2, Len(strSQL2) - 5)
Else
strSQL = Left(strSQL, Len(strSQL) - 7)
End If
SqlDataSource1.SelectCommand = strSQL + " order by E.name"
SqlDataSource1.DataBind()
Response.Write(SqlDataSource1.SelectParameters("city"))
Else
strSQL = "SELECT E.id, E.status, E.name as E_NAME, E.country, E.city, E.nearest1, E.nearest2, E.nearest3, E.nearest4, E.nearest5, E.email, E.mobile1, E.mobile2, E.home_no, E.msn, E.skype, E.moneybookers, E.agent_id, A.name as A_NAME, E.notes, E.suspend FROM employee as E left join employee as A on E.agent_id=A.id order by E.name"
SqlDataSource1.SelectCommand = strSQL
SqlDataSource1.DataBind()
End If
End Sub
<asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:rbdbConnectionString %>"
ProviderName="<%$ ConnectionStrings:rbdbConnectionString.ProviderName %>" >
</asp:SqlDataSource>
</pre>
|
|
|
|
|
asugama wrote: However, no result is being shown in the gridview
If no compilation error, just check your query and your database...
<< >>
|
|
|
|
|
I have used some javascript functions and css styles. now the problem is that all these functions and javascript is working properly with Internet Explorer but not with Mozilla Fire Fox.
Want to know the way sothat my functions and css work with others as well.
Plz give me some solution ASAP
With Thanks & Regards
Amit Sk Sharma
|
|
|
|
|
And of course we are all psychic enabling us to see the script and styles causing the problems......
|
|
|
|
|