473,386 Members | 1,830 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,386 software developers and data experts.

Need urgent help: Activex in asp.net..

Hi Friends,

I've developed an activeX control (.ocx) using VB 6.0
it has two Public functions, which chages some values of text boxes of the
control.
Fun1(int a)
Fun2()
How to use this control in ASP.NET (C#)?
I've added reference to my web application.

But I'm not getting UserControl.Fun1(a)?
or UserControl.Fun2() in ASP.NET (C#)
However the same calls works fine in Windows forms application.
and in VB 6.0 (standard EXE).

How to call these functions in ASP.NET?
Or any other way to deploy the control for with a web page?

Please help.

Thanks & Regards,
Sachin M
Nov 17 '05 #1
4 2382
Hi,

Post the code you are using, if possible both in VB.NET (working ) and the
C# that is not working

cheers,

--
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of Transportation
"Sachin_M" <Sa*****@discussions.microsoft.com> wrote in message
news:6A**********************************@microsof t.com...
Hi Friends,

I've developed an activeX control (.ocx) using VB 6.0
it has two Public functions, which chages some values of text boxes of the
control.
Fun1(int a)
Fun2()
How to use this control in ASP.NET (C#)?
I've added reference to my web application.

But I'm not getting UserControl.Fun1(a)?
or UserControl.Fun2() in ASP.NET (C#)
However the same calls works fine in Windows forms application.
and in VB 6.0 (standard EXE).

How to call these functions in ASP.NET?
Or any other way to deploy the control for with a web page?

Please help.

Thanks & Regards,
Sachin M

Nov 17 '05 #2
Hi,

Post the code you are using, if possible both in VB.NET (working ) and the
C# that is not working

cheers,

--
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of Transportation
"Sachin_M" <Sa*****@discussions.microsoft.com> wrote in message
news:6A**********************************@microsof t.com...
Hi Friends,

I've developed an activeX control (.ocx) using VB 6.0
it has two Public functions, which chages some values of text boxes of the
control.
Fun1(int a)
Fun2()
How to use this control in ASP.NET (C#)?
I've added reference to my web application.

But I'm not getting UserControl.Fun1(a)?
or UserControl.Fun2() in ASP.NET (C#)
However the same calls works fine in Windows forms application.
and in VB 6.0 (standard EXE).

How to call these functions in ASP.NET?
Or any other way to deploy the control for with a web page?

Please help.

Thanks & Regards,
Sachin M

Nov 17 '05 #3
Hi Ignacio,

Thanks for the reply.
the activex control after dropping on web form gives:
<body MS_POSITIONING="GridLayout">
<form id="Form1" method="post" runat="server">
<OBJECT id="ShowLevel" classid="clsid:9F2B3505-199C-11D2-9E4E-00AA002156AE"
VIEWASTEXT>
<PARAM NAME="Level" VALUE="65">
</OBJECT>
....
...
Even if I can replace 65 with my own value on each page load through C# (the
code behind), my prob is solved.

I tried with this in a table cell, it worked fine:
System.Web.UI.HtmlControls.HtmlGenericControl MyTableCell1;
string value=MyTableCell1.Text;

but i can't give id to PARAM
Can you guide me how to do this? I'm a beginner in C#

Regards,
Sachin M

"Ignacio Machin ( .NET/ C# MVP )" wrote:
Hi,

Post the code you are using, if possible both in VB.NET (working ) and the
C# that is not working

cheers,

--
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of Transportation
"Sachin_M" <Sa*****@discussions.microsoft.com> wrote in message
news:6A**********************************@microsof t.com...
Hi Friends,

I've developed an activeX control (.ocx) using VB 6.0
it has two Public functions, which chages some values of text boxes of the
control.
Fun1(int a)
Fun2()
How to use this control in ASP.NET (C#)?
I've added reference to my web application.

But I'm not getting UserControl.Fun1(a)?
or UserControl.Fun2() in ASP.NET (C#)
However the same calls works fine in Windows forms application.
and in VB 6.0 (standard EXE).

How to call these functions in ASP.NET?
Or any other way to deploy the control for with a web page?

Please help.

Thanks & Regards,
Sachin M


Nov 17 '05 #4
Hi Ignacio,

Thanks for the reply.
the activex control after dropping on web form gives:
<body MS_POSITIONING="GridLayout">
<form id="Form1" method="post" runat="server">
<OBJECT id="ShowLevel" classid="clsid:9F2B3505-199C-11D2-9E4E-00AA002156AE"
VIEWASTEXT>
<PARAM NAME="Level" VALUE="65">
</OBJECT>
....
...
Even if I can replace 65 with my own value on each page load through C# (the
code behind), my prob is solved.

I tried with this in a table cell, it worked fine:
System.Web.UI.HtmlControls.HtmlGenericControl MyTableCell1;
string value=MyTableCell1.Text;

but i can't give id to PARAM
Can you guide me how to do this? I'm a beginner in C#

Regards,
Sachin M

"Ignacio Machin ( .NET/ C# MVP )" wrote:
Hi,

Post the code you are using, if possible both in VB.NET (working ) and the
C# that is not working

cheers,

--
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of Transportation
"Sachin_M" <Sa*****@discussions.microsoft.com> wrote in message
news:6A**********************************@microsof t.com...
Hi Friends,

I've developed an activeX control (.ocx) using VB 6.0
it has two Public functions, which chages some values of text boxes of the
control.
Fun1(int a)
Fun2()
How to use this control in ASP.NET (C#)?
I've added reference to my web application.

But I'm not getting UserControl.Fun1(a)?
or UserControl.Fun2() in ASP.NET (C#)
However the same calls works fine in Windows forms application.
and in VB 6.0 (standard EXE).

How to call these functions in ASP.NET?
Or any other way to deploy the control for with a web page?

Please help.

Thanks & Regards,
Sachin M


Nov 17 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
by: Catherine Jones | last post by:
Hi all we are getting active x component can not create object (Error No. 16) while creating an instance of File System Object in ASP client side script. Could you plz help us in solving this...
0
by: Sachin_M | last post by:
Hi Friends, I've developed an activeX control (.ocx) with VB 6.0 it has two Public functions, which chages some values of text boxes in the control. Fun1(int a) Fun2() How to use this control...
1
by: SmartGuy | last post by:
hi,all: The whole thing is : My team is developing some activex controls in VB 6.0. As a new comer, i am quite familiar with .Net(c#) than vb 6.0. So can i develop ActiveX controls in c#? And if...
4
by: Das | last post by:
Hi All, I want to have a link on the web form. On click it should print the web form. If I use javascript window.print then it displays the Title on the top of the page & URL at the bottom but i...
3
by: JenHu | last post by:
Hi experts, In my asp.net application, I use VB.NET code. I want to have a yes/no button in my popup message box when user click "Submit" button. It will check if the employee is a rehire, if...
2
by: Sachin_M | last post by:
Hi Friends, I've developed an activeX control (.ocx) with VB 6.0 it has two Public functions, which chages some values of text boxes in the control. Fun1(int a) Fun2() How to use this control...
15
by: Cheryl Langdon | last post by:
Hello everyone, This is my first attempt at getting help in this manner. Please forgive me if this is an inappropriate request. I suddenly find myself in urgent need of instruction on how to...
1
by: LintDiggy | last post by:
My vb6 application has a nasty memory leak that I can't trace for the life of me. I have an ActiveX object that I've created called an Operation. The control has the following components : ...
3
by: sunbeam | last post by:
Short Description of the Project: we developed a e-learning system for our students. each student has a unique username/password to view the modules he/she should view and nothing more. since we...
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: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
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: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
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...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...

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.