MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

How to open file in MVS using C/C++

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> CICS and Middleware
View previous topic :: View next topic  
Author Message
Nimesh Srivastava
Beginner


Joined: 22 Jul 2003
Posts: 13
Topics: 8

PostPosted: Fri Jul 25, 2003 3:22 am    Post subject: How to open file in MVS using C/C++ Reply with quote

Hi,
I am trying to open a file in MVS env using C/C++ standard fopen command. Is is possible to open a file using fopen in MVS.
I tried for both a PDS member and a PS fileset, but it failed.
The command I gave was
FILE *fp = fopen("DD:NCS.DBS.TSTFLE","r"); for PS
and
FILE *fp = fopen("DD:NCS.DBS.SOURCE(TSTFLE)","r"); for PDS
they both failed.
Can anybody please help me on this???
Back to top
View user's profile Send private message Send e-mail
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12378
Topics: 75
Location: San Jose

PostPosted: Fri Jul 25, 2003 4:13 pm    Post subject: Reply with quote

Nimesh Srivastava,

Check this link for a detailed explanation on opening files in C/C++

http://publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/BOOKS/CBCPG110/2.9.1?SHELF=CBCBS110&DT=20010621125536


Hope this helps...

cheers

kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Nimesh Srivastava
Beginner


Joined: 22 Jul 2003
Posts: 13
Topics: 8

PostPosted: Sun Jul 27, 2003 11:57 pm    Post subject: Reply with quote

Thanks kolusu,
I tried on
fp = fopen("\'NCS.DBS.TSTFLE\'","r");
and I was able to open the PS file in MVS env
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> CICS and Middleware All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group