VS2005入れてVisual C#でFlash呼び出し その3
ウィンドウを透明にして、Flashを再生してみました。
まぁ、これがガジェットってやつだと思います。
using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Text; using System.Windows.Forms; using AxShockwaveFlashObjects; namespace WindowsApplication1 { public partial class Form1 : Form { AxShockwaveFlash flash = null; public Form1() { InitializeComponent(); } private void Form1_Load(object sender, EventArgs e) { this.FormBorderStyle = FormBorderStyle.None; this.Size = new Size(500, 300); this.TransparencyKey = Color.Black; this.flash = new AxShockwaveFlash(); ((ISupportInitialize)(this.flash)).BeginInit(); this.Controls.Add(this.flash); ((ISupportInitialize)(this.flash)).EndInit(); this.flash.SetBounds(0, 0, 500, 300); this.flash.LoadMovie(0, "http://www.classmethod.jp/images/jp/top/top.swf"); this.flash.Play(); } } }
次ももうちょっとやってみます。