|
how can i get value from a string variable into a textbox?
if (dr.Read() || checkBox1.Checked == true && tb_id.Text == "@ploginname")
{
string strpwd = (string)dr["loginpswd"];
//MessageBox.Show(strpwd);
}
i m saving 'loginpswd' from db into strpwd variable. it is coming properly.
now how can i get value of 'strpwd' into displayed into textbox2?
hoping to get a reply.
thank you.
nekshan.
|
|
|
|
|
textbox2.text = strpwd
Cheers
Navaneeth!!
|
|
|
|
|
|
|
thanx virendra.
whts up? hope to complete dis module in dis week.lets c.
cu soon. tc.
nekshan.
|
|
|
|
|
i m working on xmlwebservices.i have to prepared 3 webservices in 2 days..
|
|
|
|
|
hi
i sucessfully send or rteceive data to parallel port in windows 98
but i cant communicate parallel port in windows XP
|
|
|
|
|
I've never tryed but I think you can find your answere here
|
|
|
|
|
I have a class A and within this class A, I want to have an object of type A. Is this possible ? Do I need to do anything special ?
|
|
|
|
|
i think u can do that
Cheers
Navaneeth!!
|
|
|
|
|
|
Hello,
It's working as long as you not calling " ??? = new A();".
Then you would have a invinit loop!
All the best,
Martin
|
|
|
|
|
I understand..I will not need to do that !
|
|
|
|
|
In asp.net When you bind data to datagrid it automatically assigns the header text of columns with the binding source fields. lets say my first field name is firstName and it displays as it is in the datagrid's column header text.But i want "First Name" instead of firstName.How could i achieve that without introducing some new table or with doing extra work.Keep in mind i dun wanna disturp the order of the colums????
|
|
|
|
|
Go to datagrids property bulider page and set the column header there
Cheers
Navaneeth!!
|
|
|
|
|
well but doing so disturbs the order of binding source columns...lets say i have 3 fields id firstName n lastName and my colum names "ID", "First Name" n "Last Name". After binding it assigns field without any order against ID it binds fiestName field so on n so forth.
|
|
|
|
|
hello every one,
I am unable to close the form on the click event and load event of the form .
please help me:
1) How to close form on click event and load event in c#.
2) How to close the instance of an form in c#
rahul saini
|
|
|
|
|
this.Close();
either this or I don't get your question.
also you can manualy override
protected override void OnClosing(CancelEventArgs e)
{}
method if needed (like if you want user to confirm closing or fire up another method).
|
|
|
|
|
hi
thanks for showing interest
yes i have used
this.close();
but it is closing whole project
i want dat after login
the login window should be closed and mdi form should be opened.
but if me using this.close the whole project is closed
i hav seen an example in which they used
frmXYZ.instance().close();
but i my project their is no instance property for form.
me not understanding wat to do
please help.
rahul saini
|
|
|
|
|
There is some code that opens a window which don't close on parents form close event. Also there is delegate, you could do without it ofc.
public partial class Form4Skaitymas : Form
{
Form4Skaitymas_DataSheet form4ska_dat = new Form4Skaitymas_DataSheet();
public delegate void PassData(string uzs_mod, int uzs_nr, string darbID);
private void Some_method_of_yours()
{
PassData PD = new PassData(form4ska_dat.showData);
PD(mod_nr, part_nr, textBox3.Text);
form4ska_dat.Show();
}
}
// note: I removed most of the code form it and left only the imortant parts, as an example.
|
|
|
|
|
Hi all:
please help me to find a way to kill the processes that appear in the Task Manager from the Code?
I'm using Management Class to view the processes but i need a way to kill each of them.
Thanks
Regards
TaRiQ
|
|
|
|
|
using System.Diagnostics;
Process[] proc = Process.GetProcessesByName("process_friendly_name");
foreach (Process pt in proc)
{
pr.Kill();
}
|
|
|
|
|
Thanks man I appreciate that alot
TaRiQ
|
|
|
|
|
Hello,
The answere you got was correct!
But don't forget to dispose the processes.
pr.Dispose();//in your case
All the best,
Martin
|
|
|
|
|
YEP it's correct..
Thanks alot again
TaRiQ
|
|
|
|