4D Write v15 plugin problem

2018-07-10 Thread David Rose via 4D_Tech
In a v15.6 client/server application for Windows, I have a license for 4D Write attached to the 4D Server license. I just moved all of the 4D server components to a new machine, including the licenses. They are definitely in the right Licenses folder. When I launch 4D Server and go to Update Lice

Re: 4D Write v15 plugin problem

2018-07-10 Thread Charles Miller via 4D_Tech
Are you sure you moved plug ins and not alias/shortcuts to them You are always better off re-licensing as opposed to moving. If you ever need to uphgrade number of clients, I think you will need to re-license then. I would also try re-license Regards Chuck On Tue, Jul 10, 2018 at 12:15 PM, D

Component scope question

2018-07-10 Thread Chip Scheide via 4D_Tech
In a multi-process 4D, less then version v16, environment (not multi-threaded), 4D stand alone (single user) or C/S (client side), - a component is loaded. - In process 1 the component is called, and (internal to the component) a process var (x) is set to value "A" - In process 2 the component i

Re: Component scope question

2018-07-10 Thread Dani Beaubien via 4D_Tech
Each component has it’s own namespace for it’s variables. They behave exactly as they would as per 4D Rules. Interprocess vars have a scope across all processes, process vars only have scope with the specific process. So in your example, that process var in process 1 would be “A” and in process

Re: Component scope question

2018-07-10 Thread Charles Miller via 4D_Tech
Further you need to use pointers into the compnent to get value. That is a guard against the following In host db you have a variable named Version_txt which is set to “10.5 4D version x.x” You can have a variable named Version_txt in the component with a different setting for example “1.5 4D ver

Re: Component scope question

2018-07-10 Thread Chip Scheide via 4D_Tech
IP vars inside a component does that make any reference to the component code (or at least methods that use/reference the IPVars) NOT thread safe? or is the component 'walled off' for this consideration? On Tue, 10 Jul 2018 13:30:27 -0400, Charles Miller via 4D_Tech wrote: > Further you need to

RE: Component scope question

2018-07-10 Thread Timothy Penner via 4D_Tech
> IP vars inside a component does that make any reference to the component code > (or at least methods that use/reference the IPVars) NOT thread safe? or is > the component 'walled off' for this consideration? IP vars are not thread safe, so the component method could not be marked as thread sa

Drag n drop between processes

2018-07-10 Thread Chip Scheide via 4D_Tech
Context: dragging 1 (or more) records/rows from a selection listbox to another form in another process. 4D v13. I know, and can see by using GET PASTEBOARD DATA TYPE, and GET PASTEBOARD DATA that if I drag a line/record from a selection listbox to another process there is "stuff" put on the pa

SQL Statement Assistance

2018-07-10 Thread Stephen J. Orth via 4D_Tech
Hoping someone can point me in the right direction regarding querying a date/time field in a SQL database: I built the following query for testing purposes and it works just fine, returning the correct results: Begin SQL

RE: SQL Statement Assistance

2018-07-10 Thread Timothy Penner via 4D_Tech
How about? - Using the TS syntax as described here: http://kb.4d.com/assetid=75947 - Using CAST to cast the TEXT as a Timestamp: http://doc.4d.com/4Dv15/4D/15/CAST.300-2288162.en.html http://kb.4d.com/assetid=75047 - Using a C_DATE variable instead of a _CTEXT variable -Tim *

RE: SQL Statement Assistance

2018-07-10 Thread Stephen J. Orth via 4D_Tech
Tim, Thanks... I already tried using CAST, but that made no difference. I'll check out the other link, and revisit the CAST link. Steve -Original Message- From: Timothy Penner [mailto:tpen...@4d.com] Sent: Tuesday, July 10, 2018 1:18 PM To: s.o...@the-aquila-group.com; 4D iNug Techn

RE: SQL Statement Assistance

2018-07-10 Thread Stephen J. Orth via 4D_Tech
Tim, I tried the following with no success: vt_temp1:="{ts '2018-04-06:58:00'}" vt_temp2:="{ts '2018-04-08:01:00'}" Begin SQL SELECT RecordID, Mach_ID, Energy_1, Energy_2, Energy_3 FROM DMM_TTX_HISTORIAN WHERE TimeStamp>=:vt_temp1 AND TimeStamp <= :vt_temp

Re: Drag n drop between processes

2018-07-10 Thread Keith Culotta via 4D_Tech
Hope this is on topic... During : (Form event=On Begin Drag Over) in the source list, I put the information about the item being dragged on the Pasteboard LOAD RECORD([Item]) C_OBJECT($obj) OB SET($obj;"$rec";Record number([Item])) O

RE: SQL Statement Assistance

2018-07-10 Thread Timothy Penner via 4D_Tech
There may be multiple things wrong here; First, is your field actually named TimeStamp? If so, this is a SQL Reserved word and shouldn’t be used as a field identifier. Let's start with that first. -Tim ** 4D Internet Users G

RE: SQL Statement Assistance

2018-07-10 Thread Stephen J. Orth via 4D_Tech
Tim, This is a MS SQL server database and it queries just fine using a static timestamp value, as shown below: Begin SQL SELECT RecordID, Mach_ID, Energy_1, Energy_2, Energy_3 FROM DMM_TTX_HISTORIAN WHERE TimeStamp >= '04/06/2018 07:58:00 AM' AND TimeStamp <= '04/06/2018 09:0

RE: Component scope question

2018-07-10 Thread Chip Scheide via 4D_Tech
figured as much... Thanks On Tue, 10 Jul 2018 17:37:46 +, Timothy Penner wrote: >> IP vars inside a component does that make any reference to the >> component code (or at least methods that use/reference the IPVars) >> NOT thread safe? or is the component 'walled off' for this >> considerat

Re: Drag n drop between processes - native Pasteboard only?

2018-07-10 Thread Chip Scheide via 4D_Tech
I was/am doing this through IP sets. Same idea - (to me, a bit easier and doable [v13]), copy the selected set to an IP set, access the IP set on the drop side. But I am trying to see where I can remove IP I thought I would look at NOT using sets at all. I seem to remember someone telling me tha

Re: SQL Statement Assistance

2018-07-10 Thread Charles Miller via 4D_Tech
Hi Steve, First can you do a sql call and add timestamp to return. Use cast as VARCHAR Begin SQL SELECT RecordID, Mach_ID, Energy_1, Energy_2, Energy_3, TimeStamp FROM DMM_TTX_HISTORIAN WHERE cast(TimeStamp as VARCHAR) >= '04/06/2018 07:58:00 AM' AND cast(TimeStamp as VARCH

RE: SQL Statement Assistance

2018-07-10 Thread Justin Will via 4D_Tech
Steve Try removing the single quotes in your text variable assignment and retry your initial example. Justin ** 4D Internet Users Group (4D iNUG) FAQ: http://lists.4d.com/faqnug.html Archive: http://lists.4d.com/archives.html

RE: SQL Statement Assistance

2018-07-10 Thread Timothy Penner via 4D_Tech
That looks like the field is just plain text; have you tried just removing the extra single quotes from the text variable in your initial example (Justin Will also suggested this)? vt_temp1:="04/06/2018 07:58:00 AM" vt_temp2:="04/06/2018 08:01:00 AM" Begin SQL SELECT Recor

RE: SQL Statement Assistance

2018-07-10 Thread Stephen J. Orth via 4D_Tech
Justin, Thanks... I've done that multiple times and nada. The error being returned by the driver is that it says you can't convert an "ntext" to "timestamp": Error Desc = Error #206 (Operand type clash: ntext is incompatible with datetim) I did not design the SQL database and don't real

RE: SQL Statement Assistance

2018-07-10 Thread Stephen J. Orth via 4D_Tech
Tim, See my response to Justin, I simply get an error back: Error Desc = Error #206 (Operand type clash: ntext is incompatible with datetim) How the heck do we query a timestamp field dynamically, this just seems much more difficult than it should be. Steve

RE: SQL Statement Assistance

2018-07-10 Thread Stephen J. Orth via 4D_Tech
Tim & Anyone Else, I got it working using the following: vt_temp1:="2018-04-06 11:09:00 AM" vt_temp2:="2018-04-06 11:12:00 AM" Begin SQL SELECT RecordID, Mach_ID, Energy_1, Energy_2, Energy_3 FROM DMM_TTX_HISTORIAN WHERE [TimeStamp] >= CONVERT(datetime,CONVERT(var

4D Write PRO: editing a table / collections

2018-07-10 Thread Two Way Communications via 4D_Tech
I love the concept of tables in 4D Write Pro. You can only add or change them by code, which is fine by me for the moment. But what to do if a table has been created, and, in the 4D Write Pro document, you would want to add a column, or a row? Or change the width, the borders etc? Apparently th

Re: 4D Write PRO: editing a table / collections

2018-07-10 Thread JOHN BAUGHMAN via 4D_Tech
Try putting the collection in a c_object and store the c_object in an c_object field, or put the collection directly into the c_object field I am assuming that $tableObj is the object reference to the table. If tables are anything like images, your plan might not work. Each time a document is

Re: 4D Write PRO: editing a table / collections

2018-07-10 Thread Randy Jaynes via 4D_Tech
Another thing we’re struggling with is that we’re building 4D WP documents using code and make tables so that the resulting area can be easily turned into an HTML email. Unfortunately, that makes the Write area awkward for a user to modify. It’s not easy to manipulate the tables (delete/add col

Re: Drag n drop between processes - native Pasteboard only?

2018-07-10 Thread Jeremy French via 4D_Tech
Hi Chip, You don't need to use sets. Follow Keith's scheme, but without using 4D objects (which were not available until v14.) On Begin Drag, place the record's unique key in the text pasteboard. Or if there's more than one record, store a delimited list of the record keys in the text pasteboa

Re: Drag n drop between processes

2018-07-10 Thread Keisuke Miyako via 4D_Tech
Hello, The 510 bytes data does not contain anything useful for you. You need to append data yourself at the drag source (append data to pasteboard), Which can be an array of record numbers/primary keys (variable to blob), A set (boolean array from set, variable to blob), Or anything that makes se

Re: 4D Write v15 plugin problem

2018-07-10 Thread Keisuke Miyako via 4D_Tech
You can not simply copy the licenses folder from one machine to another. The master product (4D or 4D Server) maybe recognised but the expansions (client, write, view, etc) will all be ignored. You must re-activate all the licenses on your new computer, starting from the server and including al