- Strength to Increase Rep
- +0
- Strength to Decrease Rep
- -0
- Upvotes Received
- 6
- Posts with Upvotes
- 5
- Upvoting Members
- 6
- Downvotes Received
- 0
- Posts with Downvotes
- 0
- Downvoting Members
- 0
33 Posted Topics
Re: In my opinion: If you must to create the instance of your toSend variable before you try to add items. In your code example you try to add items to the null object. | |
Re: Hi, It looks like you are making a lot of hard work. I guess if you are setting datasource for you grid: this.grid.DataSource = table all your changes in the grid is coming to your source. So you don't need to read every time any cells from the grid and … | |
Re: Hi, Correct me if I am wrong. You have created a table, but did not add any columns to that table. Regards | |
![]() | Re: hello, Please use "public" or "protected" for your "x" and "y" variables [CODE] protected int x = 4; [/CODE] Cheers ![]() |
Re: Your code looks good. I think your form can has few containers like Tabs, Group box or something like that. It means you need to find your control in the every container. Cheers | |
Re: Hello, Yes, this is good way. Try one more if you like: [CODE] foreach (DataTable table in dataset.Tables) { //some code } [/CODE] | |
Re: Hello johnnyturbo3, You have got right direction. I have tried to recreate your task. Working very well. [CODE] class MyTabClass:TabPage { public MyTabClass() { TextBox textbox = new TextBox { Width = 100, Height = 25, Left = 25, Top = 25 }; this.Controls.Add(textbox); } } /* call from form … | |
Re: Hello vincezed, Your question is very interesting and very general. It is depending upon many things. Anyway you have to set policy for every role. You application must have userclass and your application should check policy.... Good luck | |
Re: Hello sjn21682, Defiantly you have to serialize your form before close it. Do you do it? Cheers | |
Re: Hello Prashant20, Are you using DataSet? Can you give example of your code for this operation? Cheers | |
Re: Hello Buster2209, That statement should work without any problem. I guess it has another bug. Cheers | |
Re: Hi Game, It happed because you have put "else return" statement after listBox2.SelectedIndex == 0. It means code can't rich second condition. Try using another structure: [CODE] if (listBox2.SelectedIndex == 0) { SelectedIndex0(); } else if (listBox2.SelectedIndex == 1) { SelectedIndex1(); } else { return; } [/CODE] Cheers | |
Re: Hi pamikrom, What do you mean? Are you asking about structure POINT? You can read about structure POINT here: [url]http://msdn.microsoft.com/en-us/library/bk9hwzbw.aspx[/url] Cheers | |
Re: Hello jackabascal, [CODE] private void button1_Click(object sender, EventArgs e) { this.tabControl1.SelectedTab = this.tabControl1.TabPages["Tab2"]; } [/CODE] Should work Cheers | |
Re: Hello Bijaya123, this is my variant: You have to add to your form2 two public properties (for example Field1 and Field2). [CODE] public string Field1{get;set;} public string Field2{get;set;} [/CODE] When you open Form2 you have to add values to properties: [CODE] Form2 frm = new Form2{Field1 = TextBox1.Text, Field2=TextBox2.Text}; .... … | |
Re: Hello penguin22, is ID field in your datatable INT? WHERE statement in your query looks like STRING datatype. [CODE] ... WHERE ID = " + entry.EntryID.ToString(); [/CODE] Cheers | |
Re: Hello again. Same question, Can you show Page_Load() event? Cheers | |
Re: Hello virusisfound, I guess you have to define SQL parameter type before setting value. Please note, [U]value should be "DateTime" type as well[/U]. For example: [CODE] cmd.Parameters.Add("@dt", SqlDbType.DateTime); cmd.Parameters["@dt"].Value = value; [/CODE] | |
Re: Hello jellybeannn, I guess you have to add to Page_Load event couple strings: [CODE] protected void Page_Load(object sender, EventArgs e) { if(!IsPostBack) Populate(); } [/CODE] It should help you. | |
Re: Hello Kalpa23, Sorry I give you reference. I am sure it can help you [url]http://msdn.microsoft.com/en-us/magazine/cc163725.aspx[/url] | |
Re: Hi, Maybe this code can help you. for each _row as DataRow in mySet.Tables("ALC_SECURITY_PERMISSION").Rows msgbox( _row.Item("PERMISSION_BUTTON_ID").ToString()) Next | |
Re: Hello, It seems to me you need to define "event" in your first form and use [CODE] AddHandler firstForm.<EventName>, AddressOf secondForm.<TabSelectProsedure>"[/CODE] You have to run RaiseEvent <EventName> when tab in the first form was selected. Cheers | |
Re: Hello, I am sure this can help you [url]http://msdn.microsoft.com/en-us/library/fk49wtc1.aspx[/url] Cheers | |
Re: Hello, Try this [code]For Each _control As Control In Me.Controls If TypeOf (_control) Is TextBox Then _control.Text = String.Empty End If Next[/code] | |
Re: Hello. You can use few different options. But more common is using Global.asax file. You can define variables for session and you WEB-application. Cheers | |
Re: Hello. Can you show which do you use connection string with your database? Please ensure your connection string is correct. Cheers | |
Re: Hello. You need to install MySql and ODBC driver and use it. Good luck | |
Re: Hope this code can help you. Dim _streamWriter As System.IO.StreamWriter Dim _fileName As String = "fileName.txt" If _table IsNot Nothing AndAlso _table.Rows.Count > 0 Then _streamWriter = New System.IO.StreamWriter(_fileName) For Each _row As DataSet1.EmployeesRow In _table.Rows Dim _string As String = "" For Each _column As DataColumn In _table.Columns _string … | |
Re: Hi. [url]http://www.daniweb.com/forums/thread159832.html[/url] Have a look Teme64 message. It helps you Cheers | |
Re: Hi. Can you explain to me one more time. Do you need to connect to MS SQL 2005 database or Access file? Cheers | |
Re: dim _rows() as DataRow = mDataSet.Tables(TableName).Select("CardNumber = " & cardNumber) if _rows.Lenght > 0 Then ..... else .... end if I Agree. It is very strange to check duplicate after entered to database. You need to do it before. | |
Re: Hi. May be this code can help you. Cheers Dim _table As New DataTable() Dim _connection As New SqlConnection(mConnectionString) Dim _commandText As String = "SELECT ID FROM Biodata WHERE ID = @pid" Dim _adapter As New SqlDataAdapter() Dim _string As String = String.Empty With _adapter .SelectCommand = New SqlCommand(_commandText, _connection) … |
The End.