Trying to run remote command to view AS/400 UNC and failing!

5020 pts.
Tags:
CSV
Microsoft Excel
RPG
UNC
UNC path
I need some ideas here...I'm stuck. I'm running an RPG program that builds some CSV files for our accounting department. Because they love Excel, I had to make it so that the program breaks the data up into separate CSV files so as not to exceed 65,535 rows. Anyway, I am saving the stream files into a shared folder under QOpenSys on my i5 515. When the program is done, it tries to execute a command on the PC "start explorer.exe \[ip address]Accounting$", where the accounting folder is the share on the 515. This works if the user (currently me for testing) has tried to access any share on the 515 through Windows at least once prior, since Windows prompts for a user name and password. But, when my RPG program does this, sometimes it silently fails on the PC, only opening the MS-DOS prompt long enough to blink and then nothing. Other times we clicked around and tried typing in the UNC path the the 515 and it finally asked us for a username and password. I wanted to make this easy for my users to be presented with the data as soon as it is done so they can continue to work with it. But if they have to jump through hoops I fear it will not really help them. Currently I am using STRPCO, and STRPCCMD. I tried with RUNRMTCMD, but don't like the fact that I would have to physically 'touch' each PC to make sure the service is running and allowed to interact with their Desktops. Is there any way for me to cause the user to be prompted for their sign on and password instead of this just blowing up silently? Any advice? Thanks!!

Answer Wiki

Thanks. We'll let you know when a new response is added.

Make sure Windows and AS/400 Peofile are in synch. Same yserid and password and should be no problem accessing share

Discuss This Question: 5  Replies

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
  • Koohiisan
    Oh, and I also experimented with using QNTC to access the accounting department's domain network share which resides on a Windows 2003 server, but because all of our usernames on the 515 are different than the usernames on our domain, it shows our server in WRKLNK '/QNTC/*', but can't access any shares. :( I'd be happy if I can just get it to them somewhere secure (not a wide-open share with no security)!! FTP won't work because our FTP server is a totally separate machine and the users won't be able to get to it. :(
    5,020 pointsBadges:
    report
  • Gilly400
    Hi, Coudn't you give the users a link to the share for on their desktop, then show a popup message to let them know that their files are ready from the AS400? By the way, what's a UNC path? Regards, Martin Gilbert.
    23,730 pointsBadges:
    report
  • Cwc
    I've not had good success with connecting to individual user PCs from a process initiated from the "i", although I'm sure there's a way to reliably accomplish. So here's another approach - what about initiating the process from the client side, which could connect to the i and then execute your program via a stored procedure? After the program/procedure has completed, the client side would run the command to open Explorer. As far as how to do this, I'm thinking a small .Net or Java class could accomplish, or perhaps it could be done in a script or batch file? [Martin, FYI - UNC stands for Uniform Naming Convention, with two slashes before the server name followed by a single slash, and then the path name to the file. Ex: //MyServer/MyDirectory/MyNextDirectory/MyFileName.csv )
    4,290 pointsBadges:
    report
  • TomLiotta
    ...but don't like the fact that I would have to physically 'touch' each PC to make sure the service is running and allowed to interact with their Desktops. But you'll use a function that can silently and remotely execute any process on any connected users' PCs under those users' identities without even authentication? I take it that you're not subject to audits or that your auditors are unaware of what STRPCCMD can do. No one can argue that RUNRMTCMD doesn't take preparatory planning and work. OTOH, it might be better to do as much of it as possible before it's mandated. Have you set up a NetServer GUEST profile? You might create your output in the only directory that GUEST is authorized to, and have *PUBLIC authorized as well. Then it might not matter if a previous signon had been done. Previous signons wouldn't be an issue; mismatched profiles should work as GUEST. Tom
    125,585 pointsBadges:
    report
  • graybeard52
    Another option might be to copy the files to a Windows server and let the clients access it from there. Then Windows security would be in place and control access.
    3,115 pointsBadges:
    report

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Thanks! We'll email you when relevant content is added and updated.

Following