Results 1 to 9 of 9

Thread: is it posibble to embed a program in HTML

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Aug 2000
    Posts
    117
    Does any one know how to embed a program(activeXControl) into a HTML page.

  2. #2
    Fanatic Member Dim's Avatar
    Join Date
    Jul 2000
    Posts
    620
    I'm not sure of the answer for your question. But you might want to take a look into DHTML, it allows you to create and code a vb program like interface on your page.

    Gl,
    D!m
    Dim

  3. #3
    New Member
    Join Date
    Jun 2000
    Posts
    8

    Wink

    hello...the example bellow is from microsoft...maybe can help you:
    Suppose you copy the code into wordpad,save the file as "mypage.html"....
    In fact,this is a page which combine an ActiveX Control with ADO.

    <HTML>
    <HEAD>
    <TITLE>New Page</TITLE>
    </HEAD>
    <BODY>
    <OBJECT ID="MSFlexGrid1" WIDTH=787 HEIGHT=159
    CLASSID="CLSID:6262D3A0-531B-11CF-91F6-C2863C385E30">
    <PARAM NAME="_ExtentX" VALUE="20796">
    <PARAM NAME="_ExtentY" VALUE="4207">
    <PARAM NAME="_Version" VALUE="393216">
    <PARAM NAME="AllowUserResizing" VALUE="1">
    </OBJECT>

    <SCRIPT LANGUAGE = "VBSCRIPT">

    Sub Window_OnLoad()
    Dim MyCon
    Dim ADC
    Set MyCon = CreateObject("ADODB.Connection")
    Set ADC = CREATEOBJECT("ADODB.RECORDSET")

    ADC.Open "SELECT * FROM PRODUCTS", MyCon, , , adOpenKeyset

    MSFlexGrid1.Cols = ADC.Fields.Count + 1

    Dim V

    Do While Not ADC.EOF
    V = V + 1
    ADC.MoveNext
    Loop

    ADC.MoveFirst
    MSFlexGrid1.Rows = V + 1
    MSFlexGrid1.Row = 0
    MSFlexGrid1.Col = 1
    ADC.MoveFirst
    Dim MyResource
    MyResource = ADC.GetString

    MsFlexGrid1.Cols = ADC.Fields.Count
    For X = 0 To ADC.Fields.Count - 1
    MSFlexGrid1.TextMatrix(0, X) = ADC.Fields(X).Name
    Next
    MSFLEXGRID1.Row = 1
    MSFLEXGRID1.Col = 0
    MSFLEXGRID1.RowSel = MSFLEXGRID1.Rows - 1
    MSFLEXGRID1.ColSel = MSFLEXGRID1.Cols - 1
    MSFLEXGRID1.Clip = MyResource
    MSFLEXGRID1.RowSel = MSFLEXGRID1.Row
    MSFLEXGRID1.ColSel = MSFLEXGRID1.Col

    End Sub
    </SCRIPT>
    </BODY>
    </HTML>

  4. #4
    I'm about to be a PowerPoster! Joacim Andersson's Avatar
    Join Date
    Jan 1999
    Location
    Sweden
    Posts
    14,649
    As you can see from Aldea's post you use the OBJECT tag to insert an ActiveX control. You have to specify the CLSID parameter, you find the value in the registry.
    The PARAM tag sets properties for the control. Just specify the property NAME and its VALUE.

    The easiest way of doing this is to download the ActiveX Control Pad application. You can find it at Microsoft's site and it's free.

  5. #5

    Thread Starter
    Lively Member
    Join Date
    Aug 2000
    Posts
    117
    Suppose i want tp upload this page to a server so that others can use it, do i need to upload anything else along with the HTML page ?

  6. #6
    I'm about to be a PowerPoster! Joacim Andersson's Avatar
    Join Date
    Jan 1999
    Location
    Sweden
    Posts
    14,649
    Yes the ActiveX control. And if it's written in VB the VB run-time files!!!!

  7. #7
    Hyperactive Member
    Join Date
    Jun 1999
    Location
    ma,usa
    Posts
    485
    I only put a activeX control, not the library in my uploaded files and refrenced it as an object and it works great. Only problem is that users have to turn their security settings off to register it the first time on their machines and then reboot. If I include the runtime in the files will the page run server-side without any need to register? This would be cool but sounds like the runtime would have to be active on the server though. Any clarification on this?

  8. #8
    I'm about to be a PowerPoster! Joacim Andersson's Avatar
    Join Date
    Jan 1999
    Location
    Sweden
    Posts
    14,649
    An ActiveX control doesn't run on the server, it runs on the client.
    That is the first time the user browse your web site the ActiveX control is downloaded to the client before it runs.

    If the control is made in VB the user must have the VB run-time files installed. If he/she doesn't you have to include them on your server so they will be downloaded.
    If you don't want to upload the run-time files you can (if you use P&DW) redirect the download to Microsofts site.

  9. #9
    Hyperactive Member CyberSurfer's Avatar
    Join Date
    Aug 2000
    Location
    Old London Town
    Posts
    425
    My friend wrote pacman in VB, and has it embedded into his website perfectly.

    http://www.andrewbanks.com/demo2.htm


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