309 Posted Topics
Re: U can paste ur solution so that it would be helpful for someone else who need the same.... | |
Re: u can also try to first clear the combo box items before adding the values to it.... | |
Re: Not enough....be more clear and precise.... | |
Hello Friends, I need help to get the time value from MSSQL database to VB.Net Datetimepicker I have a datetimepicker but the custom format is set to HH:mm tt so that I can get eg 11:20 AM this value I have stored in database with the help of ` Label4.Text … | |
Re: Please explain in details.... when are u getting this error?? what is the object related to this error??? | |
Re: After else if u need to mention the condition and then continue with the code....if no condition is present then just use else show the exact code what u have done after adam_k has post so we can help u more on it... | |
Re: you forgot the word Add.... it shud be Listview1.Items.Add and then the reader.... Try Dim myCommand As SqlCommand myCommand = New SqlCommand("SELECT * FROM DoctorRegister ", Connection) Dim reader As SqlDataReader = myCommand.ExecuteReader While reader.Read ListView1.Items.Add(reader.Item("FirstName")).Selected = True End While Catch ex As Exception MsgBox(ex.Message) End Try selectedItem is not … | |
Re: set a masked Text box and set the mask as 00,000,000 and the database datatype can be varchar to retrieve this data....hope it helps u.... | |
Re: For deleting data with the help of datagridview and updating in access u can use 'Open connection Dim i As Integer Dim ID As String i = DatagridView1.CurrentRow.Index ID = DatagridView1.Item(0, i).Value 'whichever will be primarykey or unique data Try Dim MessageText As String Dim myCommand As OleDbCommand myCommand = … | |
Re: The above query will show BidTime as Desc and BidAmount as Asc.... But according to the criteria 1. Assign Highest Rank of based on Max BidAmount. 2. If Bid Amount gets tie with other user then who ever enter bid amount first he will get the high Rank So just … | |
Re: Are you looking for this?? Private Sub DataGridView1_CellClick(sender As Object, e As System.Windows.Forms.DataGridViewCellEventArgs) Handles DataGridView1.CellClick Dim i As Integer i = DataGridView1.CurrentRow.Index Form1.TextBox1.Text = DataGridView1.Item(1, i).Value.ToString Form1.TextBox2.Text = DataGridView1.Item(2, i).Value.ToString End Sub Ohhh...sorry...this code is in vb.net.... | |
Re: Whatever Jim has given it works...add few more lines of code Private Sub Button7_Click(sender As System.Object, e As System.EventArgs) Handles Button7.Click 'checked on button click Dim found As Boolean = InListView(ListView1, ComboBox1.Text) If found = True Then MsgBox("Exists") Else 'MsgBox("No") ListView1.Items.Add(ComboBox1.Text) End If End Sub Private Function InListView(lvw, text) As … | |
Re: Please explain ur problem in detail....only showing the code might not help.... | |
Re: I guess if u post this in ASP.net u might get some help.... | |
Re: if u want a clear cell that use "" instead of Test4... It will be good enough if u be more specific....n number of people will be able to help u.... | |
Re: Duplicate thread [Click Here](http://www.daniweb.com/software-development/vbnet/threads/423693/windows-form-applications-vb..-please-help) | |
Re: the below thing I had done in my change password code...check if this helps u.... this code I had written in a button click event.... 'Open connection If txtUName.Text = "" Or txtOldPwd.Text = "" Or txtNewPwd.Text = "" Or txtCNPwd.Text = "" Then MsgBox("All fields are mandatory") Else If … | |
Hello Friends, I need to create a report for my project I am using Miscrosoft Visual Studio 2010 and the SAP crystal Report I am not able to set up the connection The SQL server that I am using is not coming in the drop down of the server part … | |
Re: Hey thanks...it worked perfectly fine...even I needed the same....Thanks _avd | |
Re: you can create a module and then call the module whenever u need a database connection.... this will help you to update the changes in your database only once if u need to change it anytime in future,,,,else u need to change in each and every line if u dont … | |
Re: to pass the value in combo box u can use.... Dim conn As New SqlConnection(ConnectionString) Dim strSQL As String = "your sql query" Dim da As New SqlDataAdapter(strSQL, conn) Dim ds As New DataSet da.Fill(ds, "Tablename") With ListBox1 .DataSource = ds.Tables("Tablename") .DisplayMember = "ColumnName" 'column name to be displayed in … | |
Re: write below code in ur button click event textbox2 is the field where u will enter number MsgBox(ConvertNum(TextBox2.Text)) Then write the below function Public Shared Function ConvertNum(ByVal Input As Long) As String 'Call this function passing the number you desire to be changed Dim output As String = Nothing If … | |
Re: select a.item_number, a.itemdesc,c.colordescription,m.monthdescription from article a, colors c , month m where a.colornumber=c.colornumber and a.monthnumber=m.monthnumber | |
Re: Please post the query in Database section....This is VB.net section | |
Too weird but still I have a doubt.... I have two table.... -> OutpatientDetails -> InpatientDetails But the fieldnames are same except for the ID....i.e. OutPatientID and InPatientID respectively..... I want to combine both the tables and produce one output.....I dont know whether it is possible or no.... I want … | |
Re: Can u please show ur save event?? | |
Re: Write the event in combobox1 selectediIndex change event...make correct connections Try Dim myCommand As New SqlCommand With myCommand .CommandText = "SELECT ordernumber,orderdate,itemname,quantity,RepairNumber FROM orderstable WHERE OrderNumber = '" & ComboBox1.Text & "'" .CommandType = CommandType.Text .Connection = conn End With Dim dt As New DataTable dt.Load(myCommand.ExecuteReader) With DatagridView1 .AutoGenerateColumns = … | |
Re: Can u show us ur code so that we can find out where u are going wrong.... | |
Hello Friends, I need to develop a birthday reminder form in my project.... The list of all patient that are celebrating birthday on that particular day and month...leaving the year.... My database is SQL server and I have used date datatype for it.... So I can I get the month … | |
Re: try the below text for all the textboxes keypress event... 'accepts only numbers If (Microsoft.VisualBasic.Asc(e.KeyChar) < 48) Or (Microsoft.VisualBasic.Asc(e.KeyChar) > 57) Then e.Handled = True End If If (Microsoft.VisualBasic.Asc(e.KeyChar) = 8) Then e.Handled = False End If This will be too lengthy I guess...coz u will have to code for … | |
Re: use a masked textbox and set the setmask property accordingly | |
Re: if user clicks on X button call the save_click event in the form_formclosing event.... before that u can ask the user with a msg box whether the user wants to save the form or just close without saving.....if user wants to save call the save event else dispose the form... … | |
Re: Try using masked text box and set the setmaskproperty as you want | |
Re: Try if the below code works fro u.... con.Open() cmd = New SqlCommand("SELECT COUNT(*) FROM IssueMBA WHERE ida='" + TextBox1.Text + "' and rda='" + TextBox2.Text + "'", con) 'here u are giving and condition and not between check one.... dr = cmd.ExecuteReader() If Not dr.Read() Then MsgBox("Invalid details") Else … | |
Re: if these are the only fields in ur table client then y use the field name just use the parameters one mistake is u shud use datetimepicker1.value and not text Give a try Try Dim ConStr As String = "Provider=Microsoft.Jet.OLEDB.4.0; Data Source = C:\projet.mdb" Dim Save As OleDbCommand Save = … | |
Re: Is fullname alos a columnname in the table or just an alias u r giving to the concatenation of fname and lname if it is a column name then I guess it wont go into the column else if it an alias then try below code SELECT DISTINCT DEV_user_registration.reg_fname + … | |
Re: Dim b As Integer = CInt(TextBox2.Text) Dim c As Integer = CInt(TextBox3.Text) Dim a As Integer = b * c MsgBox(a) | |
Re: SO how do u want to display the date difference??? in months, year or days??? whatever parameter u will give in the date diff function it will be dependent on that.... | |
Re: When I added ur block of comment in eclipse and tried to execute it ...it showed a lot of errors for variables like total_ot_income is not resolved and many so on.....One closing brace bracket is missing at the end also...try to paste the complete code again and also the error … | |
Hello Friends... I need help on regular expressions.... I tried the following way but it did not work for me....please help me to create a regular expression... ^.*(?=.{8,})(?=.*\d)(?=.*[a-z])(?=.*[A-Z])(^[a-zA-Z0-9@\$=!:.#%]+$) My requirement is -> Min 8 to 15 characters - this I will do with the length validation or by including in … | |
Re: check if ur form2 dataset is returning any rows or no..... | |
Re: U can directly use the text boxes instead of using property just giving an example If I want a value from form1 to form2 then I use following way code in form1 Textbox1.Text=Form2.Label1.Text In this way it wont open a new form....In your code u have used > Dim obj … | |
Hello Friends, I have three table ->PatientDetails ->ParentDetails ->InsuranceDetails -Patient id is the common column in all the three tables... While saving the data in table using VB.Net there is a column in PatientDetails i.e. Insured If the patient is insured then only the values from text boxes and the … | |
Re: [QUOTE=collin_ola;1780471]Hi, I have a form in VB which is scrollable (using autoscroll) and when I currently click 'print', it only prints what I can see; it takes a screenshot of the viewable information. Here's my code: [CODE]Private Sub btnPrint_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnPrint.Click Dim settings … | |
Re: what type of database are u using....coz the query is different in SQL and access | |
Re: Is your splash screen the startup form??? if so try to make it as `visible= false`.... if it is a start up form and u try to close the splash screen then the complete application will exit,,, ![]() | |
Re: to display data in the datagrid use the below code and then call the method with datagridview Note- in select query call only the fields that u want to display in your datagridview1 Public Function GetData() As DataView 'open connection Dim SelectQry = "SELECT * FROM Pricelist WHERE [SECURITY] ='" … | |
Re: Please can u explain more in detail | |
Re: TextBox1.Text = DateTimePicker3.Value + " " + DateTimePicker4.Value Note - DateTimepicker3 has date and Datetimepicker4 has time in it....the value will be displayed in textbox4...and the datetimepicker values are separated by a space check if u needed the same.... |
The End.