|
|
Can i have this in English please...
|
|
|
|
|
I am working on a project. In the generated page HTML of my ASP.NET page, I have text boxes that have onchange events that link to javascript functions that link to Ajax PageMethods which goes to my SQL command texts.
For 3 of the 4 cases, my update process works. The only one that isn't working is my "template name" section. Basically, the template name is automatically generated upon the first creation of a record. The page displays this name in the editable text box. My boss gave me an SQL stored procedure that takes the OLD name and the new name. The new name is no problem.
My question is how do I save/recall the old name? I am fairly new at all this. He explained something about a hidden text field, and I found in the code this:
ret &= "<input type=""hidden"" id=""oldtemplatename"" value=""" & templatename & """/>"
This is the generated code. What I believe it is doing is saving the templatename (this is the one that will be changed) into this hidden input field with id oldtemplatename. I don't know what to do to get this variable to my other VB function that gets called through the javascript.
Does anyone follow? Please help
|
|
|
|
|
Use Request.Form["oldtemplatename"] to retrieve it, either that or change the text box to an ASP HiddenField control.
|
|
|
|
|
Hi all,
I want to get conversion of this format 'Mon Jun 08 15:19:42 CEST 2009' to DateTime type.
I explain the problem i'm reading from RSS feed but some of them bring that format of datetime, so my code
m_pubDate = Convert.ToDateTime(DirectCast(xNode.Element("pubDate").Value, String))
Broke for RSS Feeds that bring that format and i'm not able to convert this to DateTime.
Thank you for help
|
|
|
|
|
Post the date what you are getting through the RSS field and do you get any errors while conversion ?
Education is not a way to escape poverty — it is a way of fighting it.
|
|
|
|
|
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??
|
|
|
|