Beispiel #1
0
        public int EnterTestMode()
        {
            int nres;

            nres = SmartComm2.SmartComm_GetStatus((long)hsmartprinterid, m_nTestModeSet);
            if (nres == SmartComm2.SM_SUCCESS)
            {
                m_nTestModeSet &= SmartComm2.SMSC_S_TESTMODE;
                if (m_nTestModeSet == 0x00)
                {
                    nres = SmartComm2.SmartCommEx_ToggleTestMode((long)hsmartprinterid);
                }
            }

            return(nres);
        }
Beispiel #2
0
        public int ExitTestMode()
        {
            int   nres;
            Int64 uis = SMSC_S_TESTMODE;

            nres = SmartComm2.SmartComm_GetStatus((long)hsmartprinterid, (long)uis);
            if (nres == SmartComm2.SM_SUCCESS)
            {
                uis &= SmartComm2.SMSC_S_TESTMODE;
                if (m_nTestModeSet != uis)
                {
                    nres = SmartComm2.SmartCommEx_ToggleTestMode((long)hsmartprinterid);
                }
            }

            return(nres);
        }