Hi,
While Working With Silverlight I came Across the Problem of Interacting with .Xap or Silverlight File Using javascript and Interacting Javascript From Csharp code of Silverlight
It was Not Big I Feel That It very Usefull So i will Like To share Knoweldge
So lets Start..
I assume That U Know Silverlight At Least Hello World
if Not then u Can see The Code Here.. and Way to code for Simple Hello
World Program in Silverlight
http://silverlight2pointzero.blogspot.com/2009/03/hello-world-for-silver-light-20.html
Requirement
VS2008
IIS
Javascript
Lets Start
Setp1
Changing Color For Grid Control From White To
Yellow
Step2
Adding Button and Text Control on Html
Control on Aspx,or Asp or Html Page
Step3
Adding Name Space in Page Which Would make
Aceesable to html Conetent and To javascript
Step4
Now Adding Load Event with registration
of Name which Would be used in Javascript
Step5
Know Adding Event which is going to be added
into javascript
Step6
Adding Javascript Code in Page
of html,classic asp,html
Step7
Know Passing Data from Html page to Silverlight.
Step8
Seeing Data Which Had Been Send Data from Html
to Silverlight
Step 9
Know We will Pass Data from Silverlight
to Html javascript
Know Addding Event Handler to button
Step10
Code which Javascript is called from Silverlight
Step11
Know Managed Code used To call Javascript
from Html,Aspx,Classic Asp or html
Step12
Know Checking Out Put
of interaction of .xap file
(Silverlight) to Html
Page
This Complete the work of Using Javascript
U can Download The code from
http://www.mediafire.com/?maz2nkhz12a
Hope It Helps
Subscribe to:
Post Comments (Atom)
Is there any other way of doing this without using javascript.
ReplyDeleteU may Try Passing Session Or Cookies
ReplyDelete