Example #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);
            }
        }
Example #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);
             }
         }));
     }
 }
Example #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);
                    }
                }));
            }
        }
Example #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);
		}
Example #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);
				}));
		}
Example #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);
				}));
		}