Results 1 to 8 of 8

Thread: ActiveX to check Page exist and run command

  1. #1

    Thread Starter
    New Member
    Join Date
    Nov 2007
    Posts
    5

    ActiveX to check Page exist and run command

    Hi everybody,

    To protect 1 MS-Access application, I'm searching 1 ActiveX component who can check one information on the web (may be just if 1 page exist) and allow to exit application based on this information.

    I'm not too bad in Vba but novice in Vb6 and need help from 1 'expert'.

    Thanks to respond.

    Yves

  2. #2
    Lively Member Spetnik's Avatar
    Join Date
    Jan 2002
    Posts
    121

    Re: ActiveX to check Page exist and run command

    I am not sure what you are asking. Do you want to check a web page for specific data, and perform a function based on that data?

  3. #3

    Thread Starter
    New Member
    Join Date
    Nov 2007
    Posts
    5

    Re: ActiveX to check Page exist and run command

    Yes, checking any information, it may be if a page exist or if 1 information is on one page ...

    The goal is to be able to exit the application based on this information.

    Because the user will have access to code, I can not put it there, it will be too easy to find and disable (with the help of the debug mode).

    I think that having 1 object hidden in one form who check the web when the form load and exit automatically may be the best way to protect the application.

    Do you know if this is feasible ?

    Yves.

  4. #4
    Lively Member Spetnik's Avatar
    Join Date
    Jan 2002
    Posts
    121

    Re: ActiveX to check Page exist and run command

    You can use winHTTP, but why not just just set permissions in the access database so that non-admins cannot edit or view the code?

  5. #5

    Thread Starter
    New Member
    Join Date
    Nov 2007
    Posts
    5

    Re: ActiveX to check Page exist and run command

    What is WinHTTP ?

    I'm obliged to keep code open but would like to keep control over the usage in middle term ...

    Yves.

  6. #6
    Lively Member Spetnik's Avatar
    Join Date
    Jan 2002
    Posts
    121

    Re: ActiveX to check Page exist and run command

    The following example shows how to open an HTTP connection, send an HTTP request, and read the response text. It assumes that you have a text box named Text1 on your form. You also must add a reference to Microsoft WinHTTP to your project.

    Code:
     Dim HttpReq As Object
    
        ' Create the WinHTTPRequest ActiveX Object.
        Set HttpReq = New WinHttpRequest
        
        ' Open an HTTP connection.
        HttpReq.Open "GET", "http://microsoft.com", False
    
        ' Send the HTTP Request.
        HttpReq.Send
      
        ' Get all response text.
        Text1.Text = HttpReq.ResponseText
    The following example shows how to post data to an HTTP server.
    Code:
     Dim HttpReq As Object
    
        ' Create the WinHTTPRequest ActiveX Object.
        Set HttpReq = New WinHttpRequest
    
        ' Initialize an HTTP request.  
        HttpReq.Open "PUT", "http://postserver/newdoc.htm", false
    
        ' Post data to the HTTP server.
        HttpReq.Send "Post data"

  7. #7

    Thread Starter
    New Member
    Join Date
    Nov 2007
    Posts
    5

    Re: ActiveX to check Page exist and run command

    Thanks but my problem is that the code will be visible (and tracable) ...
    Do you know if this can be placed in one activeX initialization process ?

    Yves.

  8. #8

    Thread Starter
    New Member
    Join Date
    Nov 2007
    Posts
    5

    Re: ActiveX to check Page exist and run command

    ... + I do not have (nor know) vb ... as it looks not difficult to do for you, are you not tempted to write it for the challenge (and I'm sure a lot of people would love this hidden feature...)

    Yves.

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