IE browser Crashes when embeding a My OCX in HTML page

  • Thread starter Thread starter Prabhakar
  • Start date Start date
P

Prabhakar

Dear Sir/Ma'm

I have written a ocx in VB which contains 2 Text box
control and 1 windows media player componet.
code is as below.

Dim mText As String
Dim mURL As String
Public Property Get Text() As String
On Error Resume Next
Text = Text1.Text
End Property
Public Property Let Text(ByVal vNewValue As String)
On Error Resume Next
Text1.Text = vNewValue
PropertyChanged "Text"
End Property

Public Property Get URL() As String
On Error Resume Next
URL = player.URL

End Property

Public Property Let URL(ByVal vNewValue As String)
On Error Resume Next
player.URL = vNewValue
Text2.Text = vNewValue
PropertyChanged "URL"
End Property

Private Sub player_OpenStateChange(ByVal NewState As Long)
On Error Resume Next
player.URL = vNewValue
Text2.Text = vNewValue
End Sub

Private Sub UserControl_Hide()
On Error Resume Next
player.Close
End Sub

Private Sub UserControl_Terminate()
On Error Resume Next
player.Close
End Sub

After Registering the OCX i get the CLSID from the
Registry and embed the same in the HTML page .
code of HTML page is as below.

<html>
<body>
<object
classid="clsid:347A9647-B6CA-4E8D-BCBA-5FF6EEA265A8"</object>
</body>
</html>

Then I launch This Htlm using Ineternet Explorer 6.0
Then i clieck on The OCX on the HTMl page. latter close
the HTLM page from the Window Close button

Internet explorer crashes saying...
Could not write into memory 0x236eca8.....
click ok close the application.

Can you help me out to solve this issue
 
I'd like to debug this.
Can you ZIP up your entire project and send it to me in email?
(e-mail address removed)
Thanks,
---Dan---

This posting is provided "AS IS" with no warranties, and confers no rights.
 
Back
Top