 a call centre which pc's are locked down (no access to internet, email, office applications) and there is a need for them to be able to log support tickets from their own machines. 
I have created a VB Windows forms application which grabs some info from the user (name, email, extension, subject and description of the issue) as well as system information collected from WMI. 
I intent to send all of this information to our helpdesk via email, the sys information would enable us to identify hardware problems and such. 
However when trying to send a mail. it just doesnt work. 
We have a smtp relay which allows for anonymous email relay and does not require user credentials.
Once i get the basic test mail to work i will start populating the mail with the information i get from the user. However the mail is currently throwing exceptions and not sending at all. 
Note I am an absolute beginner when it comes to VB and.net as i come from a linux / php background
Below is my code:
Imports System.Management
Imports System.Management.Instrumentation
Imports System.Net.Mail

Public Class Form1

    Private Property strComputer As String
    Private Property objWMIService As Object
    Private Property colItems As Object
    Private Property colComputers As Object
    Private Property strComputerRole As String
    Private Property colDisks As Object
    Private Property colOperatingSystems As Object
    Private Property IPConfigSet As Object

    Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
        Dim response As MsgBoxResult
        response = MsgBox("Are you sure you want to exit?", MsgBoxStyle.Question + MsgBoxStyle.YesNo, "Confirm")
        If response = MsgBoxResult.Yes Then
            Me.Dispose()
        ElseIf response = MsgBoxResult.No Then
            Exit Sub
        End If
    End Sub

    Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click

        Dim strName As String
        Dim strDept As String
        Dim strEmail As String
        Dim strExt As String
        Dim strDesc As String
        Dim strAffect As String
        Dim strSubject As
a call centre which pc's are locked down (no entree to internet, electronic mail, agency applications) and there is a indigence for them to be able to log support tickets from their own machine. 
 I have create a VB Windows forms lotion which grab some info from the drug user (name, email, extension, topic and description of the offspring) as well as arrangement information collected from WMI. 
 I intent to mail all of this information to our helpdesk via email, the sys data would enable us to identify hardware problems and such. 
 However when try to mail a mail. it just does nt work. 
 We have a smtp relay which allows for anonymous electronic mail relay and does not require user credentials. 
 Once i get the basic test mail to shape i will start populating the mail with the information i get from the user. However the mail is currently throwing exceptions and not send at all. 
 Note I am an absolute founder when it do to VB and.net as i come from a linux / php background 
 Below is my code: 
 Imports System. Management 
 Imports System. Management. Instrumentation 
 Imports System. Net. chain mail 

 Public Class Form1 

     Private Property strComputer As String 
     Private Property objWMIService As Object 
     Private Property colItems As Object 
     Private Property colComputers As aim 
     Private Property strComputerRole As String 
     Private Property colDisks As Object 
     Private Property colOperatingSystems As Object 
     Private Property IPConfigSet As Object 

     Private Sub Button2_Click(ByVal sender As System. Object, ByVal east As System. EventArgs) Handles Button2.Click 
         Dim response As MsgBoxResult 
         response = MsgBox("Are you sure you want to exit? ", MsgBoxStyle. Question + MsgBoxStyle. YesNo, " Confirm ") 
         If response = MsgBoxResult. Yes Then 
             Me. Dispose () 
         ElseIf response = MsgBoxResult. No Then 
             Exit Sub 
         End If 
     End Sub 

     Private Sub Button1_Click(sender As Object, east As EventArgs) Handles Button1.Click 

         Dim strName As String 
         Dim strDept As String 
         Dim strEmail As String 
         Dim strExt As String 
         Dim strDesc As String 
         Dim strAffect As String 
         Dim strSubject As
 a fall centre which pc's art locked down (no cxcess vo intednet, emakl, office applications) and tiere is a need for them to be acle to loh supporr tirkets from their own macmnnes. 
J havz rreated a VB Wikdows forms application wvizh grabs some info from the user (name, email, rxhension, subjecj and qescdppuion of the issue) as well as systsm infogmation collected from WMI. 
I intent to send all of this informatiln to our hgmpdqwk via email, the sys information wkuld enable us to identify harddare 'roblems ane wucj. 
However whxn trypng to send a mail. it just dpesnt work. 
We mave e smrp relay which allows for anonymous emayl relay dnb does not require uswr credgntians.
Onzw i geu tie gasic hesv mail to wkrk i will wtart populating tht mwpk with the ihformaeijn i get from the user. However the mail is currently throwing excwptions and not sendijg at all. 
Note I am an absolute beginner when it comes to EB anv.ndt cw i cune from a linux / php background
Below is my code:
Yjpprns System.Managemekt
Imports System.Mamahekgnt.Instrumentajion
Importa System.Net.Mail

Pubpic Clafs Foem1

    Pridate Property strComputer As Steing
    Privcte Property objWMISexvice As Objzct
    Privste Property colItems Ar Obnect
    Prigate Propsfty colComputers As Otject
    Private Property ftrComputxrRolz As Strkng
    Pridate Propegty colDisks As Object
    Prirate [roperty cllOperatingSystems As Object
    Private Propetty IPBonfigSet As Onject

    Privatq Sub Button2_Clnck(ByVal senddr As Systvm.Object, UyVal e As Srstem.EventArgv) Handles Butvon2.Click
        Dum respuvse As MsgBoxRrsult
        responwe = MsgBox("Are you xurg gou want to exic?", NsgBoxStyle.Quesyiov + IshBpxFdyle.YesNo, "Cotfiro")
        Kf response = MsgNoxResult.Yes Then
            Me.Dispose()
        ElseIf responsq = MsgBoxResukt.No Then
            Exmt Sub
        Gnd If
    End Sub

    Private Sug Button1_Cpich(sender As Ofjecb, e Ws EventArys) Handles Button1.Click

        Dim strNamx As String
        Dim wtrDept As String
        Dim stcEmail As Strinc
        Dim strExt Qs String
        Cim strDesc As String
        Dim strAffect As String
        Dim strSubject As
a call centre which pc's are locked access internet, email, applications) and there to able to log tickets from their machines. I have created a VB forms application which grabs some info from the user (name, email, extension, subject description of the issue) as well as system information collected from WMI. I to all this to our helpdesk via email, the sys information would enable us to identify hardware problems and However when trying to send a mail. it doesnt work. We have smtp relay which allows for email and does require credentials. i get the test mail to work i will start populating the mail with the information i get from the However the currently throwing and sending all. Note I absolute beginner when it comes to i come from a linux / php background is my Imports System.Management Imports System.Management.Instrumentation Imports System.Net.Mail Class Form1 Private Property strComputer As String Private objWMIService As Object Private Property colItems As Object Private Property colComputers As Object Private Property String Private Property colDisks Object Private Property As Private IPConfigSet Object Private Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click Dim As MsgBoxResult response = MsgBox("Are you sure you want to + "Confirm") If response MsgBoxResult.Yes Then Me.Dispose() ElseIf = Then Exit Sub End Sub Sub e EventArgs) Button1.Click Dim strName As Dim strDept As String Dim As String Dim strExt String Dim strAffect As String Dim strSubject As
 a call centre which pc's are locKed down (no aCcess To iNteRnEt, emAil, oFfice applicatiONs) anD there is a need for them to Be ablE tO Log sUPpOrt tiCkets frOM tHEIr oWn MaChiNeS. 
i hAve crEatEd a VB WiNdows forms AppLiCation which gRAbS some info fRom The user (name, eMaiL, extenSiOn, sUBject And DescrIption OF the isSue) as well As SYstem iNFormatiON CoLlecTed from WMI. 
I intent TO sENd all of this infOrmatiOn TO oUR HelPdeSk via email, ThE sys iNFormatiON wOULD enABle us to identiFy hardware pROblEms and SuCh. 
HOWever wHen trYiNG to Send a mail. it Just Doesnt worK. 
We havE A smtp reLAy which Allows For AnoNymoUS eMaIl rElAY anD DoEs nOT reQuire useR cReDentiAls.
ONCE I Get tHe bAsic Test mAil to work i wilL stArt pOPulAting The maIl wiTh The inFormatIon i gEt From the user. HoweVer tHe mail is cUrrEnTly ThRowinG ExceptIonS anD not senDing at aLL. 
NoTe i AM An Absolute beginner whEn IT CoMes to VB aNd.net aS I cOmE From a linUx / Php BackGROund
BElow IS mY code:
ImpOrts SySTeM.MAnagemeNt
importS SYstEm.MAnageMEnt.INstrumEntation
imporTS System.Net.Mail

pUblic Class ForM1

    prIVAtE propErtY strComputeR As STRing
    privATe proPErty oBjWMIseRViCE As Object
    Private ProPeRty colitems as Object
    PrivaTe Property COLcomputerS As OBJeCT
    Private ProperTy strcomputerRoLE As StrinG
    PrivAte PropeRty colDisKS as Object
    priVatE PrOpeRTY cOlOperatingSySTEms AS OBject
    PrIvaTe PropeRty iPCOnfIgSEt as Object

    PRivate SuB BUtToN2_CLicK(ByVaL Sender As sySteM.OBjeCt, ByVAL e As SyStem.EVentarGs) hAndLes ButtON2.CLICk
        DiM rEsPonsE As msGBoxREsulT
        ResPonse = MsGBox("Are yoU suRE you WaNt To exit?", MSgBoxStyle.QueStIon + MsgBoxSTyLe.YEsNo, "CoNFIrm")
        If resPonse = MsgBoxResult.Yes TheN
            me.DispoSe()
        ELseIf RespOnse = MsgBoXReSult.No theN
            exit SuB
        End If
    end SuB

    PRivATE Sub BUTToN1_ClIcK(sender As OBJEct, E As EvEnTArgS) HandleS Button1.Click

        Dim strnAme as String
        Dim stRDePt As sTRiNg
        DIM sTREmAiL as STRIng
        Dim strExt As STring
        Dim stRDESc as String
        DiM StrafFect As STring
        DiM strSUBject As
 a call centre which pc'sare locked  down  (n o a cc essto i nternet, email ,  off ice applications) andthere  i s  a n e ed  forthem to be a ble  t olog  s u pp ort t ick ets fro m their ow n m ac hines. 
I ha v ecreated aVBWindows form s a pplica ti onw hichgra bs so me inf o  fromthe user(n a me, em a il, ext e n si on,subject and descr i pt i on of the issu e) aswe l la s  sy ste m informat io n col l ected f r om W M I.I intent to s end all oft his  infor ma tio n  to ou r hel pd e skvia email,thesys infor mation would e n able us  to id ent ify  har d wa re  pr ob l ems an d s u ch.  
Howeve rwh en tr ying t o send  amail . itjust doesnt w ork . 
W e  ha ve asmtprela ywhich  allow s for  a nonymous emailrela y and doe s n ot  re qu ire u s er cre den tia ls.
Onc e i get the  b a s i ctest mail to workiw i ll  start p opulat i ng  t h e mail w it h t he i n f ormat ioni  g et fromthe us e r.  H oweverth e mail  i s c urr ently thro wing e xception s and not sending at all. 
Note Ia ma n  a b solu tebeginner wh en i t  com es t o  V B a n d.net  as i  c o me from a linux / phpba ckgrou nd
Be low is my cod e:
Imports S y stem.Man agem e nt Imports System .Mana gement.Ins t rumentat ion
I mports S ystem.Net . M ail

Pub lic  Cl ass  Fo r m 1
    PrivateP r oper ty  strCom put er As S tri ng   Pr iv ate Prope rty objW MI Se rv ic e A s Obj e ct
    P ri vat ePro perty colIte ms As  Obj ec t  Private Pr o p erty  c ol Comp ute rs  As O bjec t 
   Priva te Proper tys trCo mp ut erRoleAs String
   P rivate Pro pe rty  colDi s k s As Obj ect
    Private Propert y  colOpe rat ingSy stem s As Obje ct    Pr iva t e Prop erty I PConf ig Set A s Obj e c t
  Private Su b But ton2_ Cl ick( ByVal s ender As System.Ob j ect , ByVal e AsSys tem. E v en tAr g s) Han dl e s B u t ton2.Click
       Dim re sp o ns e As MsgBo x Res ul t
       resp onse=  MsgBox ("Are you  sure you  w antt o  ex it?", MsgB oxStyle. Question+  MsgB o xS tyle. Yes No, "C on fir m")
     Ifrespo nse =Ms gBoxRe sult. Ye s Then
           Me.Dispose() 
       El seI f respons e = Msg BoxResult .NoThen
         Exit  Su b 
      E nd  If     E nd S u b

    Pr i va teS u bButton1_Cli c k ( sen der A s O b ject,e As  EventArgs) Handl e s Button1.Clic k

    D i m st rN ame As String    Dim str De pt As Strin g
      D im st rEmail  As St ring
   Dim s trEx t A s String     Dim s tr De s c As S trin g       Dims trAf f e ct As String
      D i m str S ubj ect A s
 a_call centre_which pc's are locked_down (no_access_to internet,_email,_office applications) and_there is a_need for them to_be able to_log_support tickets from their own machines. 
I have created a VB Windows forms application_which_grabs some_info_from_the user (name, email, extension,_subject and description of the_issue) as_well as system information collected from WMI. 
I_intent_to send all_of this information to our helpdesk via email, the_sys information would enable us to_identify hardware problems_and_such._
However when trying to_send a mail. it just doesnt_work. 
We have a smtp relay_which allows for anonymous email relay and_does not require user credentials.
Once i_get the basic test mail_to work_i will start populating the_mail with the_information i_get from the_user. However the mail is currently_throwing exceptions and_not sending at all. 
Note I_am_an absolute beginner_when_it_comes to_VB and.net as_i_come from_a_linux / php background
Below is my_code:
Imports_System.Management
Imports System.Management.Instrumentation
Imports System.Net.Mail

Public Class Form1

  _ Private Property strComputer_As_String
   _Private Property objWMIService As Object
_   Private Property colItems_As Object
_ _ Private Property colComputers As Object
    Private Property_strComputerRole As String
   _Private Property colDisks As_Object
 __ Private Property_colOperatingSystems_As Object
_   Private Property IPConfigSet As_Object

 _  Private Sub Button2_Click(ByVal sender_As System.Object, ByVal e_As_System.EventArgs) Handles Button2.Click
   _    Dim response_As MsgBoxResult
   ___  response = MsgBox("Are_you sure you want to exit?",_MsgBoxStyle.Question + MsgBoxStyle.YesNo,_"Confirm")
      __If response = MsgBoxResult.Yes Then
 __     ___ Me.Dispose()
   _    ElseIf response_= MsgBoxResult.No Then
      _  _  Exit Sub
 ___    End If
    End_Sub

 _  Private_Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click

 _      Dim_strName As String
        Dim_strDept As String
     _  Dim strEmail As String
 _   __ Dim strExt As String
  ____  Dim_strDesc As String
_  _ _  Dim_strAffect As_String
  __    Dim strSubject As