Click here to Skip to main content
15,896,111 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralNew values in My.Settings not used - only when I restart app Pin
Xooku3-Feb-08 20:55
Xooku3-Feb-08 20:55 
GeneralRe: New values in My.Settings not used - only when I restart app Pin
Dave Kreskowiak5-Feb-08 10:21
mveDave Kreskowiak5-Feb-08 10:21 
GeneralRe: New values in My.Settings not used - only when I restart app Pin
Xooku5-Feb-08 18:17
Xooku5-Feb-08 18:17 
GeneralRemote Connection Vb.net to Postgres Pin
nishkarsh_k3-Feb-08 18:01
nishkarsh_k3-Feb-08 18:01 
GeneralRe: Remote Connection Vb.net to Postgres Pin
Mycroft Holmes3-Feb-08 21:25
professionalMycroft Holmes3-Feb-08 21:25 
GeneralRe: Remote Connection Vb.net to Postgres Pin
nishkarsh_k3-Feb-08 22:59
nishkarsh_k3-Feb-08 22:59 
QuestionArrays Pin
Cedrickdeorange3-Feb-08 5:09
Cedrickdeorange3-Feb-08 5:09 
GeneralRe: Arrays Pin
User 2710093-Feb-08 6:09
User 2710093-Feb-08 6:09 
This code works just fine.

I'm not sure what type of control lstPhone is, but this below code will work just fine.

Question: Why are you using a Structure instead of a class?

Question: Why are you using an ArrayList instead of a Generic List(Of Person)? This would provide a type safe collection.

Public Structure Person
  Public First As String
  Public Last As String
  Public Home As String
  Public Work As String
  Public Mobile As String
End Structure

Public Class Class1

  Public Persons As New ArrayList

  Public Sub New()
    Dim p As New Person
    p.First = "hello"
    p.Last = "There"
    p.Home = "555-1212"
    p.Work = "411"
    p.Mobile = "900-555-1212"
    Persons.Add(p)

    ' this will work just fine
    'I'm assuming that lstPhone is a Combo Box or List Box?

    'lstPhone.Items.Add(p.First + " " + p.Last)

  End Sub

End Class


Cheers, Karl

My Blog | Mole's Home Page | How To Create Screen Capture Videos For Your Articles

Just a grain of sand on the worlds beaches.




modified 27-Feb-21 21:01pm.

GeneralRe: Arrays Pin
Cedrickdeorange3-Feb-08 6:31
Cedrickdeorange3-Feb-08 6:31 
GeneralRe: Arrays Pin
User 2710093-Feb-08 6:35
User 2710093-Feb-08 6:35 
GeneralRe: Arrays Pin
Cedrickdeorange3-Feb-08 7:34
Cedrickdeorange3-Feb-08 7:34 
QuestionHow To Load The Menu Dynamically In Vb.Net ? Pin
kumareshTMC2-Feb-08 18:41
kumareshTMC2-Feb-08 18:41 
GeneralRe: How To Load The Menu Dynamically In Vb.Net ? Pin
User 2710093-Feb-08 4:21
User 2710093-Feb-08 4:21 
GeneralRe: How To Load The Menu Dynamically In Vb.Net ? Pin
Expert Coming3-Feb-08 17:57
Expert Coming3-Feb-08 17:57 
Generalplease help me in vb.net Pin
Abdul Rahman Hamidy2-Feb-08 18:25
Abdul Rahman Hamidy2-Feb-08 18:25 
GeneralRe: please help me in vb.net Pin
Mark Churchill3-Feb-08 2:15
Mark Churchill3-Feb-08 2:15 
GeneralRe: please help me in vb.net Pin
nishkarsh_k3-Feb-08 17:57
nishkarsh_k3-Feb-08 17:57 
GeneralHELP!!! Saving HTML Pin
keyops2-Feb-08 10:07
keyops2-Feb-08 10:07 
GeneralRe: HELP!!! Saving HTML Pin
User 2710092-Feb-08 11:03
User 2710092-Feb-08 11:03 
NewsVisual Studio 2008 Crashes When Applying Custom Attribute - BUG and Solution Pin
User 2710092-Feb-08 5:04
User 2710092-Feb-08 5:04 
GeneralMake Mpeg from jpeg Pin
Rupesh Kumar Swami2-Feb-08 1:02
Rupesh Kumar Swami2-Feb-08 1:02 
GeneralRe: Make Mpeg from jpeg Pin
Csharp™2-Feb-08 2:54
Csharp™2-Feb-08 2:54 
GeneralADODB to .net [modified] Pin
nishkarsh_k2-Feb-08 0:30
nishkarsh_k2-Feb-08 0:30 
GeneralRe: ADODB to .net Pin
Mycroft Holmes3-Feb-08 16:07
professionalMycroft Holmes3-Feb-08 16:07 
GeneralRe: ADODB to .net Pin
nishkarsh_k3-Feb-08 17:50
nishkarsh_k3-Feb-08 17:50 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.