카테고리 없음2014. 10. 7. 13:26

내가 짠 코드가 무분별하게 퍼지는 것을 막기위한 아주 사소한 장치...


function TimeLimitCode

[startdate checkpassword] = key;

startdate = datenum(startdate);

todaysdate = datenum(date);

if (todaysdate - startdate > 0) 

    password = inputdlg('Password:','Licensing for this product has expired',[1 55]);

    if strcmp(checkpassword,password)   % 라이센스가 만료되어도 password 입력으로 실행 가능하도록

        % Insert Main Code File Name

    else

        errordlg('Invalid password','Error');

        return

    end

else

    % Insert Main Code File Name

end



function [mydate, mypassword] = key

mydate       = '31-Dec-2014';

mypassword    = 'my password';; 

Posted by 오늘보다 나은 내일