As a part of a project i am working on, we have a WinForm application that has a Web Browser control on it. from that control, I am calling an html file that will be in a shared folder on a local network. in that folder, there are also various images, of which a client may want to switch out from time to time.
All that is fine, but i am trying to use the html document, with some javascript to refresh, look in that folder, load all the images, and use sliderman.js to present these images as a slideshow. I am not all too familiar with javascript, but basically, in pseudo-code, this is what i am trying to accomplish:
<html>
<body>
<script type="text/javascript">
function PageRefreshTimer(){
}
function GetFiles(){
//gets files from local network location (ie: \\192.168.1.2\sharedfolder)
for each file in folder {
//add <img> tag to page for the image
}
}
</script>
</body>
</html>
what i have accomplished so far is this:
<div id="slider_container_3">
<div id="SliderName_3" class="SliderName_3">
<!-- images will be inserted here -->
<script type="text/javascript">
window.alert("found script");
if (window.File && window.FileReader && window.FileList && window.Blob) {
//do your stuff!
} else {
alert('The File APIs are not fully supported by your browser.');
}
</script>
<img src="../01.jpg" width="800" height="200" alt="" title="" />
<img src="../02.jpg" width="800" height="200" alt="" title="" />
</div>
<div class="c"></div>
<script type="text/javascript">
//scripting for sliderman.js
demo3Effect1 = {name: 'myEffect31', top: true, move: true, duration: 400};
demo3Effect2 = {name: 'myEffect32', right: true, move: true, duration: 400};
demo3Effect3 = {name: 'myEffect33', bottom: true, move: true, duration: 400};
demo3Effect4 = {name: 'myEffect34', left: true, move: true, duration: 400};
demo3Effect5 = {name: 'myEffect35', rows: 3, cols: 9, delay: 50, duration: 100, order: 'random', fade: true};
demo3Effect6 = {name: 'myEffect36', rows: 2, cols: 4, delay: 100, duration: 400, order: 'random', fade: true, chess: true};
effectsDemo3 = [demo3Effect1,demo3Effect2,demo3Effect3,demo3Effect4,demo3Effect5,demo3Effect6,'blinds'];
var demoSlider_3 = Sliderman.slider({container: 'SliderName_3', width: 800, height: 200, effects: effectsDemo3, display: {autoplay: 10000}});
</script>
<div class="c"></div>
</div>
if i have tags in there already, it runs the slideshow as it is supposed to. However, when it reaches the check to see if it supports the the API in the program class, it sends the message that it is not supported. Any reasoning behind this?
Is this just due to a lack of support for the API in the C# Web Browser control?