all groups > dotnet compact framework > march 2006 >
You're in the

dotnet compact framework

group:

How to programmatically Provide Domain\Username and Password


How to programmatically Provide Domain\Username and Password Ron Weiner
3/30/2006 4:04:33 PM
dotnet compact framework: I have a VB.Net Pocket PC application that needs to be able to move files it
generates to a \\Server\Share for additional processing. The devices
connect to our network via WiFi. I am currently using code like:

strFiles = Directory.GetFiles(strSearchPath, "*.wav")
j = 0
For Each strfile In strFiles
File.Copy(strfile, Path.Combine(strNewDirName,
Path.GetFileName(strfile)), True)
j += 1
txtChanged.Text = "Saving Wave File " & j
Next

Works Great! But :-(

The first time that the Pocket PC does this A dialog pops up looking for the
user to enter their Username and Password for access to the Share. Sure as
Day follows the night our users are complaining about having to errorlessly
tap in their network credentials. Is there any way I can alleviate their
plight and programmatically provide a valid set of credentials (with
appropriate permissions) before I start the file copy procedure?

--
Ron W
www.WorksRite.com

Re: How to programmatically Provide Domain\Username and Password Chris Tacke [MVP]
3/30/2006 4:10:22 PM
I've not done the managed conversion yet, but here's the native
implementation. As you can see, it's not so simple:

http://blog.opennetcf.org/ctacke/PermaLink,guid,9e9b19d4-b436-486d-a3e6-305962db031c.aspx

-Chris


[quoted text, click to view]

Re: How to programmatically Provide Domain\Username and Password Ron Weiner
3/30/2006 4:30:47 PM
Oy Veh!

I hadn't anticipated it would be this much of a project. Looks like I am
going to have to sharpen up my "C" to VB skills and attempt to PInvoke my
way through this as best I can. Thanks for the heads up.

--
Ron W
www.WorksRite.com
[quoted text, click to view]

AddThis Social Bookmark Button