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

jscript calling c# function?

I want to create a Windows Form in C# that has a web browser componant on
it. If I load a web page into the web browser containing jscript, can
jscript call a C# function on my form?

Nov 15 '05 #1
2 1808
I canot help you, but I would like to know if javascript can call into a
dotnet windows form on a web-page, and
the other way.

This is possible with Java and Flash, using liveconnect. But how about
dotnet?

Sorry if you feel I mix up you question, just thourt that maybe this was a
little bit the same thing.

Best Regards,

Anders,

"Bootstrap Bill" <wr*******@yahoo.com> wrote in message
news:#J**************@TK2MSFTNGP12.phx.gbl...
I want to create a Windows Form in C# that has a web browser componant on
it. If I load a web page into the web browser containing jscript, can
jscript call a C# function on my form?


Nov 15 '05 #2
yes, with a little work. the javascript in the browser can call any com
object that supports late binding. this means you have to expose a com
object to the browser that the javascript can talk too.

there are two approaches to exposing this object:

1) the browser support one external object (defined in the hosting site).
but this is not supported by the web control, you will have to write your
own C/C++ wrapper to expose it.

2) supply a .net active/x control that remotes back into your app.

-- bruce (sqlwork.com)
"Bootstrap Bill" <wr*******@yahoo.com> wrote in message
news:#J**************@TK2MSFTNGP12.phx.gbl...
I want to create a Windows Form in C# that has a web browser componant on
it. If I load a web page into the web browser containing jscript, can
jscript call a C# function on my form?


Nov 15 '05 #3

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

Similar topics

29
by: Christopher Brandsdal | last post by:
If I have a .ASP page that runs JScript code - is it possible to include an ..ASP page that runs VBscript???
4
by: Harag | last post by:
Hi All I currently thinking of converting from my little knowledge of VBscript to jScript ASP. With this in mind I'm looking at my current code to see how it will convert over to Jscript. ...
6
by: Dan Roberts | last post by:
I am running some off-the-shelf software that is written in ASP, which uses JScript to generate dynamic content within HTML forms. There are several ASP pages which are partially rendering to IE,...
5
by: benc | last post by:
Hi Can some good soul help on this. I need to call jscript functions from C#. I have hosted a web control and displayed an html page successfully, but just can't find a way to call jscript...
1
by: Chuck Traywick | last post by:
Finally getting some thing to work but am perlpexed by client side jScript code. Two questions we'd really appreciate some feedback on: 1: If we have a function in JScript that validates a...
2
by: moondaddy | last post by:
I'm using vb.net and have an aspx page where I want to call a function in the code behind to do something on the backend and I want to call this function from a jscript function in the aspx page. ...
2
by: Chuck Thomos | last post by:
Does the number of arguments defined in the Jscript function should match the number of arguments while calling the function should match? I am seeing in my test that it is not required to match....
1
by: Andrew Wan | last post by:
How can VBScript code access JScript code variables in the same ASP page? <SCRIPT LANGAUGE="VBScript"> Dim a a = 10 </SCRIPT> <SCRIPT LANGUAGE="JScript"> Response.Write(a); </SCRIPT>
3
by: Kosmos | last post by:
G'day...not sure if this is the proper place to post this question as it is vbscript, but I figured I'd give it a shot...I have searched the depths of the oceans for an answer to this problem but I...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
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...

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.