- Strength to Increase Rep
- +6
- Strength to Decrease Rep
- -1
- Upvotes Received
- 7
- Posts with Upvotes
- 5
- Upvoting Members
- 6
- Downvotes Received
- 0
- Posts with Downvotes
- 0
- Downvoting Members
- 0
94 Posted Topics
hi I want to know how to read from excel file i know how to open it but how to store cell's value from excel to the variable i wrote varname=xlsheet.Cells(1, 1) and i got run timeerror "cast from range to "string not supported
"Never argue with idiots, they'll just bring you down to their level and beat you with experience." :)
i hope this link will help you [url]http://www.vbdotnetheaven.com/UploadFile/aghiondea2/StoringImagesInVB11122005034248AM/StoringImagesInVB.aspx?ArticleID=7ed1fe42-0819-4912-88ae-bbc43829d8a6[/url]
i think you just need to add reference to System.configuration.dll
I am not sure if I understand you well :S do you want to clear the textbox from data when user click some button ? you do like this [CODE]Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click TextBox1.Text = "" [/CODE] and that for all ur …
Add ColorDialog control to the form , then change its property to the way you want it to show . to show the dailog [CODE]ColorDialog1.ShowDialog()[/CODE] you can get the color that user selected by ColorDialog1.Color after this you can set the backcolor of form to this color
Salam... I need to get value that has been selected from combobox .. the values in combobox is taken from column's contents of one of tabel in database..so once i write if x=combobox.selectedvalue..i got error that i Additional information: Operator is not valid for type 'DataRowView' and string
[QUOTE]I am getting an error called 'Data type mismatch in criteria expression'. This only happen when I tried to add an item.[/QUOTE] I think the error means that you have variable from one type and you are trying to store in it value from other type . since you have …
I got 27 [QUOTE]You are an average on-line user. You may surf the Web a bit too long at times, but you have control over your usage.[/QUOTE]
hi MichelleCrews, welcom to Daniweb ! I hope you will enjoy here and learn more to get A :D
i do not understand your code. >>"this the code for button next n previous" you mean that the same code for next and previous ? each one has its own code [CODE] i = 0 [B]For i = 0 To -1[/B] TextBox1.Text = varDataSet.Tables("tbl_rop").Rows([B]0[/B]).Item("Name_User") TextBox2.Text = varDataSet.Tables("tbl_rop").Rows(0).Item("Date_of_birth") TextBox3.Text = varDataSet.Tables("tbl_rop").Rows(0).Item("Hobbies") …
hi every one . does any one know how to insert checkbox in datagrid so user can select row and how to know which rows selected
[QUOTE]plz...m relly need a immediate coding.. plz sumbody solve my probs.. i want to subtract my current quantity stock went m enter any amount at a textbox... currentquantity = fullquantity - amount(type in the textbox) then save to database can sumbody help mee..plzzz[/QUOTE] As Teme64 said open new thread with …
[QUOTE]When i click on the ID field that id should get displayed in the ID TEXT FIELD...[/QUOTE] do you mean display it on TextBox? if yes then use MouseUp event handler inorder to know when user select the cell, and then display the cell content in textbox [CODE]Private Sub DataGrid1_MouseUp(ByVal …
[QUOTE][CODE] Private Sub add(Of T)(ByVal x As T, ByVal y As T) Dim res As T res = x + y MsgBox(res) End Sub[/CODE][/QUOTE] what type T ??
do you get error, or the program run but no change made to database or what ?
it would be better if you post your code any way , I think you didn't convert from string to double before calculating, you wrote like this [CODE] Balance.Text = coursefees - installment1.Text[/CODE] it may work but if user did not enter value and leave the textbox empty then you …
[QUOTE]i have to input number in all textboxes so it gives me a zero in the total. also i have an error coming up its text is not member of double. please help on this.[/QUOTE] sorry but I don't understand the problem , you mean the total is always zero? …
[QUOTE] I just wanna discuss about that difficulty, have some advises and know about difficult that you find or found out to plan yours careers.[/QUOTE] About me I had job interview few days ago , he asked me what your career plan for the next 5 years :S I really …
1/to use image in the form you need [URL="http://www.startvbdotnet.com/controls/gbox.aspx"]PictureBox Control[/URL] 2/in order to change the picture whenever the user select item from the comboBox you use the SelectedIndexChanged event, you can get the item that user selected by [CODE] dim selectedItem as string selectedItem = ComboBox.Text [/CODE]
there are many good tutorials in net like [URL="http://www.homeandlearn.co.uk/NET/nets12p4.html"]this [/URL] and [URL="http://www.itwriting.com/pcw/vbdotnetdata.php"]this[/URL] you can search for more and it will help you to come up with your code if you need help you can ask here
to read from file line by line you need to use ReadLine method as you did , plus checking if you reached the end of file or not by Peek method [CODE]While loadf.Peek <> -1 Line = loadf.ReadLine() ... ... End While[/CODE] [QUOTE]Please just give me the code to read …
[QUOTE][CODE]Public Sub save(ByVal sav As Double) If sav= 0.0 Then Console.WriteLine("Is not valid") Else mainsave = sav End If[/CODE] [/QUOTE] what I understand that the user will enter the value in textbox , after you check that user did not leave it empty you can use it . [CODE] Dim …
you will need dataAdapter and dataset by using dataset you can [B][I]update[/I][/B] the value of any cell in database [CODE]Me.DataSet11.Tables("Table_Name").Rows(0).Item(1) = TextBox1.Text[/CODE] this will not update your databse , to change it you must write [CODE]Me.OleDbDataAdapter1.Update(Me.DataSet11)[/CODE] inserting new row is like updating, you first add new row into dataset then …
first thing you need to store the special characters in [URL="http://www.startvbdotnet.com/language/arrays.aspx"]array [/URL], so you will declear array [CODE]Dim SC(36) As char[/CODE]after that store values [CODE]SC(0) = "Ï" SC(1) = "Î" .......[/CODE]2-go through the user's string using For loop and for each character in user's string ,which you can get by …
[CODE] If myGuess = randNum Then[/CODE] here you compare between [I][B]integer[/B][/I] and [I][B]class Random [/B][/I] to solve this [CODE]If myGuess = randNumGenerated Then[/CODE] same thing in the "<" and ">" but you need to define randNumGenerated as global variable I think.. any way your game is hard :S at least …
[QUOTE]My Question is should I create a database first...if yes then how and with what? if No then what i`m suppose to do...?[/QUOTE] as Jx_Man said you need to have database so you can make it as source of your data you can use Microsoft Access to create it read …
and[URL="http://www.java2s.com/Tutorial/VB/0160__Collections/0220__ArrayList.htm"] this [/URL]is other site now we are waiting your code :)
[QUOTE]How can I declare the InitialValue.text, txtSalvageValue.Text and TxtAssetLife.Text part of this code?[/QUOTE] You do not declare InitialValue.text you just declare variable as textbox. textbox has many properties one of them is text we access properties of InitialValue variable by typing[B] InitialValue[B][COLOR="Red"].[/B][/COLOR][/B] what comes after its property to declear textbox …
[CODE] x = TextBox1.Text.ToCharArray While continue = True And (i < x.Length) If IsNumeric(x(i)) Then y += x(i) Else continue = False MessageBox.Show("Sorry, only numbers allowed") End If i = i + 1 End While TextBox1.Text = y[/CODE] any way I think not allowing user from start to violate the …
[QUOTE]What do I need to do to correct that?[/QUOTE] you need to do as Jx_Man suggest , use Convert.ToSingle
[QUOTE]For i = 0 To fLen1 - 1 snglRead1(i) = br1.ReadSingle() 'EXCEPTION thrown right here Next[/QUOTE] maybe you trying to read while you reached the end of file , [QUOTE]fLen1 = f1.Length[/QUOTE] i think this return length on byte , try this [CODE]fLen1 = Int(f1.Length / 4)[/CODE]
i hope [URL="http://www.vbdotnetheaven.com/UploadFile/tameta/DataGridControl04112005012947AM/DataGridControl.aspx"]this artical [/URL]will help you
to know which row is selected use this [CODE]DataGrid1.CurrentRowIndex [/CODE] to show the value of first column in text box [CODE]Me.TextBox1.Text = DataGrid1.Item(DataGrid1.CurrentRowIndex, [B]0[/B])[/CODE]
u mean how to play flash movie in vb.net ? add Shockwave Flash Object from COM Component ( by right click on tool box -->>Add/Remove Items -->> COM Component tab --->> Shockwave Flash Object) then drag the item that will appear in tool box to the form on play button …
see [URL="http://www.daniweb.com/forums/thread72816.html"]this link [/URL]for adding flash file
[CODE]YourString.Substring(0, YourString.IndexOf("have"))[/CODE] but you must handle what if "have" does not exist , i think it will give you error
[QUOTE]Dim intListIndex As Integer[/QUOTE]what i understand from your code that intListIndex is integer , so you can not write intListIndex.SelectedIndex to print only what the user select try this [CODE] e.Graphics.DrawString(lstProducts.SelectedItem, fntPrintFont, Brushes.Black, sngX, sngY) [/CODE]
i am not sure if i understand you . any way to check mandatory fields , check they not empty for example if user must enter ID in textbox check it like this [CODE] if Id_textbox="" then Label1.Text = "you must enter the ID" end if [/CODE] about confirming exit …
i did not understand why u use For loop , do you want to show [B]all [/B] the array's content in one label ? if yes then [CODE]For subscript As Integer = 0 To [B]3[/B] ratesLabel.Text =[B]ratesLabel.Text[/B]+ " "+ rates(index).ToString Next subscript[/CODE] if you want to show only one rate …
[URL="http://www.devcity.net/Articles/102/Articles.aspx?a=ViewArticle&ArticleID=102"]this [/URL] is good explanation for what you need
you can use split method in string class [CODE] Dim namepart(3) As String fullname = TextBox1.Text For i = 0 To TextBox1.Text.Length - 1 namepart = fullname.Split(" ") Next TextBox2.Text = namepart(0) TextBox3.Text = namepart(1) TextBox4.Text = namepart(2)[/CODE] you can read more about array [URL="http://www.startvbdotnet.com/language/arrays.aspx"]here[/URL] and about string [URL="http://articles.techrepublic.com.com/5100-3513-6030362.html"]here[/URL]
are you asking about how to loop thru database ? i think like this [CODE]count = Me.DataSet.Table_Name.Count For i = 0 To count - 1 m = Me.DataSet. Table_Name.Rows(i).Item("Column_name") Select Case m Case "Leo" Display image of Leo in Me.DataGrid1.Item(i, 0) . . . etc End Select[/CODE]
as you did here [QUOTE]Dim p As String = rdr(1) If txtPassword.Text = p Then[/QUOTE] you can show the data in lable or textbox [code]textbox1.text=rdr("column_name")[/code]
read [URL="http://www.codeproject.com/cs/webservices/SendSmsThroughWS.asp"]this[/URL] it may help u
>number = number * 4.3 i think that's wrong , you need to add 125,000 to the population grouth each year number=number+(number*4.3) Loop Until count = 200000 other thing why you stop looping untill count=200 000 ?i think you mean number not count
use boolean varaible to indicate if the user enter correct value for each input like this [CODE]If Val(employeeid_txt.Text) > 10 Or Val(employeeid_txt.Text) < 1 Then MessageBox.Show("Employee Id Outwith Range 1 to 10 ", "Please re-enter", MessageBoxButtons.OK) Else [B]correct_EmployeeID=true [/B] End If[/CODE] then if all inputs for user are correct , …
The End.