CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 6 of 6
  1. #1
    Join Date
    Mar 2001
    Posts
    26

    Question About Internet TransferControl

    Hi

    I use Internet Transfer Control to access send request to a server via https protocol but I receive this error: Client authorization not setup

    I can connect to that site using Internet Explorer without authorization

    Thanks
    Ehsan



  2. #2
    Join Date
    Apr 2001
    Posts
    36

    Re: Question About Internet TransferControl

    I'm tring to use https using the Internet Transfer Protocol. I'm a little confused. Been tring to get the following code to work.

    Dim RemoteHost as string
    Dim RemotePort as Integer
    Dim strFilePath as string
    Dim strRemoteHost as string
    Dim strURLPath as string
    Dim strURL as string
    Dim strFormData as string
    Dim strInput as string

    strPassword = frmFTPInfo.txtN_password.Text
    strUsername = frmFTPInfo.txtN_Username.Text
    strPortNum = frmFTPInfo.txtN_PortNum.Text

    strRemoteHost = "https://stream-portal.akamai.com"
    strURLPath = "/notifyuser/action-script.php3"
    RemotePort = 443
    Inet1.URL = m_strRemoteHost
    Inet1.UserName = strUsername
    Inet1.Password = strPassword
    Inet1.Protocol = icHTTPS
    Inet1.RemoteHost = strRemoteHost
    strFormData = "user=" & strUsername & "&action=" & strAction & "&port=" & strPortNum
    strURL = strRemoteHost & strURLPath & strFormData

    strInput = Inet1.OpenURL(strURL, icString)
    text1.text = strInput




    Currently when I run this code, text1.text = ""
    Could you help me in making this work. I want to be able to execute or open the following link:
    https://mycompany.com/directory/scri...n&port=PortNum
    When I click on the link manually, it works. I want to be able to do this when an event happens. I don't even think that I am connecting to the server. Need help on this if possible.

    Thanks for your assistance.

    [email protected]


  3. #3
    Join Date
    Feb 2001
    Location
    Stamford CT USA
    Posts
    2,167

    Re: Question About Internet TransferControl

    Mike,

    Not sure if this is just a typo, the line: "strURL = strRemoteHost & strURLPath & strFormData" should actually be: "strURL = strRemoteHost & strURLPath & "?" & strFormData"

    Anyway, if you have a server out there that I can test against, I might be able to spare some time to test the code. Email me if you have any.

    -Cool Bizs

    Good Luck,
    -Cool Bizs

  4. #4
    Join Date
    Mar 2001
    Posts
    26

    Re: Question About Internet TransferControl

    Hello

    If you also need to render the output I have a better suggestion,

    You can use web browser control and call it's "navigate" method. I think that it is simpler.

    Even if you don't want to render the output you can set 'visible' property to false and use it.

    Web browser control has also some advantages spec. when you want to use https protocol, for example if your server certificates have a problem Inet will only returns an error without any output, but web browser do the same thing as IE doe's.(Shows you a confirmation dialog and if you confirm the certificate it will do it's job, probably this occurs is when visible property is true)

    Thanks

    Ehsan


  5. #5
    Join Date
    Apr 2001
    Posts
    36

    Re: Question About Internet TransferControl

    Thanks, I will try it and let you know.


  6. #6
    Join Date
    Apr 2001
    Posts
    36

    Re: Question About Internet TransferControl

    Tried that, still did not work. Someone suggested using the Web Browser Control. I will try using that and see what happens. I'll let you know.


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured