|
this is the day 'Mon Jun 08 15:19:42 CEST 2009'
and the error i have is while doing Convert
|
|
|
|
|
try this plz[^]
Education is not a way to escape poverty — it is a way of fighting it.
|
|
|
|
|
i have used webparts in my application where the data is stored in the app_data...now iam having users where their data abt username and password are there in sql server 2005 how can i implement personalisation on for the users ...any examples related sql server 2005 and oracle personalisation
Thanks in advance
|
|
|
|
|
hi Friends,
I want to generate options available for login id like Gmail, yahoo when the desired login id not available.
Is there any way to do this ?
|
|
|
|
|
Deepak Nigam wrote: I want to generate options available for login id like Gmail, yahoo when the desired login id not available.
Take the user input, match with the user entry with DB. You can use Ajax with it.
|
|
|
|
|
This [^]should help
Manas Bhardwaj
Please remember to rate helpful or unhelpful answers, it lets us and people reading the forums know if our answers are any good.
|
|
|
|
|
get the user data. Compare it with the database. If already exist give the error. Or let it proceed.
|
|
|
|
|
Hi folks,
I am new to ASP.Net development as such, so my questions can be really stupid. Thanks a ton in advance and pointers greately appreciated
The problem:
For Web Farm setup, we are trying to keep the session data in State Server. We have marked the objects as [Serializable] to make them fit in State Server.
Now, we keep some of the data bjects in session and we are also keeping threads that operate on these objects in session.
The class looks like:
[serializable]
Class DataManager {
Data1 data1Obj;
Data2 data2Obj;
[nonserialized]Thread m_thread;
[nonserialized]AutoResetEvent m_event;
[nonserialized]Thread m_updateThread;
.....
}
Now we are getting exception as threads and events are non-serializable when we run the program. We added the attribute [nonserialized] to these individual thread variables and events. But the strange thing is, once we allocate the threads and start them, some how the thread objects are set to null. I guess this happens after one serialization operation. So imaginge, the program is continuously stuck on checking the thread null and allocating it again. This obviously is not working at all.
// the code looks like
void somefunction()
{
if (m_thread == null)
{
RespawanThread() // this happens all the time
}
}
My question is even after adding the [nonserialized] tag to the individual thread members, what makes them null after some time?
Evil triumphs when good people sit quiet...
|
|
|
|
|
You can't keep a thread active in session. When you store data in session, you are simply saving XML in memory. Your class is written out as XML and then when you deserialize it, a new instace is created and the values of properties are retreived from the XML.
Also, from my experience, you do not want to keep a thread alive between postbacks. It is a bad idea. The reason being is that the client can abrubtly disconnect and it is not always possible to fire an event in your server code when that happens.
I didn't get any requirements for the signature
|
|
|
|
|
How to write code for Dynamic Radio buttons events in asp.net .
Here I'm geting data from database .
My project Flow is:
Step1:Select Location In DropDownlist box
Step2:Display The various cuisines in RadioButton.
Step3:When ever I select Radiobutton it's not perform event.
Please Give Me solution as early as possible..
i'm using ASp.NET/C#
Thank you..
Kantharao
modified on Tuesday, June 23, 2009 9:02 AM
|
|
|
|
|
Your dynamic controls will only fire events if they are created before page load, otherwise, viewstate is not restored for them.
Christian Graus
Driven to the arms of OSX by Vista.
"! i don't exactly like or do programming and it only gives me a headache." - spotted in VB forums.
I can do things with my brain that I can't even google. I can flex the front part of my brain instantly anytime I want. It can be exhausting and it even causes me vision problems for some reason. - CaptainSeeSharp
|
|
|
|
|
kantharao wrote: How to write code for Dynamic Radio buttons events in asp.net .
Here is the code:
protected void Page_Load(object sender, EventArgs e)
{
RadioButton rbt = new RadioButton();
rbt.CheckedChanged += new EventHandler(rbt_checked);
rbt.AutoPostBack = true;
//create a panel in design.
Panel1.Controls.Add(rbt);
}
protected void rbt_checked(object sender, EventArgs e)
{
Response.Write("hi");
}
|
|
|
|
|
I have a webpart and dropdown property and user can select value1 or value2 .If user select value1 ,webpart1 will be added else webpart2 will be added with their properties(configable).How do I resolve this problem?
|
|
|
|
|
magicFire wrote: I have a webpart and dropdown property and user can select value1 or value2 .If user select value1 ,webpart1 will be added else webpart2 will be added with their properties(configable).
You mean you want to add web parts based on User selection from Drop down ?
|
|
|
|
|
Yes I want dropdown property allow user select which web part is loaded?
|
|
|
|
|
Protected Sub chkSelect_CheckedChanged(ByVal sender As Object, ByVal e As EventArgs)
Dim chkTest As CheckBox = DirectCast(sender, CheckBox)
Dim grdRow As GridViewRow = DirectCast(chkTest.NamingContainer, GridViewRow)
Dim txtname As TextBox = DirectCast(grdRow.FindControl("txtName"), TextBox)
If chkTest.Checked Then
txtname.ReadOnly = False
txtname.ForeColor = System.Drawing.Color.Black
Else
txtname.ReadOnly = True
txtname.ForeColor = System.Drawing.Color.Blue
End If
End Sub
|
|
|
|
|
KhandelwalA wrote: Dim txtname As TextBox = DirectCast(grdRow.FindControl("txtName"), TextBox)
Did you check textbox object here?
Did you searched google for it? This is the one of the common error message.
|
|
|
|
|
you have to find the row in which the textbox is present. I am not familiar with VB so i written the code in C#
for(int i=0;i < GVLeads.Rows.Count;i++)
{
TextBox txt = (TextBox)GVLeads.Rows[i].FindControl("TextBox2");
txt.ReadOnly = true;
}
//convert it to VB it iwll work fine
modified on Tuesday, June 23, 2009 6:42 AM
|
|
|
|
|
thanks for ur reply..........but i want to know what is basic reason behind this kind of error.......it comes many times...........can u explain me plzzz??
|
|
|
|
|
|
yes, the object reference error comes as per your coding is you have multiple rows in the grid, But you have not mentioned in which row the textbox is presented. YOu can just see in your code itself.
//instead of this:
Dim txtname As TextBox = DirectCast(grdRow.FindControl("txtName"), TextBox)
//use this
Dim txtname As TextBox = DirectCast(grdRow.Rows[0].FindControl("txtName"), TextBox)
txtname.ReadOnly = False
//for this only the first row of the grid textbox will be readonly = false.
//if you want for all the rows then put for loop
for(i=0;i < grdRow.Rows.count;i++)
{
Dim txtname As TextBox = DirectCast(grdRow.Rows[i].FindControl("txtName"), TextBox)
txtname.ReadOnly = False
}
//I hope you understood now
|
|
|
|
|
|
its still giving me the same error..... .....plz help me
|
|
|
|
|
send me the code wat you are using now
|
|
|
|
|
Protected Sub chkSelect_CheckedChanged(ByVal sender As Object, ByVal e As EventArgs)
Dim chkTest As CheckBox = DirectCast(sender, CheckBox)
Dim grdRow As GridViewRow = DirectCast(chkTest.NamingContainer, GridViewRow)
Dim txtname As TextBox = DirectCast(grdRow.FindControl("txtName"), TextBox)
If chkTest.Checked Then
txtname.ReadOnly = False
txtname.ForeColor = System.Drawing.Color.Black
Else
txtname.ReadOnly = True
txtname.ForeColor = System.Drawing.Color.Blue
End If
End Sub
|
|
|
|