Re: Procedurally adding attributes to ST SET ATTRIBUTES

2017-09-21 Thread Pat Bensky via 4D_Tech
Yeah ... I was thinking along similar lines but I need a more efficient way to do it, as we're building large documents and each paragraph of text will have a style applied to it. I'm thinking of doing something with key-pair two-dimensional arrays. I'll experiment with that idea. Pat On 21

Re: METHOD OPEN PATH Equivalent For Forms

2017-09-21 Thread Cannon Smith via 4D_Tech
Ah yes, essentially what I’m trying to do. Thanks anyway. -- Cannon.Smith Synergy Farm Solutions Inc. Hill Spring, AB Canada 403-626-3236 > On Sep 21, 2017, at 1:52 PM, Douglas von Roeder via 4D_Tech > <4d_tech@lists.4d.com> wrote: > > Not that I've been

Re: METHOD OPEN PATH Equivalent For Forms

2017-09-21 Thread Douglas von Roeder via 4D_Tech
Cannon: Not that I've been able to figure out. I use MOP in my "workspace palette" which allows me to create groups of methods that pertain to each issue that I work on. By clicking on a workspace name, all of the methods windows open or I can open them individually. I'd love to be able to

METHOD OPEN PATH Equivalent For Forms

2017-09-21 Thread Cannon Smith via 4D_Tech
It can be helpful to programmatically open a method editor window for a method using METHOD OPEN PATH. I’d like to do the same thing with forms. Is there a way to programmatically open a form in a form editing window? Thanks. -- Cannon.Smith Synergy Farm Solutions Inc. Hill Spring, AB Canada

Re: Procedurally adding attributes to ST SET ATTRIBUTES

2017-09-21 Thread John DeSoi via 4D_Tech
The easiest way would be to put your style attributes and values in an object (or arrays) and then loop over them calling ST SET ATTRIBUTES. For example, here is what I use to clear all font styles: ARRAY LONGINT($aStyle;0) ARRAY_Append_integer (->$aStyle;Attribute bold style;Attribute italic

Re: PostgreSQL SELECT... RETURNING ID

2017-09-21 Thread Jeffrey Kain via 4D_Tech
Ahh, thanks for the clarification (and to Dave Adams). That makes sense. We'll stick with the 'returning' clause. -- Jeffrey Kain jeffrey.k...@gmail.com > On Sep 21, 2017, at 1:23 PM, John DeSoi via 4D_Tech <4d_tech@lists.4d.com> > wrote: > > PgSQL Get Last Insert Row ID is not the same thing

Re: Command numbers and names and using Execute

2017-09-21 Thread Pat Bensky via 4D_Tech
FYI - in V15 and later you don't need to bother with the command numbers any more: " Compatibility note: Since a command name may vary from one 4D version to the next (commands renamed), this command was used in previous versions of the program to designate a command directly by means of its

Re: PostgreSQL SELECT... RETURNING ID

2017-09-21 Thread John DeSoi via 4D_Tech
PgSQL Get Last Insert Row ID is not the same thing - it returns the OID (object identifier) for the row. OIDs are depreciated and not created by default for a table unless you include WITH OIDS in your CREATE TABLE statement (or change the parameter default). Assuming what you are after is the

Re: PostgreSQL SELECT... RETURNING ID

2017-09-21 Thread Jeffrey Kain via 4D_Tech
Sorry- typo... > On Sep 21, 2017, at 1:01 PM, Alfonso Zafon via 4D_Tech <4d_tech@lists.4d.com> > wrote: > > The line > $rowset:=PgSQL Select ($lConnection;"";$lStatement) > > > is wrong ** 4D Internet Users Group (4D iNUG)

Re: PostgreSQL SELECT... RETURNING ID

2017-09-21 Thread Alfonso Zafon via 4D_Tech
Idemsoft-Alfonso Zafón The line $rowset:=PgSQL Select ($lConnection;"";$lStatement) is wrong must be: $rowset:=PgSQL Select ($lConnection;$lStatement) Saludos. idem Alfonso Zafón Tel:+34 963 455 103 Email: alfo...@idemsoft.com Web:

Re: PostgreSQL SELECT... RETURNING ID

2017-09-21 Thread Jeffrey Kain via 4D_Tech
Thanks everyone - Lee, you were right, there's a PgSQL Get Last Insert Row ID function that's also available in the plug-in. They seem to do the same thing. Jeff -- Jeffrey Kain jeffrey.k...@gmail.com > On Sep 21, 2017, at 12:54 PM, John DeSoi via 4D_Tech <4d_tech@lists.4d.com> > wrote: >

Re: PostgreSQL SELECT... RETURNING ID

2017-09-21 Thread John DeSoi via 4D_Tech
That should work without problems. PgSQL Select and PgSQL Execute mostly do the same things except Execute does not return rows. The "returning" clause makes it a set returning SQL command so PgSQL Select is the right plugin command. John DeSoi, Ph.D. > On Sep 21, 2017, at 9:37 AM, Jeffrey

Re: PostgreSQL SELECT... RETURNING ID

2017-09-21 Thread Alfonso Zafon via 4D_Tech
Idemsoft-Alfonso Zafón Hi, $tStatement:="INSERT INTO invoices (name, amount) VALUES ($tName,string($rAmount)) returning id" $rowset:=PgSQL Select ($lConnection;"";$lStatement) $lInvoiceID:=PgSQL Get Longint Column ($rowset;"id") This work form me. Saludos. idem Alfonso

Re: Command numbers and names and using Execute

2017-09-21 Thread Arnaud de Montard via 4D_Tech
> Le 21 sept. 2017 à 17:51, Nigel Greenlee via 4D_Tech <4d_tech@lists.4d.com> a > écrit : > > For ($i;1;1) //well i know there are less than 1 commands for the > next few years at least:) you can exit the loop when ok = 0, see here:

Re: PostgreSQL SELECT... RETURNING ID

2017-09-21 Thread Lee Hinde via 4D_Tech
I haven't used the Postgres plug-in, but the MySQL plugin has: *MySQL Get Last Insert Row ID* just for that purpose. Is there an equivalent? On Thu, Sep 21, 2017 at 7:37 AM, Jeffrey Kain via 4D_Tech < 4d_tech@lists.4d.com> wrote: > We're using the Pluggers PostgreSQL plug-in, and trying to

Re: Command numbers and names and using Execute

2017-09-21 Thread Paul Lovejoy via 4D_Tech
Thanks! > Le 21 sept. 2017 à 18:05, Keisuke Miyako via 4D_Tech <4d_tech@lists.4d.com> a > écrit : > > ARRAY TEXT is command #222 so you could do > > EXECUTE FORMULA(":C222(...)") > > C must be uppercase. > > c.f. > >

Re: Command numbers and names and using Execute

2017-09-21 Thread Paul Lovejoy via 4D_Tech
Thanks Nigel! > Le 21 sept. 2017 à 17:51, Nigel Greenlee via 4D_Tech <4d_tech@lists.4d.com> a > écrit : > > Paul. > > When i was writing my rather excellent(even though i say so myself) auto > variable declaring code I wanted the command and command numbers. I just > looked up what i did >

Re: Command numbers and names and using Execute

2017-09-21 Thread Keisuke Miyako via 4D_Tech
ARRAY TEXT is command #222 so you could do EXECUTE FORMULA(":C222(...)") C must be uppercase. c.f. http://doc.4d.com/4Dv16/4D/16.2/Using-tokens-in-formulas.300-3432926.en.html > 2017/09/22 0:34、Paul Lovejoy via 4D_Tech <4d_tech@lists.4d.com> のメール: > > I want to use the Execute command in a

Command numbers and names and using Execute

2017-09-21 Thread Paul Lovejoy via 4D_Tech
Hi everyone, I want to use the Execute command in a multi-lingual environment use it to execute 4D commands such as ARRAY TEXT(). Of course, this would fail as is on a French version of 4D. I believe there’s a way to use Execute() with the internal command numbers but I can’t find anything in

Procedurally adding attributes to ST SET ATTRIBUTES

2017-09-21 Thread Pat Bensky via 4D_Tech
I can't get my head around this :) I need to be able to procedurally build up an *ST SET ATTRIBUTES *statement. I have a number of styles - let's call them Style A, Style B, Style C. Style A might be built like this: Attribute font name;"Arial";Attribute text size;20;Attribute underline

Re: Configure SSL Web Server on 4Dv15

2017-09-21 Thread Andrea Angeli via 4D_Tech
Hi, Problem Solved. I hat to update openssl on OS X from 0.9.8 to 1.2 and now it works. I’m not sure if that information is clear in the documentation. Probably not for my english. Thanks in advance Andrea Angeli > Il giorno 21 set 2017, alle ore 09:34, Paul Dennis via 4D_Tech >

Re: Configure SSL Web Server on 4Dv15

2017-09-21 Thread Paul Dennis via 4D_Tech
Andrea, you would be better off running nginx on same windows proxy and proxy nginx https to 4D http. Faster and certs are easy with lets encrypt. -- Sent from: http://4d.1045681.n5.nabble.com/4D-Tech-f1376241.html ** 4D

RE: Configure SSL Web Server on 4Dv15

2017-09-21 Thread Epperlein, Lutz (agendo) via 4D_Tech
Hi Andrea Look here: http://forums.4d.com/Post/DE/17153654/1/17153655#17153779 (in German, but you can translate it in a good quality with https://www.deepl.com/translator). Here is it done for you: --- The certificates must be in "pem" format, see: