Home > Ask the AS/400 Experts > iSeries i5/OS and OS/400 Questions & Answers > Creating a user profile from a file
Ask The iSeries 400 Expert: Questions & Answers
EMAIL THIS

Creating a user profile from a file

Ken Graap EXPERT RESPONSE FROM: Ken Graap

Pose a Question
Other iSeries 400 Categories
Meet all iSeries 400 Experts
Become an Expert for this site


Digg This!    StumbleUpon Toolbar StumbleUpon    Bookmark with Delicious Del.icio.us   


>
QUESTION POSED ON: 31 July 2007
I am writing a program to create user profile from a file. For OUTQ, INLPGM, INLMENU, I get error: CPD0078. The value for parameter is not a valid name.

Here is how I built the parameters:

DCL &INLPGM TYPE(*CHAR) LEN(21)

Then I dumped the copy from user profile to an outfile:

If &UPINPG = '*NONE', then &INPPGM = *none Else do chgvar &INLPGM value(&upinpl *TCAT '/' *TCAT &upinpg)

What can I do to fix this error?


>
EXPERT RESPONSE
A program name can only be 10 characters long.

Change &INLPGM to LEN(10) ... If &INLPGM is being passed to the program as Library/ProgramName, then you will need to use the %SST function to break it into two parameters.

For example:

DCL        VAR(&OUTQ) TYPE(*CHAR) LEN(20) 

DCL        VAR(&OUTQNAME) TYPE(*CHAR) LEN(10)
DCL        VAR(&OUTQLIB) TYPE(*CHAR) LEN(10) 

CHGVAR     VAR(&OUTQNAME) VALUE(%SST(&OUTQ 1 10)) 
CHGVAR     VAR(&OUTQLIB) VALUE(%SST(&OUTQ 11 10))

Good Luck!


Digg This!    StumbleUpon Toolbar StumbleUpon    Bookmark with Delicious Del.icio.us   


RELATED CONTENT
iSeries i5/OS and OS/400
Restricting specific user command line access
Print private authorities (PRTPVTAUT) command for user objects in a library with *public exclude
Getting modules to adopt authorities from the main program
Copying a physical file back to a spool file
See who's browsing secret file records
Finding the value for the 'message key' parameter
Writing a spool file directly to an optical drive
Storing system documentation on the iSeries
Setting up journals
Error message within the printer file

iSeries programming commands
Date calculation commands for AS/400
Monitoring escape messages and using RCVMSG for diagnostic messages
iSeries application display subfiles with other program windows
DSPPGMREF (Display Program Reference)
DSPPGM (Display Program)
DSPFD (Display File Description)
DSPPTF (Display PTF)
Top 10 iSeries commands
WRKACTJOB (Work with Active Jobs)
WRKOBJLCK (Work with Object Locks)
iSeries programming commands Research

RELATED GLOSSARY TERMS
Terms from Whatis.com − the technology online dictionary
Quiz: iSeries (AS/400) Commands  (Search400.com)

RELATED RESOURCES
2020software.com, trial software downloads for accounting software, ERP software, CRM software and business software systems
Search Bitpipe.com for the latest white papers and business webcasts
Whatis.com, the online computer dictionary



Search and Browse the Expert Answer Center
Search and browse more than 25,000 question and answer pairs from more than 250 TechTarget industry experts.
Browse our Expert Advice



iSeries Networking - Printing, Remote Access, TCP/IP
HomeNewsTopicsITKnowledge ExchangeTipsBlogsAsk the ExpertsMultimediaWhite PapersProducts
About Us  |  Contact Us  |  For Advertisers  |  For Business Partners  |  Site Index  |  RSS
SEARCH 
TechTarget provides enterprise IT professionals with the information they need to perform their jobs - from developing strategy, to making cost-effective IT purchase decisions and managing their organizations' IT projects - with its network of technology-specific Web sites, events and magazines.

TechTarget Corporate Web Site  |  Media Kits  |  Reprints  |  Site Map




All Rights Reserved, Copyright 1999 - 2008, TechTarget | Read our Privacy Policy
  TechTarget - The IT Media ROI Experts