Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

com component on aspx page

Status
Not open for further replies.

vishalmarya

Programmer
Aug 19, 2001
28
0
0
have created a simple activex control.
it loads successfuly on the aspx page. it displays its user interface as created. ( one text box and a command button )

following is the vb6 code for the activex control

Option Explicit
Dim displaytext_value As String

Private Sub Command1_Click()
Text1.Text = displaytext_value
End Sub


Public Property Get displaytext() As String
displaytext = displaytext_value
End Property

Public Property Let displaytext(ByVal vNewValue As String)
displaytext_value = vNewValue
End Property

Private Sub UserControl_ReadProperties(PropBag As PropertyBag)
displaytext_value = PropBag.ReadProperty("displaytext", "")
End Sub

Private Sub UserControl_WriteProperties(PropBag As PropertyBag)

PropBag.WriteProperty "displaytext", displaytext_value, ""

End Sub

-----------------------------------------
following is the aspx page code

<OBJECT style="Z-INDEX: 110; LEFT: 304px; WIDTH: 176px; POSITION: absolute; TOP: 296px; HEIGHT: 176px"
CODEBASE="TestCtl.ocx" classid="clsid:4C86F415-A10F-4785-B7D0-549A37D20F08" VIEWASTEXT>
<PARAM NAME="_ExtentX" VALUE="4657">
<PARAM NAME="_ExtentY" VALUE="4657">
<PARAM NAME="displaytext" VALUE="this is a test control">
</OBJECT>


-------------Now the Problem ----------------------------

this control is loaded in the page when its opened in the web browser.

But on click of the command button , value of displaytext property i.e.
"this is a test control" should be displayed in the textbox.
and that is Not Happening.

if i use this control in vb.net windows application. it works and value is displayed

Any Suggestions.

Thanks
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top