PxPlus User Forum

Twitter Twitter Twitter

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Peter.Higgins

Pages: [1] 2 3 ... 8
1
Programming / Server parameter in CALL "*web/sftp;receive"
« on: January 05, 2023, 11:49:32 AM »
Server parameter in CALL "*web/sftp;receive" is confusing me somewhat. 
I recently implemented a client with Id/Password where the domain:port only worked as domain;port. (Delimiter = Semi-Colon)
The next client using a cert only works with domain:port.
Is there a way to know when to use a certain delimiter in the domain sent? 

2
Language / Re: Key function - Key Generate
« on: December 06, 2022, 12:34:40 PM »
Thank you Mike,
All good reasons to use the internally keyed files for new stuff.   

3
Language / Key function - Key Generate
« on: December 05, 2022, 06:52:16 PM »
The really useful part of this functions Key Generate is not having to enumerate alternate keys for padding. 
But it does not return a complete key padded for trailing empty fields in external key files as shown below. 
I haven't checked it yet against the internal files as empty trailing fields are less likely by design.
So enumeration of keys or hard coding padding data may still be necessary.
Wondering if I am missing something here? 
I would expect and prefer to mid/stp the result if a partial key was wanted.
Still on Version 1410. 

01 OPEN (1)"OP9002" ! External Prime key file, Key 3 is 4 Fields, 33 bytes - 20:7:2:4
02 cmd$="key(1,key=""00190579172397"":""5850720"":""  "":""    "",kno=3)"
03 x$=EVS(cmd$)
04 PRINT HTA(x$)
05 PRINT LEN(x$)
06 cmd$="key(1,key=""00190579172397"":""5850720"":"""":"""",kno=3)"
07 x$=EVS(cmd$)
08 PRINT HTA(x$)
09 PRINT LEN(x$)
10 cmd$="key(1,key=""00190579172397"":""5850720"",kno=3)"
11 x$=EVS(cmd$)
12 PRINT HTA(x$)
13 PRINT LEN(x$)
14 CLOSE (1)
15 END

-;run
303031393035373931373233393700000000000035383530373230202020202020
 33
3030313930353739313732333937000000000000353835303732300000
 29
303031393035373931373233393700000000000035383530373230
 27

4
Programming / Re: Reverse or limit VER *
« on: August 11, 2022, 03:56:15 PM »
Yes that was useful to set the 50 limit when someone who made frequent saves joined the crew. ::)

5
Programming / Reverse or limit VER *
« on: August 10, 2022, 05:29:54 PM »
For a while we've been able to VER 2 for instance to get the date/Time/Version number of a program.  This has stopped working recently.  Since the system program count is set a 50, VER * is pretty much useless as it only shows the last 10 lines or so.  Is there a way to limit or reverse the list?

6
Programming / Reverse or limit VER *
« on: August 10, 2022, 05:28:40 PM »
For a while we've been able to VER 2 for instance to get the date/Time/Version number of a program and it has stopped working in the last couple of weeks.  Since the program count is set a 50, VER * is pretty much useless as it only shows the last 10 lines or so.  Is there a way to limit or reverse the list?

7
Programming / Re: Composite String Record behaviour in an object.
« on: August 09, 2022, 12:55:29 PM »
Mike,
Its a typo and should be str(AAARecord.RoadsideAssistenceNumber$ or str(Phone$ 
The summary is in an Object, composite strings for AAA$ & AAARec$ work but AAARecord$ will not. 
AAA is a place holder for a number of file names fortunately all 3 letters. 
Please note on the system in question that AAARecord.RoadsideAssistenceNumber$ works in a run or called program just not in objects.

8
Programming / Composite String Record behaviour in an object.
« on: August 09, 2022, 12:24:26 PM »
I use records frequently as object parameters and find the structure neither remains after the enter, or in a local variable.  So I must do the following in every method. Except I've found debugging that a variable of len 9 will not return data from a composite string although the structure is there. Note: I have not played with how long a variable still works.   Curious if I missed something in documentation,  if this is unusual  behavior, or just an object limitation?  version 2017 on Linux.

! Doesn't work
ENTER (FILEREC$),(FILEIOL$)
DIM AAARecord$:fileiol$
AAARecord$=FILEREC$
phone$=AAA.RoadsideAssistenceNumber$
? lst(iol(AAARecord$))  ! will show Structure. 
? str(AAA.RoadsideAssistenceNumber$:"xxx-xxx-xxxx")
   -   -   

! This works
ENTER (FILEREC$),(FILEIOL$)
DIM AAA$:fileiol$
AAA$=FILEREC$
phone$=AAA.RoadsideAssistenceNumber$
? str(phone$:"xxx-xxx-xxxx")
888-888-8888

9
Programming / Re: UNT & HFN returning -1
« on: July 21, 2022, 08:29:39 PM »
Thanks James,
You are correct.  I followed the example in HFN below and it is messed up.  Its been a long time, maybe 20 years since I've had to explicitly set XF.

set_param -'XF'
?hfn
32767

 

10
Programming / Re: UNT & HFN returning -1
« on: July 21, 2022, 03:57:23 PM »
James,  -'XF' at the time and place of the -1

11
Programming / UNT & HFN returning -1
« on: July 21, 2022, 03:27:27 PM »
This is a new one in my experience.  I'm wondering why I am getting this from these two functions.  It is 5 levels into an object stack when the file handles appear to run out, but chn doesn't span more than 1 and half lines.  Same code has been running for a week with this object on thousands of imports for another project without this error occurring.

12
Programming / Re: *web/sftp directory delimiters
« on: July 21, 2022, 03:21:17 PM »
Devon,
The delimiter editing is likely a curl thing.  I removed the *.* from /PO/OUT/*.* and the delimiter started disappearing in the remote log.  I added the escape /PO/OUT\/ from the earlier curl question this year which I did not find until after asking.  The remote network reported the path had the trailing delimiter with escape added, but still no joy.  Almost certainly the remote network's issue because the code works everywhere else we connect.

13
Programming / *web/sftp directory delimiters
« on: July 21, 2022, 01:30:50 PM »
In a continuing battle to connect to a specific network I and being asked to add a trailing delimiter to the directory path.  This is stripped by the sftp program.  Is there a way to escape the final path delimiter.

14
Programming / Re: error handling in objects
« on: July 21, 2022, 01:25:26 PM »
Thanks Mike,
The goal is to not do an exit err or escape err which triggers the main error handler.  Just silently return messages so they can be logged unless an exit err or escape err is put into the object for critical tasks.  Perhaps I've over thought this and a generic return on the seterr procedure will work?

15
Programming / error handling in objects
« on: July 17, 2022, 10:59:56 AM »
If the goal is to capture the minor errors in an object create or a method, is there a way to use SETERR and do a proper return integer/string to the stack?  I am looking to save the errNumber and ErrMessage$ and suppress error processing from an escape err or exit err in the stack program so they can handle the error as required.  I can do this using TRY or EVN/EVS encapsulation but it would require extensive additions to every object method of which there are around 100 objects and unknown qty of methods and anticipating all possible errors is not likely.

Pages: [1] 2 3 ... 8