473,385 Members | 1,569 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

code for representing "Events" for a custom control in classic ASP

Hi to All,

I created one ClassLibrary in .Net using VB.Net, which is configured for COM InterOP. In this Library, I created 3 classes and below they are.

(1) Document class: which is having 2 properties
(a) AddPage : function for adding a Page to the Document.
(b) DrawToFile : method which 'll draw the output to the specified file.
(2) Page class: Having a AddLabel function used for adding a Label to the Page.
(3) Label class: having 2 functions and 1 Event.
(a) Text function: which is used to Set or Get the Text of the Label.
(b) TextColor function , which is used to Set or Get the Text of the Label.
(c) TextColorChanged event


Now, In Vb 6, by referencing the TypeLibrary for the .Net ClassLibrary, I am able to code as I required. And the code , what I have written in Vb 6 is below.


Public WithEvents mylabel As ClassLibrary1.Label
Public doc As New Document

Private Sub Command1_Click()
Dim page As page
Set page = doc.AddPage
Set mylabel = page.AddLabel("ceTe Software,Mysore,India", 10, 10, 300, 20)
doc.DrawToFile ("c:\t.pdf")
End Sub

Private Sub Command2_Click()
mylabel_TextColorChanged (Text1.Text)
doc.DrawToFile ("c:\t.pdf")
End Sub

Private Sub mylabel_TextColorChanged(ByVal value As String)
mylabel.TextColor = value
End Sub


My need is to implement the same in Classic ASP.

Anyone, write the code in Classic ASP for me, as I donot know how to do this in Classic ASP.

Thanks in Advance,
Murty
Jun 15 '07 #1
0 1176

Sign in to post your reply or Sign up for a free account.

Similar topics

6
by: Lauren Wilson | last post by:
Hello group, Somehow, I have not yet fully understood the meaning and purpose of "DoEvents". Can someone post or point me to a clear, concise explanation of it -- one that includes situational...
0
by: Robin Tucker | last post by:
Hi people, Is it possible for me to handle events raised by an object which is embeded in a web browser control, from my VB.NET code? I am able to gain access to the object itself through the...
2
by: Jonathan | last post by:
Hi I need implement loosely coupled events to raise events in a Classibrary project from one Windows Application project, and hanlde these from other Windows Application project. I found this...
3
by: Robert Inder | last post by:
I am struggling to catch kestrokes within an Internet Explorer 6 window. My window happens to be displaying three frames, though I suspect a similar problem would arise with a single document. ...
3
by: Ricardo Vazquez | last post by:
THIS IS MY SCENARIO: - PBX (a private telephone exchange or switch) - A Telephony server running on computer "A" (it communicates with the PBX via IP) - An ASP.NET application (running on...
2
by: Lukas Kurka | last post by:
Hi, I would like to create user control which will provide OnClick and other events. Something like index.aspx ..... <uc1:MyControl id="MyControl1" runat="server"...
3
by: Anil Gupte | last post by:
I want to embed using an embed tag or object tag (like YouTube or others do) to embed a video file in a web page. I want to know if there is an event related to the video being done playing. Also...
6
by: Smithers | last post by:
Just looking to compile a list of "all the ways to implement events". I'm NOT looking to get into the merits or mechanics of each in this thread... just want to identify them all - good, bad, and...
0
by: miarfej | last post by:
Hi to all.. i am just new here, hoping to find some suggestions. I am writing a code in VC++. It is about creating an activeX control using MFC. This control exposes the properties and methods of...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.