how can I prevent window1.show() from showing same window multiple times. Are there any command like.. if (window1 exists) don't open window1 thanks Sudeep ====== code proj. rocks!
Sudee
Posts
-
Simple question abt pop-up window -
multiple selection in datagridSreeji, Thank you very much. I appreciate your help. :) ====== code proj. rocks!
-
multiple selection in datagridHello Sreejit, I have used DataGrid_MouseUp() event and then used DataGrid.CurrentRowIndex to get the current row.
private void DataGrid_MouseUp(object sender, System.Windows.Forms.MouseEventArgs e) { int i = DataGrid.CurrentRowIndex; }
But how can I get multiple rows index if I have selected multiple rows. like this>>private void DataGrid_MouseUp(object sender, System.Windows.Forms.MouseEventArgs e) { for (int i = 0; i <= DataGrid.CurrentRowIndexes:confused:; i++) { int j = DataGrid.CurrentRowIndexes[i]; } }
====== Yo need a brain to code. -
multiple selection in datagridRight now I am working with DataGrid.CurrentRowIndex how to do if I have to select multiple rows. Thank you, ====== Yo need a brain to code.
-
DTS packagesI am using sql server to copy data from oracle. So I use DTS to copy a table. What I have done is use DTS Import/Export Wizard. And I have DTS packages which is schedule every day to update table. But the problem is all the data repeats in my new table in sql database instead of updating data. Please give me some hint what I can do? and where can I go to learn abt it. Thank you very much. sudeep ====== Yo need a brain to code.
-
How to insert ' into database?this.SqlConnection = new System.Data.SqlClient.SqlConnection(); cmd = new SqlCommand("INSERT INTO TableName (intColumnA, chrColumnB) VALUES (1,'XYX')",this.SqlConnection); cmd.ExecuteNonQuery(); What exception did you get? ====== Yo need a brain to code.
-
how to bind the textbox value to sqlCommand?cmdSql = New SqlCommand("Select * From Peripheral WHERE PCID='"+Tpcid+"' ", myConnection) I am not sure.. just try once. Sorry if I am wrong. :)- Sudeep ====== You need a head to program. Cool, fast and sharp.
-
How to insert ' into database?http://www.w3schools.com/sql/sql\_select.asp ====== You need a head to program. Cool, fast and sharp.
-
unhandled exceptionAfter doing try catch within the error block I caught such exception: System.Data.SqlClient.SqlException: @dtExpireDate is not a parameter for procedure pr_EditTreatInstrument. at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream) at System.Data.SqlClient.SqlCommand.ExecuteNonQuery() at.... so on and when I excluded @dtExpireDate, then I see exception like System.Data.SqlClient.SqlException: Procedure 'pr_EditTreatInstrument' excepts parameter '@dtExpireDate', which was not supplied. at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream) at... so on Thank you, Sudee ====== You need a head to program. Cool, fast and sharp.
-
unhandled exceptionhi all, I am getting following error.. An unhandled exception of type 'System.Data.SqlClient.SqlException' occurred in system.data.dll. There is no problem with my store procedure as I checked from Query Analyzer. public static void EditTreatInstrument(int Id,string Name,string BarCode,string PDACode,DateTime ExpireTime, int Method ) { SqlCommand cmd = WesServer.GetSqlCommand.Get( Conn , CommandType.StoredProcedure , "pr_EditTreatInstrument" ); cmd.Parameters.Add( GetSqlParameter.Get( "@intId", SqlDbType.Int, Id ) ); cmd.Parameters.Add( GetSqlParameter.Get( "@nvchrName", SqlDbType.NVarChar, Name ) ); cmd.Parameters.Add( GetSqlParameter.Get( "@vchrBarCode", SqlDbType.VarChar, BarCode ) ); cmd.Parameters.Add( GetSqlParameter.Get( "@vchrPDACode", SqlDbType.VarChar, PDACode ) ); cmd.Parameters.Add( GetSqlParameter.Get(" @dtExpireDate", SqlDbType.DateTime, ExpireTime )); cmd.Parameters.Add( GetSqlParameter.Get( "@intMethod", SqlDbType.Int, Method ) ); cmd.ExecuteNonQuery(); } What are the condition when such error can occer ??? Thanks, Sudeep ====== You need a head to program. Cool, fast and sharp.
-
sql statementCREATE PROCEDURE pr_InsertDictTable @intID int, @vchrValue nvarchar(50), @vchrWesBarCode nvarchar(10), @vchrTableName varchar(20) AS declare @sql varchar(1000) set @sql = 'INSERT INTO ' + @vchrTableName + ' (Id, Name, PDACode) VALUES ( '+@intID+','+@vchrValue+','+@vchrWesBarCode+')' print @sql GO Any problem in this procedure? ====== You need a head to program. Cool, fast and sharp.
-
DataBind ArrayList with StructPlease someone look up my code. I want to bind ArrayList to combobox. private class stru { public string ID; public string Name; public stru( string id, string name ) { ID = id; Name = name; } } ... ArrayList a = new ArrayList(); a.Add(new stru("1","Zach")); a.Add(new stru("2","Amin")); comboBox2.DataSource = a; comboBox2.DisplayMember = "Name"; Thank You. Sudeep ====== You need a head to program. Cool, fast and sharp.
-
debuggingsorry! ====== You need a head to program. Cool, fast and sharp.
-
debugginghello, I have created a dynamic textbox in an asp.net and fill the value dynamically. But the value doesn't show up on the page. I think system has overwrite the value on my dynamic textbox. I tried to trace the textbox. But couldn't do it. Can anyone give me the best way to trace the textbox. or if I can set a break point for my dynamic textbox. any suggestion will be appreciated. Thanks, Suds ====== You need a head to program. Cool, fast and sharp.
-
debugginghello, I have created a dynamic textbox in an asp.net and fill the value dynamically. But the value doesn't show up on the page. I think system has overwrite the value on my dynamic textbox. I tried to trace the textbox. But couldn't do it. Can anyone give me the best way to trace the textbox. or if I can set a break point for my dynamic textbox. any suggestion will be appreciated. Thanks, Suds ====== You need a head to program. Cool, fast and sharp.
-
source code problemI have my project file in D drive, and a copy of same project on my C drive, where I used to work before. Now when I try to run project from D drive. some of code behind files link back to C drive, where I have my old project. I know there is some linking problem. but don't know how to fix it. Appreciate any suggestions. thanks ====== You need a head to program. Cool, fast and sharp.
-
LockingDear all, where should I go abt learning locking system? I have a system with a multiple user and sql as database. UI has a multi-layer(or parts) as many users can surf at a time. What I want to do is lock the user on different layers. What is the best way to achieve this? I am very begineer to this. Thank you. ====== You need a head to program. Cool, fast and sharp.
-
datatableI have a DateTime variable. DateTime dt; I want to enter first date value. ( date = "1/1/2004" ) dt = date; then I want to enter time value.(time = "5:AM" ) dt += time; How can I achieve this. Thank you very much. Suds ====== You need a head to program. Cool, fast and sharp.
-
copy data from datatable to htmltableHow can I copy rows from datatable to htmltable. I guess htmltable doesn't support direct index copy. I am creating dynamic htmltable. Is there any easy way to do so? Thank you, Suds ====== Drazzling, Cloudburst and then Sunny Morning.
-
mulitple choice searchhello. Can anyone show me how can I do multiple choice searching in a table? I am writing store procedure. Suppose there are 3 search options on a page. store procedure searching @a int, @b int, @c int as select a,b,c,d,e from grandtable where a=@a and/or bhal bhal bhal I am a very begineer for SQL. thank, Sudeep Some dudes gotta know how to develop a prg. and some dudes just never get it at all.