Quantcast
Channel: First steps - JuliaLang
Viewing all articles
Browse latest Browse all 2795

Include, using, export

$
0
0

@erlebach wrote:

Hi,

I wish to put experimental code in another file, call “TestFile”, and this file contains a function “TestFunction”. In my Main file called “main.jl”, I wish to access the function “TestFunction”. How do I do it? I tried

include("TestFile.jl")

and get the message “Could not open the file TestFile” or something similar.
What is the easiest approach? Both the file “main.jl” and “TestFile.jl” are in the same directory, and I thought the current directory would automatically be in the LOAD_PATH.

Thanks for any help! I have read the various discussions on the subject.

Posts: 2

Participants: 2

Read full topic


Viewing all articles
Browse latest Browse all 2795

Latest Images

Trending Articles



Latest Images