创建服务器登录名 [英] Creating a Server Login

查看:84
本文介绍了创建服务器登录名的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

好的,我以前做过其中一种,但是当我不得不重新加载计算机时我丢失了它....而且我找不到以前用来帮助我做的教程.

我正在做的是/like/MSWPI(Microsoft Web平台安装程序),但还不完全是.当您打开它时,将弹出一个对话框,询问用户名和网站密码(我可以使用"SendKeys"来做到这一点),这是正确的,它将加载一个列表.文件和目录. use3r可以从那里下载任何内容.

我想在我的网站上进行下载,有时我会在其中发布一个教程,并发布我制作的程序,但是大多数尚未完成的程序都可以进入到私有服务器...

我没有使用任何种类或SQL,MySQL等.我简单地使用了我朋友给我的用户名/密码的服务器,在达成协议后,我从他那里购买了服务器.

好吧,我想我开始和很多人聊天了,所以请发表您认为对我有帮助的内容.

拜托,谢谢您,
乔丹



这是我当前的代码:

OK, I've made one of these before, but I lost it when I had to reload my computer.... And I can't find the tutorial I used before to help me make one.

What I'm doing to making something that is /like/ the MSWPI(microsoft web platform installer), but not quite. When you open it up, a dialog will pop up, and ask for a username, and password to the site(I might be able to do that with "SendKeys"), is it is correct, it will load up a list of files and directories. From there the use3r can download anything.

I want to make this for my website, where i will sometimes post a tutorial, and post the programs I make, but most programs that are not done yet go in to the private server...

I am NOT Using ANY kind or SQL, MySQL, ect. I simple use the server my friend gave me the username/pasword to, and after I worked out a deal, I bought it from him.

Ok, I think I'm starting to talk to much, so please post what you think might help me.

Please and Thank You,
Jordan



Here is my current code:

Imports System.Net
Imports System.Web
Public Class InternetConnector

    Public Sub IsConnected(ByVal Host As String, ByVal Status As String, ByVal Connected As Boolean)
        If My.Computer.Network.IsAvailable Then

            Status = "Connection Availible"

        ElseIf Not My.Computer.Network.IsAvailable Then

            Status = "Connection Not Availible"

        End If

   If Connected = True Then

            'TRUE CODE

        ElseIf Connected = False Then

            'FALSE CODE

        End If

    End Sub


    Private Sub ConnectedTrue(ByVal NetworkUserPass As NetworkCredential, ByVal FileName As String, ByVal FilePath As String)
        Dim WEB As New WebClient
        WEB.Credentials = NetworkUserPass
        WEB.DownloadFile(FileName, FilePath)
    End
 Sub


    Private Sub ConnectedFalse(ByVal NetworkUserPass As NetworkCredential, ByVal FileName As String, ByVal FilePath As String)
        Dim WEB2 As New WebClient
        WEB2.Credentials = NetworkUserPass
        WEB2.UploadFile(FileName, FilePath)
    End Sub

End Class



希望对您有所帮助! :)



Hope it helps out! :)

推荐答案

在这里看看:


这篇关于创建服务器登录名的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆