800 Posted Topics

Member Avatar for Begginnerdev

Hello my fellow Daniwebers! I am having some problems wrapping my head around the task sorting a List(Of CustomType) I have a list containing a custom class. The class contains Two DateTime objects, Start and End. I am trying to sort the list descending so that the shortest timespan will …

Member Avatar for Begginnerdev
0
450
Member Avatar for Ancient Dragon

I am not aware of a way to set the location of a message box, but you can create a custom dialog box to fit your needs. I have a custom dialog written in WinForms that has a multiline textbox for the data. (Acts just like a JIT messagebox) Would …

Member Avatar for TnTinMN
0
2K
Member Avatar for pratik65

Is this exception thrown from a client or the dev machine? If this is from the client, you need to install Crystal Reports.

Member Avatar for john.knapp
0
364
Member Avatar for fabio.bozzo

You could cheat a little and create buttons for each take picture, then hide them. Then create one more button, and on that button.click event call the: [CODE] Camera1Button.performclick Camera2Button.performclick [/CODE] ect.... They wont be EXACTLY the same time, but they will be extremely close.

Member Avatar for vince8290
0
533
Member Avatar for Krokcy

An IP with the prefix octet of 192 is always a private IP Address. You will have to assign the server a static (unchanging) ip for outside users to be able to connect. [Here](http://whatismyipaddress.com/dynamic-static) is some material for you to read/research.

Member Avatar for Krokcy
0
288
Member Avatar for hhm_pro992

You will need a for statment to cycle through the listview. (This only works where a unique value is present for each entry.) (Like an ID Column) 'This assumes that the CODE field is unique to each database entry!! For Each li as ListViewItem In ListView1.Items With OleDa .DeleteCommand = …

Member Avatar for Begginnerdev
0
586
Member Avatar for Begginnerdev

I have a question. Does anyone know of a way to scan an image into vb.net, and then save that image as a multipage tiff? I would need a redistributable. I have been looking for a library that will do this, but every one I have found does not meet …

Member Avatar for Begginnerdev
0
3K
Member Avatar for G_Waddell
Member Avatar for ponkhiraj

A label does not have a MaxLength Property, but it would probably be safe assumtion that it's a 32bit integer number. So a label would have 2^32 maximum characters. (4294967296 possible characters) **EDIT** [Here](http://vbcity.com/forums/t/76219.aspx) is a link that leads to an article with a custom marquee control.

Member Avatar for tinstaafl
0
188
Member Avatar for mattwagner

Try [CODE] SQLstr = "INSERT INTO Users (Username,Password) VALUES '" & txtUsername.text & "','" & txtPassword.Text & "'" [/CODE]

Member Avatar for adam_k
0
7K
Member Avatar for zalen17

We are not here for home work help. If you have some code of your own that you are needing help with- post it. Other than that, we are NOT going to do your homework for you. How are you going to learn when someone does it for you?

Member Avatar for zalen17
0
118
Member Avatar for tendaimare

What you could also do is: [CODE] 'Set the indexes of the controls, then use this code: 'Capture the enter key and go to next control Where i is the index of the control Me.Controls(i).Focus() [/CODE]

Member Avatar for safrans
0
3K
Member Avatar for fkatan

Talk about bringing back dead threads... You have less or to many columns in your insert. If less on purpose, you will have to set the values to their columns. Example: Dim sqls As String = "INSERT INTO table (column1, column3, column4) VALUES ('val1','val2,'val3')

Member Avatar for harsh01ajmera
0
3K
Member Avatar for Matigo

You can try py2exe and call the exe from the vb.net application. Example: Process.Start("pathToMy.exe")

Member Avatar for Matigo
0
237
Member Avatar for adam.n.halpin

You can try something like this: For i = 0 To ComboBox1.Items.Count - 1 e.Graphics.DrawString(ComboBox1.Items(i), PrintFont, Brushes.Black, horizontalPrintPosition, verticalPrintPosition) 'Leave some space for the next item. verticalPrintPosition += 5 Next

Member Avatar for Begginnerdev
0
221
Member Avatar for manoj323

[Here](http://social.msdn.microsoft.com/Forums/en-US/Vsexpressvb/thread/7aa77ef3-1341-4aeb-bd6b-b1d737ae30be) is some one with a solution to this problem.

Member Avatar for Begginnerdev
0
65
Member Avatar for Neethaa
Re: code

You will want to look into [this.](http://www.connectionstrings.com/)

Member Avatar for xerohomicide
0
128
Member Avatar for thomas.weatherill.5

Try handling it with an inline if statment: If txtUsername.Text = IIF(IsDBNull(ds.Tables("AddressBook").Rows(inc).Item(1)),"",ds.Tables("AddressBook").Rows(inc).Item(1)) Then 'Do Work End IF It is possible that you are returning a null entry from the database, thus throwing a NRE. By using this inline if, you return "" for null (not throwing a NRE) and can …

Member Avatar for Begginnerdev
0
229
Member Avatar for joshl_1995

You will have to add the dll reference to your project, import it, instantiate a variable of the form's class, and then call the forms Show() sub.

Member Avatar for Begginnerdev
0
294
Member Avatar for khair.ullah

First of all: Whoa! That formatting was terrible. Second of all: Try something like this: Dim cmd as New OleDbCommand("DBCC CHECKIDENT (YOUR_TABLE_NAME_HERE, RESEED, 0)",YOUR_CONNECTION_HERE) cmd.ExecuteNonQuery 'This will reseed the table and set the identity back to 0

Member Avatar for Begginnerdev
0
129
Member Avatar for Stuugie

You can do something like this: Dim di As New IO.DirectoryInfo(YourDirectoryHere) Dim diar1 As IO.FileInfo() = di.GetFiles() Dim dra As IO.FileInfo For Each dra In diar1 If dra.Extension = ".csv" Then 'Do Work End If Next

Member Avatar for Stuugie
0
180
Member Avatar for Riteman

Can you post an image of the GUI. I am having a hard time visualizing what you are doing.

Member Avatar for Riteman
0
109
Member Avatar for khair.ullah

You can try something like this: Private Sub AddControls(ByVal lstControls As List(Of Control), ByVal tpgDestination As TabPage) Try If IsNothing(lstControls) = False Then For i = 0 To lstControls.Count - 1 tpgDestination.Controls.Add(lstControls(i)) Next End If Catch ex As Exception MsgBox("There was a problem adding the controls!" & vbCrLf & ex.Message …

Member Avatar for Begginnerdev
0
1K
Member Avatar for LD Company

I think [this](http://www.planet-source-code.com/vb/scripts/ShowCode.asp?txtCodeId=8261&lngWId=10) is probably what you want.

Member Avatar for LD Company
0
218
Member Avatar for happygeek

Hello! I seem to have a bit of a problem here. I deleted my old avatar ( to search for one of a better quality ) and now I can not upload the new avatar. Uppon saving the avatar, I receive the error message: "There was a problem moving the …

Member Avatar for Ancient Dragon
0
2K
Member Avatar for lebo.bytes

Are you posting a code contribution, or requesting help? If you are requesting help, it might be wise to ask a question when you post. =)

Member Avatar for G_Waddell
-1
675
Member Avatar for androidz

I have searched for a distributable for the same purpose... It came down to installing CR on the machine.

Member Avatar for androidz
0
211
Member Avatar for iamthwee

Though a little high in cholesterol, shrimp are a great source of protein with low calories. Grilled/Steamed shrimp (3oz) can net about 85 calories with 18g of protein, but with 120mg of cholesterol.

Member Avatar for Mike Askew
0
437
Member Avatar for xcarbonx

Could also do something like this: For Each line As String in System.IO.File.RealAllLines("input.txt") Dim lstData As New List of String lstData = line.Split(vbTab).ToList For i = 0 To lstData.Count - 1 outFile.WriteLine(lstData(i)) Next Next

Member Avatar for xcarbonx
0
331
Member Avatar for lion8420

Make use of the sender object of the form. You can cast the sender to the type of your control. Dim cntrl As New Type cntrl = TryCast(Sender,Type)

Member Avatar for lion8420
0
195
Member Avatar for SH3H@N

Set the form's opacity color / percentage Create a label Set the back color to the opacity color Write the text in the label Set the label location to cursor location

Member Avatar for SH3H@N
0
197
Member Avatar for jhedonghae

Try something like this in your login button's click event: With lviNew .Text = Now.ToShortDateString .SubItems.Add(Now.ToShortTimeString) End With ListView1.Items.Add(lviNew)

Member Avatar for jhedonghae
0
194
Member Avatar for lulu79
Member Avatar for Dili1234

[Here](http://social.msdn.microsoft.com/Forums/eu/vscrystalreports/thread/2f37947e-34da-4459-b17b-c484da40d887) is an article on MSDN that has code to do exactly what you are wanting. Hope this helps

Member Avatar for Begginnerdev
0
1K
Member Avatar for roemerito

You can split the contents of the textbox, storing them in list (of string) and remove the element, then rebuild the string. Example: Dim str As New List(Of String) 'Assuming you are using a , seperator. str = TextBox1.Text.Split(",").ToList str.Remove("test") For i = 0 To str.Count - 1 If i …

Member Avatar for roemerito
0
2K
Member Avatar for jontennyeah

Try something like this: For Each lviItem As ListViewItem In ListView1.Items If lviItem.Text = ComboBox1.Text Then TextBox1.Text = lviItem.SubItems(0).Text TextBox2.Text = lviItem.SubItems(1).Text End If Next

Member Avatar for Reverend Jim
0
185
Member Avatar for ranga.seeman

Kind of simplistic, but you can try something like this; Private Function WeekOfYear(ByVal dt As Date) As Integer Try Return dt.DayOfYear / 7 Catch ex As Exception MsgBox("There was a problem retreiving the week of the year!" & vbCrLf & ex.Message) Return Nothing End Try End Function

Member Avatar for ranga.seeman
0
1,000
Member Avatar for tinu28

Something like this would do the trick: "INSERT INTO destinationTable(Itemname,Itemcode)" & _ "SELECT sourceTable.ItemName, sourceTable.ItemCode " & _ "FROM sourcetable WHERE sourcetable.Column=Value"

Member Avatar for tinu28
0
1K
Member Avatar for paoi00

Try something like this: Dim lviNew As New ListViewItem With lviNew 'NOTE: ' I always assign my unique values to the .Text property. ' This will make it easier to compare against a database. .Text = TextBox1.Text .SubItems.Add(ComboBox1.Text) End With

Member Avatar for Begginnerdev
0
160
Member Avatar for veeeeebeeeee

I am not seeing a handler for the form close event, is something firing off - or is it not being handled? As for currency, try this: txtPrice.Text = CDec(txtPrice.Text).ToString("C") As for the navigation, are you scrolling, or clicking to the next entry?

Member Avatar for Begginnerdev
0
218
Member Avatar for jontennyeah

This is going to sound rude, but are you a student? If so, then you need to listen more in class. .sln A solution file. This is the project file for Visual Studio. This contains the uncompiled project and resources. When you compile and run the project, an executable is …

Member Avatar for Reverend Jim
0
108
Member Avatar for Begginnerdev

Hello! I seem to have a bit of a problem here. I deleted my old avatar ( to search for one of a better quality ) and now I can not upload the new avatar. Uppon saving the avatar, I receive the error message: "There was a problem moving the …

Member Avatar for Begginnerdev
0
122
Member Avatar for jontennyeah

Do you have any code thus far? We can't simply do the work for you. For all that we know, you could be asking for homework "help"

Member Avatar for jontennyeah
0
109
Member Avatar for sean.downes.96

txtNumRows would be the name of your textbox where you want to display the count. The (normal) naming convention for vb.net would be object type|name(camel case) So txt = TextBox Example: Dim sHello As String = "Hello, World!" 'Note the s prefix Dim iCount As Integer 'Note the i prefix …

Member Avatar for Begginnerdev
0
122
Member Avatar for suntec

Don't post on 4 year old threads. Start another thread if you have a question you need to ask.

Member Avatar for Begginnerdev
0
1K
Member Avatar for Shodow

Does your report cycle through the listview's items? If so, just execute the report on the listview's selcted items. Example: For Each itm as ListViewItem in ListView1.SelectedItems 'Do Work Next

Member Avatar for Shodow
0
911
Member Avatar for jontennyeah

If the data is in a database, just execute the statement on every record. Something to the tone of: "UPDATE table SET column='OUT'"

Member Avatar for mikeybware
0
118
Member Avatar for mageamida

Use a masked text box. Just set the mask and it will do the rest for you. [Example](http://msdn.microsoft.com/en-us/library/kkx4h3az.aspx)

Member Avatar for mikeybware
0
180
Member Avatar for mh.cool992

After looking at your code, I do not think that you are receiving this error from this chunk of code. **Possibility** One of your substrings from the listviewitem is a string where you are trying to store Quantity. Can you please give an example of your data. OR Can you …

Member Avatar for Reverend Jim
-1
286
Member Avatar for hhm_pro992

If the quantity is an auto number, it will not be changeable. Other than that, just wrap your values that are strings in the correct casts or 's. Example: 'If quant is an int the listview try Cint(Me.ListView1.Items(0).SubItems(3).Text) 'Or OleDa.UpdateCommand.Parameters.Add("UPDATE [Inventry] SET [QTY] = [QTY] - '" & Me.ListView1.Items(0).SubItems(3).Text & …

Member Avatar for Begginnerdev
0
205

The End.