NETSEND Application in VB6

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Kamlesh

    NETSEND Application in VB6

    Hello,

    I am bored with the NETSEND Command Line interface. Hence, I have
    written a NetSend application using VB6. This program internally
    calls the Shell command to send the message. How can I know the
    SUCCESS/FAILURE of the NETSEND command from VB? If the msg was not
    sent successfully, I want to trap it and give an alert in my NetSend
    User Interface.

    Any help on the above would be appreciated. Is there any other way to
    develop the NET SEND application in better way.

    Regards,
    Kamlesh
  • Raoul Watson

    #2
    Re: NETSEND Application in VB6


    "Kamlesh" <kamlesh2000@ya hoo.com> wrote in message
    news:2644c0f6.0 402152315.4c527 06f@posting.goo gle.com...[color=blue]
    > Hello,
    >
    > I am bored with the NETSEND Command Line interface. Hence, I have
    > written a NetSend application using VB6. This program internally
    > calls the Shell command to send the message. How can I know the
    > SUCCESS/FAILURE of the NETSEND command from VB? If the msg was not
    > sent successfully, I want to trap it and give an alert in my NetSend
    > User Interface.
    >
    > Any help on the above would be appreciated. Is there any other way to
    > develop the NET SEND application in better way.
    >
    > Regards,
    > Kamlesh[/color]

    If you want a status report, look up NetMessageBuffe rSend using netapi32..
    so you can get status like:

    returnCode = NetMessageBuffe rSend(.sServerN ame, _
    .sSendTo, _
    .sSendFrom, _
    .sMessage, _
    ByVal Len(.sMessage))


    Comment

    • R.Wieser

      #3
      Re: NETSEND Application in VB6

      Kamlesh <kamlesh2000@ya hoo.com> schreef in berichtnieuws
      2644c0f6.040215 2315.4c52706f@p osting.google.c om...[color=blue]
      > Hello,[/color]

      Hello Kamlesh,
      [color=blue]
      > I am bored with the NETSEND Command Line interface. Hence,
      > I have written a NetSend application using VB6. This program
      > internally calls the Shell command to send the message. How can
      > I know the SUCCESS/FAILURE of the NETSEND command
      > from VB? If the msg was not sent successfully, I want to trap it
      > and give an alert in my NetSend User Interface.[/color]

      I would advice you, just like Raoul did, to take a peek at the
      NetMessageBuffe rSend API-call, as interfacing with a command-line program
      (and retrieving it's output) is mostly more difficult and more work than
      understanding this, relativily simple, API-call is.
      [color=blue]
      > Any help on the above would be appreciated. Is there any other way to
      > develop the NET SEND application in better way.[/color]

      Jup. Use the force Luke ! .... I mean use the API-call Kamlesh :-)

      Regards,
      Rudy Wieser



      Comment

      • Rick Rothstein

        #4
        Re: NETSEND Application in VB6

        Here is a link showing the function in use...

        VBnet provides Intermediate and Advanced Win32 API code for VB developers. Comprehensive Code, FAQ, Developers Resources & News, alphabetical API/Type/Constant/Method Index, along with the largest Visual Basic-related links list on the net.


        Rick - MVP


        "Raoul Watson" <WatsonR@Intell igenCIA.com> wrote in message
        news:qu5Yb.2948 4$M8.5891@nwrdn y02.gnilink.net ...[color=blue]
        >
        > "Kamlesh" <kamlesh2000@ya hoo.com> wrote in message
        > news:2644c0f6.0 402152315.4c527 06f@posting.goo gle.com...[color=green]
        > > Hello,
        > >
        > > I am bored with the NETSEND Command Line interface. Hence, I have
        > > written a NetSend application using VB6. This program internally
        > > calls the Shell command to send the message. How can I know the
        > > SUCCESS/FAILURE of the NETSEND command from VB? If the msg was not
        > > sent successfully, I want to trap it and give an alert in my NetSend
        > > User Interface.
        > >
        > > Any help on the above would be appreciated. Is there any other way to
        > > develop the NET SEND application in better way.
        > >
        > > Regards,
        > > Kamlesh[/color]
        >
        > If you want a status report, look up NetMessageBuffe rSend using[/color]
        netapi32..[color=blue]
        > so you can get status like:
        >
        > returnCode = NetMessageBuffe rSend(.sServerN ame, _
        > .sSendTo, _
        > .sSendFrom, _
        > .sMessage, _
        > ByVal Len(.sMessage))
        >
        >[/color]


        Comment

        • Kamlesh

          #5
          Re: NETSEND Application in VB6

          "R.Wieser" <rwieser-killthis-@xs4all.nl> wrote in message news:<4030eb5c$ 0$140$e4fe514c@ dreader5.news.x s4all.nl>...[color=blue]
          > Kamlesh <kamlesh2000@ya hoo.com> schreef in berichtnieuws
          > 2644c0f6.040215 2315.4c52706f@p osting.google.c om...[color=green]
          > > Hello,[/color]
          >
          > Hello Kamlesh,
          >[color=green]
          > > I am bored with the NETSEND Command Line interface. Hence,
          > > I have written a NetSend application using VB6. This program
          > > internally calls the Shell command to send the message. How can
          > > I know the SUCCESS/FAILURE of the NETSEND command
          > > from VB? If the msg was not sent successfully, I want to trap it
          > > and give an alert in my NetSend User Interface.[/color]
          >
          > I would advice you, just like Raoul did, to take a peek at the
          > NetMessageBuffe rSend API-call, as interfacing with a command-line program
          > (and retrieving it's output) is mostly more difficult and more work than
          > understanding this, relativily simple, API-call is.
          >[color=green]
          > > Any help on the above would be appreciated. Is there any other way to
          > > develop the NET SEND application in better way.[/color]
          >
          > Jup. Use the force Luke ! .... I mean use the API-call Kamlesh :-)
          >
          > Regards,
          > Rudy Wieser[/color]


          I thank everyone (Watson, Rothstien, Wieser) for the replies and
          suggestions. NetMessageBuffe rSend API works fine.

          Going forward, I am anxious to know how the chat programs like
          Yahoo/MSN are developed? Does any of you guys are aware of it? I am
          interested in studying the chat programs and write one which works on
          Internet. Please recommend me any websites/books.

          Best Regards,
          Kamlesh

          Comment

          Working...