Wrox Programmer Forums
|
VB.NET General VB.NET discussions for issues that don't fall into other VB.NET forums.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the VB.NET section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old June 20th, 2006, 01:28 PM
Registered User
 
Join Date: Jun 2006
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default File Directory Access

I am new to .NET, trying to write a basic web page that allows users to look at a list of text files on another computer, andclick one to download it.

'This works
mypath = "G:\" ' local drive
myname = Dir(mypath, vbDirectory) ' Retrieve the first entry.

' this does not, returns nothing, regardless of network drive used, drive is connected
mypath = "G:\" ' netwrok drive
myname = Dir(mypath, vbDirectory) ' Retrieve the first entry.

'someone recommended I try this, which gives me an error "Could not find part of the path"
Dim di As New DirectoryInfo("G:\")
Dim fiArr As FileInfo() = di.GetFiles()

'Someone else recommended trying GetFiles, when I do I get an error "Could not find part of the path", or "unknown user name or bad password."
mynames = GetFiles("\\tx30-ibe01\datadrive\devapps")

any idea what I need to do?

Mike



 
Old June 20th, 2006, 01:45 PM
Friend of Wrox
 
Join Date: Nov 2004
Posts: 1,621
Thanks: 1
Thanked 3 Times in 3 Posts
Default

Where in the collection of components if this code you are showing us? (Server? Web page?)
How are you invoking it?





Similar Threads
Thread Thread Starter Forum Replies Last Post
Linking Access to Active Directory Brendan Bartley Access 2 November 28th, 2007 05:42 AM
Active Directory Access obrienkev C# 2005 3 October 31st, 2007 11:36 AM
Access to Active Directory pcyoung Access 4 August 17th, 2007 08:32 AM
Directory access mike_remember ASP.NET 1.0 and 1.1 Professional 3 May 9th, 2007 10:18 AM
Access denied to a directory hasanali00 BOOK: ASP.NET Website Programming Problem-Design-Solution 2 March 22nd, 2005 07:35 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.