Month function - License checkout failed

조회 수: 1 (최근 30일)
Martin Poulsen
Martin Poulsen 2019년 11월 28일
댓글: Walter Roberson 2020년 1월 3일
Hello
I am having an issue when i use the month() function from my GUI made in designer. When i call the function in the Command Window, it works fine, but when my GUI calls it, it says somthing about my license for Financial_Toolbox has expired. I have never used the toolbox and i did not think month() was a part of it. I get the following error
License checkout failed.
License Manager Error -10
Your license for Financial_Toolbox has expired.
If you are not using a trial license contact your License Administrator to obtain an updated license.
Otherwise, contact your Sales Representative for a trial extension.
  댓글 수: 1
Walter Roberson
Walter Roberson 2019년 11월 28일
month() is part of the Financial Toolbox.
But possibly you are using a datetime object: month() is also a method for datetime objects.
Is it possible that you are using load() inside the function that is having problems, and that you are are not assigning the result of load to a variable?
Or is it possible that the thing you are taking month() of is ending up as [] ?
Time to use the debugger.

댓글을 달려면 로그인하십시오.

답변 (1개)

Chidvi Modala
Chidvi Modala 2020년 1월 3일
“month” function is present in both MATLAB and Financial toolbox. Distinguishing the datatime method called “month”, from the Financial Toolbox function “month” requires knowing the input type. The analysis tracks variable types, but not for temporary variables without a name. If the datatime object is assigned a name, the analysis will correctly deduce the type and therefore calls the “method” function you require
You can make use of following code and it does not report a Finance Toolbox dependency
d = datetime(date);
thismonth = month(d);
  댓글 수: 2
Walter Roberson
Walter Roberson 2020년 1월 3일
Wuhhh???
How about cases like
foo.d = datetime(now);
thismonth = month(foo.d);
Is foo.d a temporary variable without a name?
This calls for more testing...
Walter Roberson
Walter Roberson 2020년 1월 3일
I'm liking my speculation of a load() without an assignment better. My testing so far is not consistent with the explanation of temporary variables versus named variables. On the other hand, I do not have any expired toolbox licenses to test with.

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Manage Products에 대해 자세히 알아보기

태그

제품


릴리스

R2019a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by