Global Variable

I want know the procedure to pass a value of a variable from one function to another.

1 件のコメント

Jiro Doke
Jiro Doke 2012 年 2 月 18 日
Why don't you pass it as an input argument of the function?

サインインしてコメントする。

回答 (1 件)

Prashant Somani
Prashant Somani 2012 年 2 月 18 日

0 投票

define it with global
Example:
function fn1()
global var1;
function fn2()
global var1

カテゴリ

ヘルプ センター および File ExchangeElectrical Block Libraries についてさらに検索

タグ

質問済み:

2012 年 2 月 18 日

Community Treasure Hunt

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

Start Hunting!

Translated by