Esempio n. 1
0
        void Target_FileUpload(Target sender, FileUploadEventArgs args)
        {
            MemoryStream stream = new MemoryStream(args.Data);
            Document     doc    = Manager.CreateDocument(args.FileName, null, stream);

            stream.Dispose();

            if (doc != null)
            {
                Manager.ShowDocument(doc);
            }
        }
Esempio n. 2
0
 void realHost_FileUpload(ITarget host, FileUploadEventArgs args)
 {
     if (mForm != null && mForm.IsHandleCreated)
     {
         mForm.BeginInvoke(new MethodInvoker(delegate()
         {
             if (this.FileUpload != null)
             {
                 this.FileUpload(this, args);
             }
         }));
     }
 }
Esempio n. 3
0
        void OnFileUpload(string fileName, byte [] data)
        {
            FileUploadEventArgs args = new FileUploadEventArgs(fileName, data);

            if (mForm != null && mForm.IsHandleCreated)
            {
                mForm.BeginInvoke(new MethodInvoker(delegate()
                {
                    if (this.FileUpload != null)
                    {
                        this.FileUpload(this, args);
                    }
                }));
            }
        }
Esempio n. 4
0
		void Target_FileUpload(Target sender, FileUploadEventArgs args)
		{
			MemoryStream stream = new MemoryStream(args.Data);
			Document doc = Manager.CreateDocument(args.FileName, null, stream);
			stream.Dispose();

			if(doc != null)
				Manager.ShowDocument(doc);
		}
Esempio n. 5
0
		void realHost_FileUpload(ITarget host, FileUploadEventArgs args)
		{
			if (mForm != null && mForm.IsHandleCreated)
				mForm.BeginInvoke(new MethodInvoker(delegate()
				{
					if (this.FileUpload != null)
						this.FileUpload(this, args);
				}));
		}
Esempio n. 6
0
		void OnFileUpload(string fileName, byte [] data)
		{
			FileUploadEventArgs args = new FileUploadEventArgs(fileName, data);
			if (mForm != null && mForm.IsHandleCreated)
				mForm.BeginInvoke(new MethodInvoker(delegate()
				{
					if (this.FileUpload != null)
						this.FileUpload(this, args);
				}));
		}