?
Solved

How to get dspusrprf <user> to VB

Posted on 2010-11-15
4
Medium Priority
?
788 Views
Last Modified: 2012-05-10
Hi,

Can anyone help me to get the output of dspusrprf <user>  on as400 green screen to VB program,  I was trying to get this via Client Access Express (CWBX) but unable to get the output.

Regards
Shaminda
0
Comment
Question by:PMS-ICT
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 
LVL 35

Accepted Solution

by:
Gary Patterson earned 1000 total points
ID: 34139494
Sure.  Just specity the OUTPUT(*OUTFILE) option and the OUTFILE parameter to redirect output from this command to a database file.  Then query the file in your VB application using SQL (ODBC / ADO / ADO.NET)

http://publib.boulder.ibm.com/infocenter/iseries/v6r1m0/index.jsp?topic=/cl/dspusrprf.htm

DSPUSRPRF USRPRF(MYPROFILE) OUTPUT(*OUTFILE) OUTFILE(mylib/myfile)

- Gary Patterson
0
 
LVL 27

Assisted Solution

by:tliotta
tliotta earned 1000 total points
ID: 34139635
See the  cwbsoprf.h, cwbsousr.h and cwbsousg.h interface definitions for the System i Access cwbsoapi.dll in the Programmer's Toolkit. The Programmer's Toolkit is an install option of System i Access. If installed, access it through Start-> Programs-> IBM System i Access for Windows-> Programmer's Toolkit.

When opened, review the C/C++ APIs subtopic of the System i Operations topic.

It might be easier simply to code a program on AS/400 that returns the user profile attributes when you call it from VB.

Tom
0
 
LVL 143

Expert Comment

by:Guy Hengel [angelIII / a3]
ID: 34949764
This question has been classified as abandoned and is being closed as part of the Cleanup Program. See my comment at the end of the question for more details.
0

Featured Post

Veeam Task Manager for Hyper-V

Task Manager for Hyper-V provides critical information that allows you to monitor Hyper-V performance by displaying real-time views of CPU and memory at the individual VM-level, so you can quickly identify which VMs are using host resources.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When trying to find the cause of a problem in VBA or VB6 it's often valuable to know what procedures were executed prior to the error. You can use the Call Stack for that but it is often inadequate because it may show procedures you aren't intereste…
Enums (shorthand for ‘enumerations’) are not often used by programmers but they can be quite valuable when they are.  What are they? An Enum is just a type of variable like a string or an Integer, but in this case one that you create that contains…
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…
Suggested Courses

719 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question