Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. Visual Basic
  4. Calling Batch File from VB

Calling Batch File from VB

Scheduled Pinned Locked Moved Visual Basic
helpsysadminlinux
3 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Offline
    A Offline
    aaraaayen
    wrote on last edited by
    #1

    Hi Friends, I am calling one batch file from vb program like the below code. Dim d As Double d = Shell("\\sys1\share1\overtime log\Overtime Log\Ext.bat", vbHide) the above 2 lines are given in form_load event. share1 is the shared folder in the server sys1. When I try to run this application which is having the above two lines to call the batch file from the Server : sys1 it is working fine and calling the batch file. But when i create package and deployement of this application, and installed in other system and when i try to run the project, it gives error Runtime Error: Call to invalid procedure or argument But the i am not getting the above error if i give the ipaddress of sys1 instead of giving the system name like sys1. Please suggest me some ideas for this. Since my ip address is dynamic, i cannot give that address, so i can only give my sys name ....So Expecting your help. Thanks in Advance, Regards

    C 1 Reply Last reply
    0
    • A aaraaayen

      Hi Friends, I am calling one batch file from vb program like the below code. Dim d As Double d = Shell("\\sys1\share1\overtime log\Overtime Log\Ext.bat", vbHide) the above 2 lines are given in form_load event. share1 is the shared folder in the server sys1. When I try to run this application which is having the above two lines to call the batch file from the Server : sys1 it is working fine and calling the batch file. But when i create package and deployement of this application, and installed in other system and when i try to run the project, it gives error Runtime Error: Call to invalid procedure or argument But the i am not getting the above error if i give the ipaddress of sys1 instead of giving the system name like sys1. Please suggest me some ideas for this. Since my ip address is dynamic, i cannot give that address, so i can only give my sys name ....So Expecting your help. Thanks in Advance, Regards

      C Offline
      C Offline
      Christian Graus
      wrote on last edited by
      #2

      Your IP address on the network is dynamic ? Perhaps this is not the best way to do this ?

      Christian Graus - Microsoft MVP - C++ "also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )

      A 1 Reply Last reply
      0
      • C Christian Graus

        Your IP address on the network is dynamic ? Perhaps this is not the best way to do this ?

        Christian Graus - Microsoft MVP - C++ "also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )

        A Offline
        A Offline
        aaraaayen
        wrote on last edited by
        #3

        Hi, Thanks lot for your reply. Can you suggest any other ideas to overcome this problem. Waiting for your reply. Regards,

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups