Exemplo n.º 1
0
        public TwainHelper(Control ctr)
        {
            tw = new Twain();
            this.ctr = ctr;
            frm = ctr.FindForm();

            ctr.BackgroundImageLayout = ImageLayout.Stretch;
            tw.Init(ctr.Handle);
        }
Exemplo n.º 2
0
        public TwCapability(TwCap cap, short sval)
        {
            Cap     = (short)cap;
            ConType = (short)TwOn.One;
            Handle  = Twain.GlobalAlloc(0x42, 6);
            IntPtr pv = Twain.GlobalLock(Handle);

            Marshal.WriteInt16(pv, 0, (short)TwType.Int16);
            Marshal.WriteInt32(pv, 2, (int)sval);
            Twain.GlobalUnlock(Handle);
        }
Exemplo n.º 3
0
 public GetImageFormDevice()
 {
     InitializeComponent();
     tw = new Twain();
     tw.Init(this.Handle);
 }