Skip to main content
Home Forums Silverlight Programming Programming with JavaScript Guiding to step by step so that can be able to run some of examples Silverlihgt on vectorform, please ?
7 replies. Latest Post by cukingoi on October 22, 2007.
(0)
cukingoi
Member
20 points
27 Posts
10-17-2007 3:58 AM |
Hi all,
I'm learning Silverlihgt, via Scott's blogs I have known that on vectorform/Silverlight site have a lot of samples about Silverlight. I visited it and saw many examples very pretty. I very like and want to get it. I downloaded source code available on it. But when I built in Visual Studio and run then occur error in runtime in the main.js file as following:
AG_E_RUNTIME_METHOD : SetSource
or on the browser alert:
Silverlight error message ErrorCode: 4001ErrorType: DownloadError Message: AG_E_NETWORK_ERROR
Anybody knows as these problems or you had ran OK for Silverlight samples of vectorform, please guide to me step by step so that I can be able to set up these samples on localhost and run OK.
Thanks so much.
Dave Bri...
681 points
229 Posts
10-17-2007 11:10 AM |
These would tend to indicate that resources you are trying to download are not available. SetSource is for setting the source of either an Image, or a MediaElement and I would guess that the apps on vectorform are referencing URI's on that site so running them locally you are hitting security issues related to cross site scripting. If you try to copy the resources locally too, this may help. If you give me a link to specific code, I can take a look to see if I can help ...
=> Dave
ddobbs-v...
66 points
45 Posts
10-17-2007 8:30 PM |
cukingoi, which sample are you trying to view?
The problem is most likely due to certain asset files (images or video) not being in place. You can get the missing files from your cache after viewing the examples on the vectorform site, or you can replace the file references with your own images or video files. If the example is using a downloader object, it will need to be run from an actual web server. Another reason may be that you are trying to view one of the examples that use a .php proxy script to grab content from another server (such as the Flickr example). If thats the case you would need to run the files through a server that has php installed or write an equivalent proxy script in the language of your choice (like asp for example).
10-18-2007 4:50 AM |
Hi you,
I tried to run these your examples as following:
image_viewer2, vectorwho, version9. Please give me an advise. Thanks a lot you.
10-18-2007 9:47 AM |
cukingoi,
both image_viewer2 and vectorwho need to be run off of a actual web server because they use a downloader object for a zip file. So if you upload the files to a remote server you have access to they will work or if you have a local server running on your PC this will work as well. For instance if you have IIS installed, you can place the files in C:\Inetpub\wwwroot\silverlight\image_viewer2 and then browse to http://localhost/silverlight/image_viewer2 you will be able to view the samples on your machine.
The version9 example has an RSS reader as part of the demo which utilizes the a .php proxy script (the proxy.php file in the example) to retrieve an XML feed from Yahoo news. So this example will need to run specifically off of a php enabled server. But you can also use .asp or any other backend language of your choice to do the same thing.
10-18-2007 11:26 PM |
Hi,
Yes, Ddobbs. You are pro. I have done OK. It was wonderful, pretty and professional. I also learn more the Silverlight technology. And certainly I always visit on vectorform/Silverlight. Hope that I will be viewing a lot of samples on it. However, I expect you can be able to explain generally about Tween.js file. For example, could you tell me know how it works, please?
Thanks so much to you.
Best regard.
10-19-2007 9:50 AM |
cukingoi, Tween.js is a very nice animation library for Javascript written by Philippe Maegerman. Documentation and examples can be found here:
http://jstween.blogspot.com/
You can use it to manipulate any numerical property you wish (position,scale,opacity,etc) over time with simple event calls.
There are other Javascript animation libraries as well like JSTweener, which can be found here: http://code.google.com/p/tweener/
10-22-2007 10:22 PM |
Oh, greating with your guiding and introduction. Helping me so much. Thanks a lot all.