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. Shell "File Not Found"

Shell "File Not Found"

Scheduled Pinned Locked Moved Visual Basic
linuxhelpquestion
2 Posts 1 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.
  • T Offline
    T Offline
    TheComputerMan
    wrote on last edited by
    #1

    I have searched Google and the message boards but I can't find an answer to this.

            strFileName = My.Computer.FileSystem.SpecialDirectories.MyDocuments & "\\" & Me.dgvData.SelectedRows(0).Cells(0).Value.ToString & ".kml"
            Dim sw As StreamWriter = New StreamWriter(strFileName)
            sw.WriteLine(strXML)
            sw.Close()
    
            strFileName = Chr(34) & strFileName & Chr(34)
            procID = Shell(strFileName, AppWinStyle.NormalFocus)
    

    As soon as it hits Shell if stops with file not found, yet the file exists as it has just been created. As you can see I tried enclosing the file name with "", but that has not helped either. I am assuming that since a kml file extension is registered to Google Earth that I don't need to specify GE. The file runs just fine if I find it in My Documents and double click it. Anyone out there who can help? :) :)

    T 1 Reply Last reply
    0
    • T TheComputerMan

      I have searched Google and the message boards but I can't find an answer to this.

              strFileName = My.Computer.FileSystem.SpecialDirectories.MyDocuments & "\\" & Me.dgvData.SelectedRows(0).Cells(0).Value.ToString & ".kml"
              Dim sw As StreamWriter = New StreamWriter(strFileName)
              sw.WriteLine(strXML)
              sw.Close()
      
              strFileName = Chr(34) & strFileName & Chr(34)
              procID = Shell(strFileName, AppWinStyle.NormalFocus)
      

      As soon as it hits Shell if stops with file not found, yet the file exists as it has just been created. As you can see I tried enclosing the file name with "", but that has not helped either. I am assuming that since a kml file extension is registered to Google Earth that I don't need to specify GE. The file runs just fine if I find it in My Documents and double click it. Anyone out there who can help? :) :)

      T Offline
      T Offline
      TheComputerMan
      wrote on last edited by
      #2

      Thanks Folks. Question answered in the "How do I..." about the screen saver. Process.start works just fine.

      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