- 신규로 표시
- 북마크
- 구독
- 소거
- RSS 피드 구독
- 강조
- 인쇄
- 부적절한 컨텐트 신고
I have maybe a trivial question, but however I can not fount the function in the manual.
I'm using a lot of files, so I want to use an unique file unit-number, not used somewhere else at the same time. Is there a method to proof if a file-unit is arlready used ?
I'm using a lot of files, so I want to use an unique file unit-number, not used somewhere else at the same time. Is there a method to proof if a file-unit is arlready used ?
링크가 복사됨
1 응답
- 신규로 표시
- 북마크
- 구독
- 소거
- RSS 피드 구독
- 강조
- 인쇄
- 부적절한 컨텐트 신고
[cpp]
integer*4 function get_free_file_unit_number integer*4, parameter :: first_unit= 10 integer*4, parameter :: last_unit =9999 logical*4 test do get_free_file_unit_number=first_unit,last_unit inquire(get_free_file_unit_number,opened=test) if (.not.test) return enddo get_free_file_unit_number=-1 end function[/cpp]
