Re: Importing from camera

2019-07-08 Thread John DeSoi via 4D_Tech
Searching the knowledge base for "camera" turns up some tech notes. ftp://ftp.4d.com/ACI_TECHNICAL_NOTES/2015/TN_2015/15-01_CameraInterfaceR1.zip ftp://ftp.4d.com/ACI_TECHNICAL_NOTES/2016/TN_2016/16-16_CameraSurveillanceIn4D.zip John DeSoi, Ph.D. > On Jul 7, 2019, at 10:25 PM, JOHN BAUGHMAN

Re: The set does not exist

2019-07-07 Thread John DeSoi via 4D_Tech
There is the answer: "the data source is arrays". The highlight set only applies to selection (table) based list boxes. To get the highlighted rows of an array listbox, you use the True/False value of the boolean array representing the listbox. See the "Managing Selection" section on the page

Re: 'Clairvoyance' in listBox (v17r5)

2019-06-21 Thread John DeSoi via 4D_Tech
This was just discussed and requested on the Forums. Some examples were posted on how it can be done. http://forums.4d.com/Post/EN/30170877/1/30278226 Vote for the feature request here http://forums.4d.com/Post/EN/15446498/1/30188166 John DeSoi, Ph.D. > On Jun 21, 2019, at 12:00 PM, Chris

Re: Invalid JSON?

2019-06-02 Thread John DeSoi via 4D_Tech
What version of 4D? JSON Parse on what you provided below does not throw an error with 4D 17.1. John DeSoi, Ph.D. > On Jun 2, 2019, at 8:05 PM, JOHN BAUGHMAN via 4D_Tech <4d_tech@lists.4d.com> > wrote: > > I am getting the following from zip-codes.com… > > { > "item": { >

Re: Injecting Forms from a component

2019-05-23 Thread John DeSoi via 4D_Tech
> On May 23, 2019, at 10:26 AM, Chip Scheide via 4D_Tech <4d_tech@lists.4d.com> > wrote: > > I expect that you can do the same for table(s) via SQ, I have not tried. In addition to SQL, you can also use IMPORT STRUCTURE which is probably better in a lot of ways because you can do things like

Re: Managing 4D Server as a service

2019-05-10 Thread John DeSoi via 4D_Tech
> On May 9, 2019, at 4:25 PM, Tim Nevels via 4D_Tech <4d_tech@lists.4d.com> > wrote: > > Current 4D recommendations is to not use interact with desktop when running > 4D Server as a service and to handle everything yourself. Always install ON > ERR CALL method on everything that runs on 4D

Re: Capturing workstation timezone from the OS

2019-05-06 Thread John DeSoi via 4D_Tech
This gives the number of seconds offset from GMT. John DeSoi, Ph.D. $zDate:=Current date $str:=String($zDate;ISO date GMT;$zTime) //2010-09-13T16:11:53Z $str:=Substring($str;1;Length($str)-1) //Remove the Z or it gives us back local time. $gmtDate:=Date($str) $gmtTime:=Time($str) Case of

Re: 4D V15 crash

2019-05-03 Thread John DeSoi via 4D_Tech
Look at the crash log (should be in ~/Library/Logs/DiagnosticReports). It often gives helpful clues about what is causing the crash. John DeSoi, Ph.D. > On May 3, 2019, at 8:11 PM, Robert McKeever via 4D_Tech > <4d_tech@lists.4d.com> wrote: > > My client (4 time zones away), had been

Re: 4D 17.1 network issues

2019-05-03 Thread John DeSoi via 4D_Tech
You > should not have a real IP on ethernet connection and self assigned on > wifi. Something is not adding up > > Regards > Chuck > > On Wed, Apr 24, 2019 at 12:28 PM Peter Bozek via 4D_Tech > <4d_tech@lists.4d.com> wrote: >> >> On Wed, Apr 24, 2019 at 4:06

Re: Connecting to FTP

2019-04-30 Thread John DeSoi via 4D_Tech
h > <4d_tech@lists.4d.com> wrote: > > IT_SetPort returns 0. > > The FTP Login returns 10032 - Unknown or invalid response. > >> On Apr 30, 2019, at 5:32 PM, John DeSoi via 4D_Tech <4d_tech@lists.4d.com> >> wrote: >> >> Bob, >

Re: Connecting to FTP

2019-04-30 Thread John DeSoi via 4D_Tech
Bob, You need to use the IT_SetPort command. John DeSoi, Ph.D. > On Apr 30, 2019, at 6:49 PM, Robert McKeever via 4D_Tech > <4d_tech@lists.4d.com> wrote: > > I run an FTP server for my clients. All of the connections are secure FTP - > port . > > I can’t get the FTP_Login to work. I

Re: Using the HELP Menu for my own purposes.

2019-04-29 Thread John DeSoi via 4D_Tech
Vote for the feature request at the link below from 2007. I also requested it before the forum existed back in 1998. Don't hold your breath :). https://forums.4d.com/Post/FR/1510042/1/2352980 John DeSoi, Ph.D. > On Apr 28, 2019, at 5:51 PM, Herr Alexander Heintz via 4D_Tech >

Re: 4D 17.1 network issues

2019-04-24 Thread John DeSoi via 4D_Tech
It is a link-local address (see https://en.wikipedia.org/wiki/Link-local_address), sometimes called self-assigned. There is nothing wrong with DHCP. As I mentioned in the previous message, you get this for WiFi on the Mac when Wifi is not connected or marked as inactivated. Seems strange, but

Re: 4D 17.1 network issues

2019-04-24 Thread John DeSoi via 4D_Tech
Hi Spencer, > On Apr 24, 2019, at 8:29 AM, Spencer Hinsdale wrote: > > If you go to Apple menu, System Preferences on the mini, for Network do you > see more than one green dot? Each is separate network connection, where you > can click Advanced and go to TCP/IP tab for details. Is not

4D 17.1 network issues

2019-04-24 Thread John DeSoi via 4D_Tech
Since I upgraded from 16.4 to 17.1 (all Mac), users have been complaining about 4D Client disconnects. Messages like: "The current connection to the database has been disrupted. Connection error with the server. Please restart the application." "Unknown Error. Connection error with the server.

Re: ORDA and 4D selections

2019-04-10 Thread John DeSoi via 4D_Tech
Good points. The primary disadvantage in my opinion is the loss of table and field referencing because queries and other functions embed everything in strings. Understanding or modifying a large code base (especially if you did not write it) is going to be a lot harder with ORDA versus

Re: Auto Updating 4D Not Working

2019-04-08 Thread John DeSoi via 4D_Tech
Hi Cannon, It is working for me with 17.1. The 4D application is in the Applications folder and the update folder is a mounted disk image in the Downloads folder. If you are using other types of paths, maybe try something like that? Perhaps it could be a security restriction added by a recent

Re: Securing sensitive data in a 4D data file (Chip Scheide)

2019-04-01 Thread John DeSoi via 4D_Tech
On the Mac one option is to script storing the private key in the Keychain with LAUNCH EXTERNAL PROCESS. Type "man security" Terminal to see the command line interface options. John DeSoi, Ph.D. > On Mar 31, 2019, at 10:54 PM, Chip Scheide via 4D_Tech <4d_tech@lists.4d.com> > wrote: > > I

Re: Backup and journal file configurations

2019-03-25 Thread John DeSoi via 4D_Tech
> On Mar 25, 2019, at 5:11 PM, Tim Nevels via 4D_Tech <4d_tech@lists.4d.com> > wrote: > > When you are moving data files around between systems, just copy the entire > data file folder. That will have the .4DD, .4DIndx, .Match and .journal > files. If they are all in the same folder you can

Re: Getting a collection created from 4D function to work in Storage.

2019-03-20 Thread John DeSoi via 4D_Tech
The first line does nothing because you don't do anything with the function result of the call. The second line assigning $myTempVolumeCol to a copy returns a regular collection (see documentation). The error is because you can't assign a regular collection to a shared collection

Re: Apple Notary Service

2019-03-16 Thread John DeSoi via 4D_Tech
Does this really work (or might it break in the future) as 4D modifies the application package at runtime? I noticed that the code signature is no longer valid once you run the application (codesign --verify --verbose /path/to/application). John DeSoi, Ph.D. > On Mar 15, 2019, at 9:29 PM,

Re: "Attempting to retype using a pointer"

2019-02-28 Thread John DeSoi via 4D_Tech
Hi Chip, > > On Feb 28, 2019, at 9:12 AM, Chip Scheide <4d_o...@pghrepository.org> wrote: > > I see the issue -- The time array is NOT an array of Time > using v13 (no Time array) > so I had to use a longint array, or a time variable which points out > the problem. Version 13 is long dead and

Re: "Attempting to retype using a pointer"

2019-02-28 Thread John DeSoi via 4D_Tech
4D has improved over the years, but there is still a number of type handling inconsistencies. Only option seems to be to work around them by moving data into different variable types. The method below (_TEST) works interpreted but gives a runtime error in compiled mode. Reported as a bug in

Re: Build Application “No License is Installed" and ...

2019-02-26 Thread John DeSoi via 4D_Tech
Maybe. I never worried about it before for custom and personal applications, but each version of macOS is getting more restrictive. With 10.14 certain commands called by 4D with LAUNCH EXTERNAL PROCESS stopped working. The error said you had to give access to the app in security and privacy

4D 17.1 duplicate constant

2019-02-20 Thread John DeSoi via 4D_Tech
Just killed a bunch of time trying to figure out why some menu actions were not working for a host menu duplicated by a component. It turns out the "Associated standard action" constant is duplicated with different values and 4D does not use the same one in all cases. John DeSoi, Ph.D.

Re: Relation naming for ORDA in v17? Best Practices anyone?

2019-02-09 Thread John DeSoi via 4D_Tech
I always use singular table names and the relationship names are singular or plural based on their type. For example, I have a structure that imports 4D code and builds a database of each method path and the related methods it directly calls: [Method_Call]ID [Method_Call]Caller_Method_ID ->

Re: v17 built client on windows a few issues

2019-02-06 Thread John DeSoi via 4D_Tech
> On Feb 6, 2019, at 11:15 AM, Chuck Miller via 4D_Tech <4d_tech@lists.4d.com> > wrote: > > I am using v17.2 64 bit client. On a variety of windows machines, entering a > enter from extended keyboard is causing volume desktop has stopped working > and of course 4D just quits. Anyone else

Re: Does 4D 64-bit Volume desktop use more than 1 core?

2019-01-30 Thread John DeSoi via 4D_Tech
Hi Neil, > On Jan 30, 2019, at 3:40 PM, Dennis, Neil wrote: > >> If a shared method is marked as preemptive capable, any shared method it >> uses must also be marked as preemptive capable. Otherwise 4D says the method >> further down in the call chain is not thread safe even if it has no

Re: Does 4D 64-bit Volume desktop use more than 1 core?

2019-01-30 Thread John DeSoi via 4D_Tech
Hi Christian, That is really impressive since they seem like complex plugins that need a lot of 4D interaction and there are currently very few plugin API calls that are thread safe. Are you really saying that I can mark a 4D method as preemptive capable and use significant functionality of

Re: Does 4D 64-bit Volume desktop use more than 1 core?

2019-01-30 Thread John DeSoi via 4D_Tech
Chip, This is true, but there is some extra complexity involved with components: If a shared method is marked as preemptive capable, any shared method it uses must also be marked as preemptive capable. Otherwise 4D says the method further down in the call chain is not thread safe even if it

Re: Does 4D 64-bit Volume desktop use more than 1 core?

2019-01-30 Thread John DeSoi via 4D_Tech
Yes, I was not trying to imply that all plugins are thread safe, only that it is possible to create one following the direction outlined in the SDK. It is supported and there are significant speedup benefits if you can make it work. I'm not aware any commercial 4D plugin that works in

Re: Does 4D 64-bit Volume desktop use more than 1 core?

2019-01-30 Thread John DeSoi via 4D_Tech
Hi Tim, The header file in the publicly available SDK indicates which plugin API entry points are thread safe (currently a small number). https://github.com/4d/4D-Plugin-SDK See further discussion here including input from 4D France: > Yes the 4d plugin sdk allows to build preemptive ready

Re: Does 4D 64-bit Volume desktop use more than 1 core?

2019-01-30 Thread John DeSoi via 4D_Tech
In version 17 you can use plug-ins in preemptive mode if the plugin call is marked as thread safe. I converted my Postgres component/plugin to work in preemptive mode. Tests show 300% to 400% improvement over single core execution. See this lengthy thread on the forum for issues in converting

Re: Does 4D 64-bit Volume desktop use more than 1 core?

2019-01-30 Thread John DeSoi via 4D_Tech
No, a normal process can be preemptive (started with New process or Executed on server) as long as the starting method is preemptive capable. John DeSoi, Ph.D. > On Jan 30, 2019, at 2:14 PM, Dennis, Neil via 4D_Tech <4d_tech@lists.4d.com> > wrote: > > I thought for a process to work on a

Re: XLS plugin - format number with leading zero

2019-01-30 Thread John DeSoi via 4D_Tech
I don't know anything about the plugin you were attempting to use, but one way to create formatted documents for Excel is to use XML. You specify the type for each cell. I'm sure you could figure out the format option you want by saving a document with Excel and looking at the XML. John DeSoi,

Re: listbox commands and collection variables

2019-01-23 Thread John DeSoi via 4D_Tech
Hi Kirk, > I'm not able to replicate all of the issues you mention with a collection > based listbox. To test I made a form and added a collection based listbox > with two columns. To open it I made a method, created a collection with 10 > elements comprised of objects and had the listbox

listbox commands and collection variables

2019-01-22 Thread John DeSoi via 4D_Tech
17.0 HF4 Mac I've noticed that a lot of generic listbox code fails with collection variables. For example, in passing a listbox pointer to a method such as LISTBOX SELECT ROW($arrayListbox->;$row) `works LISTBOX SELECT ROW($selectionLisbox->;$row) `works LISTBOX SELECT

Re: Apple Push Notification Servers (APNS)

2019-01-15 Thread John DeSoi via 4D_Tech
I have seen this error which I thought was related to a keep-alive error (* as the last parameter) in the HTTP client implementation, but it appears you are not using that option. My work-around was to just retry the request which seemed to work. Might be worth a try. John DeSoi, Ph.D. >

Re: Socket Communication

2019-01-15 Thread John DeSoi via 4D_Tech
Polling does not have to be an immediate request/response. See long polling: https://www.pubnub.com/blog/2014-12-01-http-long-polling/ With websockets your are going to have a connection open all the time anyway, so long polling is no more resource intensive. I would not use it for the public

Re: Socket Communication

2019-01-15 Thread John DeSoi via 4D_Tech
Steve, > On Jan 15, 2019, at 3:08 PM, Stephen J. Orth > wrote: > > Not sure I understand what you are saying, would you be able to provide me > with a high level overview of what you are thinking? HTTP is a request/response protocol where the server only responds to requests from the

Re: Socket Communication

2019-01-15 Thread John DeSoi via 4D_Tech
Do you really need the ability for the server to send data asynchronously to the client (browser)? If not, then HTTP should work and is already supported in the browser and on 4D Server. John DeSoi, Ph.D. > On Jan 15, 2019, at 1:30 PM, Stephen J. Orth via 4D_Tech > <4d_tech@lists.4d.com>

Re: Sales Tax Solutions for 4D

2019-01-04 Thread John DeSoi via 4D_Tech
What 4D version are you using and how are you sending the request? What you have below does not correspond to any recent 4D HTTP client interface which passes the headers/values as two text arrays. Why are you sending a content-length header for GET request? John DeSoi, Ph.D. > On Jan 4,

list box column width on resize

2018-12-29 Thread John DeSoi via 4D_Tech
I have code since the advent of list boxes that allows a column other than the last one to grow and shrink as the window is resized. It works for array based list boxes, but I just noticed it is no longer working for (named) selection list boxes in version 16 or 17. The last column always

Re: How to process all WritePro area expressions for replacement / update?

2018-12-21 Thread John DeSoi via 4D_Tech
This may help you get started: ARRAY LONGINT($aPos;0) ARRAY LONGINT($aLen;0) $start:=1 While (Match regex("\\s*)";$text;$start;$aPos;$aLen)) $expr:=Substring($text;$aPos{2};$aLen{2}) $expr:=Substring($expr;10) //Strip off leading -d4-ref:' $expr:=URL_Decode ($expr) End while John

Re: WritePro expression undefined

2018-12-20 Thread John DeSoi via 4D_Tech
There is no such command SET ALLOWED COMMANDS, only SET ALLOWED METHODS which only works on methods. If you allow users to enter "QUERY" then they can also enter DELETE SELECTION. The documentation says: > If you would like the user to be able to call 4D commands that are > unauthorized by

Re: Storing Dates and Times From Different Time Zones

2018-12-20 Thread John DeSoi via 4D_Tech
I use the code below to determine the number of seconds offset from GMT for the current time zone. This could be added back to a GMT time stamp to get the local time. John DeSoi, Ph.D. C_LONGINT($0) C_DATE($zDate;$gmtDate) C_TIME($zTime;$gmtTime) C_TEXT($str) $zDate:=Current date

Re: WA Evaluate JavaScript in 16.4

2018-12-20 Thread John DeSoi via 4D_Tech
Try turning 'Use embedded rendering engine' off for the web area. And verify your JavaScript code works outside of 4D in Safari when using Mojave. John DeSoi, Ph.D. > On Dec 20, 2018, at 11:10 AM, Noah via 4D_Tech <4d_tech@lists.4d.com> wrote: > > The parent form: > Case of >: (Form

Re: WritePro expression undefined

2018-12-20 Thread John DeSoi via 4D_Tech
I see two options: 1. Submit a bug/feature request to 4D and hope they change it to return nothing instead of "Undefined". 2. Replace all of your QUERY commands with a method that returns an empty string. I don't use 4D Write Pro, but I think automating the replacement in 4D Write before

Re: WritePro expression undefined

2018-12-20 Thread John DeSoi via 4D_Tech
SET ALLOWED METHODS specifies project methods allowed, not 4D commands. So unless you named a project method the same as the 4D command QUERY, you are using it wrong. And the 4D command QUERY does not return a result, so I'm not sure how you would use that in an expression. Of course, you can

Re: 4D Write for v17

2018-12-15 Thread John DeSoi via 4D_Tech
Maybe 4D Write version 16 plugin will work with 32 bit 4D 17? Not sure, never tried it. As long as you don't need to run 4D Write in version 17 (just need to compile/load with the old code), you can create a 64 bit plugin stub that just has the 4D Write resources. I can send you one if you need

Re: Native 4D to make REST request to Django application

2018-12-10 Thread John DeSoi via 4D_Tech
I'm not familiar with Django, but here are some suggestions after a quick look at their API. They show an examples here with curl. https://www.django-rest-framework.org/tutorial/quickstart/ https://www.django-rest-framework.org/api-guide/authentication/ If you run these adding the --verbose

Re: 4D Structure Export...

2018-12-07 Thread John DeSoi via 4D_Tech
> > On Dec 7, 2018, at 1:07 PM, Kirk Brooks via 4D_Tech <4d_tech@lists.4d.com> > wrote: > > I'm not familiar with VC_Framework but the big improvement in R3 is the > addition of Form convert to dynamic. This allows you to export all the > forms - not just the object and form methods. The

Re: Calling java

2018-12-04 Thread John DeSoi via 4D_Tech
Creating a plugin would be pretty involved. If LAUNCH EXTERNAL PROCESS is too slow, I would look into something like JSON RPC. For example, https://www.jsonrpc.org/archive_json-rpc.org/implementations.html https://github.com/briandilley/jsonrpc4j John DeSoi, Ph.D. > On Dec 4, 2018, at 1:48

Re: ORDA to get "record number" value

2018-11-28 Thread John DeSoi via 4D_Tech
If you only need to emulate the Record number function for a particular entity, you could use getKey() to get the primary key and then Find in field to get the record number. John DeSoi, Ph.D. > On Nov 23, 2018, at 11:10 AM, Gianluca Rigotti via 4D_Tech > <4d_tech@lists.4d.com> wrote: > >

Re: V15.2 to v17.0HF3 conversion problem

2018-11-23 Thread John DeSoi via 4D_Tech
You could write something to load each form and then use OBJECT Get action to find the problem check boxes. Or open a copy of the structure in 17R and export all the forms to search them with your favorite text editor. John DeSoi, Ph.D. > On Nov 22, 2018, at 9:36 PM, Keith Goebel via

Re: Explorer bottom toolbar not displaying...

2018-11-21 Thread John DeSoi via 4D_Tech
I'm happy there is a simpler work-around than finding some obscure file to delete. But it would be better if 4D just fixed the issue. If you use multiple monitors and change configurations this is an ongoing issue. Other Mac applications have no problems, but I'm often surprised by how 4D

Re: Audit File Updates via Triggers...

2018-11-20 Thread John DeSoi via 4D_Tech
Just note that you won't be able to see any of the data in an object field if you are displaying records in a list box. Some possible options now in version 17 if you are using collections/entity selections. John DeSoi, Ph.D. > On Nov 20, 2018, at 2:56 PM, Robert ListMail via 4D_Tech >

Re: Format of MySql data file

2018-11-15 Thread John DeSoi via 4D_Tech
Pat, > > On Nov 15, 2018, at 5:18 PM, Pat Bensky via 4D_Tech <4d_tech@lists.4d.com> > wrote: > > I want to break this file down into individual files for each table, to > make it more manageable. So I created a method to parse the file and create > a new file for each table. > But ... > The

Re: What is the "REST" process for?

2018-11-14 Thread John DeSoi via 4D_Tech
I'm not seeing what ACI0098723 has to do with this issue. I'm not doing anything here with ORDA. After some further testing I discovered the issue is related to saving records on tables with triggers enabled in a preemptive process. If I disable all the triggers, no REST process shows up. Also

What is the "REST" process for?

2018-11-13 Thread John DeSoi via 4D_Tech
4D 17.0 HF3 Mac 64bit. I'm experimenting with creating a lot of records concurrently (different tables) in 5 preemptive processes. As soon as each process launches, 4D launches a second process named "REST". It has origin -3 = Web process with no context. The web server is not on and I can't

Re: How to get a list of all user windows?

2018-11-08 Thread John DeSoi via 4D_Tech
You could use the Window process function find the process number. Then use the "origin" parameter of PROCESS PROPERTIES to determine which processes belong to the design process. John DeSoi, Ph.D. > On Nov 8, 2018, at 1:46 PM, Pat Bensky via 4D_Tech <4d_tech@lists.4d.com> > wrote: > > The

Re: SET MENU BAR glitch

2018-11-03 Thread John DeSoi via 4D_Tech
Have you checked the "Active Menu Bar" property on the form? If you don't do that, none of the main menu items will work. I don't think you can check this option unless you specify an appended menu. I always use an empty appended menu. John DeSoi, Ph.D. > On Nov 3, 2018, at 3:06 AM, Chris

Re: Linefeed option not working for v16 emails

2018-11-02 Thread John DeSoi via 4D_Tech
I just ran some tests using a web mail program and confirm the issue you reported. I have been using 4D 16 in production since late 2017 and no one has complained, I suppose since most use Apple Mail where everything seems OK. As a work-around, I turned off that default and ensured the body

Re: Linefeed option not working for v16 emails

2018-11-01 Thread John DeSoi via 4D_Tech
> On Nov 1, 2018, at 3:22 PM, Janet Jonas via 4D_Tech <4d_tech@lists.4d.com> > wrote: > > We recently switched to v16 and found out today that our plain text emails > are no longer getting a linefeed added to the carriage returns in the body of > plain text we send out. After looking at the

Re: Using 4D with Git...

2018-10-31 Thread John DeSoi via 4D_Tech
Yes, it can do those things plus just manage local repositories if you don't publish anywhere. I thought that was one of the questions in this thread - a usable git GUI client. John DeSoi, Ph.D. > On Oct 31, 2018, at 2:05 PM, Robert ListMail via 4D_Tech > <4d_tech@lists.4d.com> wrote: > >

Re: Using 4D with Git...

2018-10-31 Thread John DeSoi via 4D_Tech
I like Fork. Nice interface, open source, free. I tried to find a donation page, but did not see one. https://git-fork.com John DeSoi, Ph.D. > On Oct 31, 2018, at 2:01 AM, Paul Dennis via 4D_Tech <4d_tech@lists.4d.com> > wrote: > > Ill give the client a try. There is defiantly a gap in

Re: Setting up an entity / collection listbox in code

2018-10-30 Thread John DeSoi via 4D_Tech
Maybe it could work if you adopted the convention that the collection properties are based on the listbox object name, e.g. Form.listbox1__currentItem Form.listbox1__selectedItems etc. You would have to adjust these properties after the first listbox, but I assume the component could manage

Re: text characters in blob or text to document

2018-10-30 Thread John DeSoi via 4D_Tech
> On Oct 30, 2018, at 2:24 PM, Charles Miller via 4D_Tech > <4d_tech@lists.4d.com> wrote: > > OK I will try and explain. I qwas working at a customer who has code that > uses send packet. This is really old code and I do not think they have ever > used USE CHARACTER SET. So that is likely

Re: text characters in blob or text to document

2018-10-30 Thread John DeSoi via 4D_Tech
Not sure I'm following exactly what you are doing - difficult to know without seeing the commands and parameters. TEXT TO BLOB and Blob to text both allow you to specify the character set. If you are using SEND PACKET with a blob you created using TEXT TO BLOB, there should be no problem

Re: text characters in blob or text to document

2018-10-30 Thread John DeSoi via 4D_Tech
The problem is likely with TEXT TO DOCUMENT/Document to text. These have strange defaults, so you have to be very careful about the parameters. TEXT TO DOCUMENT defaults to UTF-8 and inserts a BOM (which I think is a bug). So you can't read it using DOCUMENT TO BLOB and covert to UTF-8 text

Re: Longing IDs or UUIDs as primary key?

2018-10-24 Thread John DeSoi via 4D_Tech
There are other options which may be more attractive if you are willing to put more work in your synchronization code. I did something like this years ago before UUIDs existed. You need to be able to identify shared records (which can be a UUID field without it being the primary key) and then

Re: Form data, Constants and dot notation

2018-10-14 Thread John DeSoi via 4D_Tech
Only the bracketed expression form, e.g. myObject[constant]. John DeSoi, Ph.D. > On Oct 14, 2018, at 1:56 AM, Jim Dorrance via 4D_Tech <4d_tech@lists.4d.com> > wrote: > > Constants cannot be used with dot notation? ** 4D

Re: 4D Write Pro (WP) Area and ST INSERT EXPRESSION

2018-10-09 Thread John DeSoi via 4D_Tech
You can use the 4D formula editor with the EDIT FORMULA command. I don't use 4D Write, but I implemented the formula editor for styled text fields (used to implement a markdown editor). Editing (by double click) or inserting a formula is something like this: GET

Re: How to get the current time in a specified time zone

2018-09-26 Thread John DeSoi via 4D_Tech
It is really a database problem of managing all of the various rules of different locations. Postgres has this built in. If you don't want to use Postgres, you still might find the data you need to add to your 4D implementation. See list below of 79 distinct zones. John DeSoi, Ph.D. > On

Re: Creating a form object to use as dynamic form

2018-09-24 Thread John DeSoi via 4D_Tech
On Sep 24, 2018, at 9:44 AM, Two Way Communications via 4D_Tech <4d_tech@lists.4d.com> wrote: > > $page:=New object("objects";New object("myListBox";$obj)) $form:=New > object(“pages";New collection(Null;$page)) > > $form:=New object("windowTitle";"Select a >

Re: v13-v16 thread safe component

2018-09-20 Thread John DeSoi via 4D_Tech
> On Sep 20, 2018, at 11:40 AM, Chip Scheide <4d_o...@pghrepository.org> wrote: > > I have been looking through the v16 and v17 documentation, I do not see > where it says that pasteboard commands do not work with/inside > pre-emptive threads. Every command that supports preemptive mode has a

Re: v13-v16 thread safe component

2018-09-20 Thread John DeSoi via 4D_Tech
Chip, > On Sep 20, 2018, at 9:24 AM, Chip Scheide via 4D_Tech <4d_tech@lists.4d.com> > wrote: > > I was going to use the pasteboard to pass information to and from the > IP set tracking process, but as I discovered yesterday - this could be > a problem... The pasteboard commands don't work

Re: Do I want to use SELECTION TO ARRAY instead of GOTO SELECTED RECORD server-side in V17

2018-09-18 Thread John DeSoi via 4D_Tech
Dani, Thanks for taking the time to test this and post your results. I looked at some document generation routines where I was caching some text before writing it out with SEND PACKET (to avoid lots of calls to SEND PACKET with small amounts of text). I changed to a blob cache and it seemed to

Re: Do I want to use SELECTION TO ARRAY instead of GOTO SELECTED RECORD server-side in V17?

2018-09-15 Thread John DeSoi via 4D_Tech
With a little up front work, you can create a nice wrapper for SELECTION TO ARRAY/SELECTION RANGE TO ARRAY where you just pass an array of field pointers. You can use a process 2D array of each type to dynamically allocate/deallocate the necessary arrays and just manipulate the pointers. Some

Re: 4D for iOS: anyone?

2018-09-11 Thread John DeSoi via 4D_Tech
I think it refers to My Home > List of posts > R-release channel > Beta version Then in the first box there is a Forum "4D for iOS - Preview", where you can further filter or click on "Create a new topic". John DeSoi, Ph.D. > On Sep 11, 2018, at 3:20 AM, Two Way Communications via 4D_Tech >

Re: 4D Write to 4D Write Pro

2018-08-29 Thread John DeSoi via 4D_Tech
One solution for this is to just create a "stub" plugin that does nothing except load properly on 64 bit. Then copy all of the 4D Write resources to it. That way you can keep the old code around as long as you need it for reference. I think I did it by finding a small 64 bit plugin and then

Re: Using local variables and set and named selection names in a recursive situation

2018-08-29 Thread John DeSoi via 4D_Tech
Hi Pat, There is no such thing as a local named selection. That is just a named selection name that begins with a "$" character. A leading $ in a string has a meaning for a local set name, but that just means the set is only on the client and not the server. See

Re: New record numbering system and CALL WORKER

2018-08-27 Thread John DeSoi via 4D_Tech
. > On Aug 27, 2018, at 10:04 AM, Keith Culotta via 4D_Tech > <4d_tech@lists.4d.com> wrote: > > Does the speed penalty apply to reading values from Storage, or just to > writing values to Storage? > > > >> On Aug 26, 2018, at 8:57 AM, John DeSoi via 4D_T

Re: New record numbering system and CALL WORKER

2018-08-26 Thread John DeSoi via 4D_Tech
Storage is the best option for interprocess communications if you want to use preemptive processes. I have not done any real benchmarking but I have not noticed that anything seems slow. By setting up return values on a per-process basis you can avoid locking contention on storage. For

Re: New record numbering system and CALL WORKER

2018-08-25 Thread John DeSoi via 4D_Tech
Hi Pat, Set the method property to "Execute on Server". This shared object/collection could also have a collection of numbers that need to be reused if you require that there are no missing numbers in your sequence. Of course, you'll have to get the database involved at some level to handle

Re: New record numbering system and CALL WORKER

2018-08-25 Thread John DeSoi via 4D_Tech
> On Aug 25, 2018, at 9:10 AM, Pat Bensky via 4D_Tech <4d_tech@lists.4d.com> > wrote: > > As I see it, we'll need to call a worker, which calls the worker that > assigns the record number. > The first worker has to wait until the second one has created the new > number. > Then the original

v17 variables not found on forms

2018-08-13 Thread John DeSoi via 4D_Tech
It appears version 17 (including HF1) no longer finds variables on forms. If I right click on a variable in a method, and choose "Search References", it only shows the variables in methods. If I do a global text search, it shows additional references on forms. Be careful renaming things. Also,

Re: ORDA - updating data in listboxes

2018-08-12 Thread John DeSoi via 4D_Tech
This makes me wonder why REDRAW can't do this internally instead of adding yet another microscopic difference between listbox types that will continue to elude even the most experienced 4D developers. At the very least, the REDRAW documentation should be updated to say that this command does

Re: Automatic updating of built apps

2018-08-08 Thread John DeSoi via 4D_Tech
What version of 4D? I'm not having any problems with 16.3. Are you setting the update folder to the full path of the application package? For example, I'm updating from a disk image with the same name as the application with something like: $updateFolder:=$appName +Folder

Re: Automated Generation of Form Variables

2018-08-06 Thread John DeSoi via 4D_Tech
I don't use the form wizard, so I'm not sure I understand what you mean about Form.table.dataClassAttribute. But you can certainly generate your own form with fields and labels in version 17. To generate a field, I use a method like this: //Create field object. //$0 - Field object. //$1

Re: startup progress on server

2018-08-06 Thread John DeSoi via 4D_Tech
Randy, I'll be interested to hear if this permanently fixes the problem. I'm still having random crash on quit errors on 4D Server (16.3HF4, 64-bit). Never a problem in version 15, 32-bit. I have never connected crashing to a status interface, but in my case it has always run in a separate

Re: selected rows for a collection listbox

2018-08-05 Thread John DeSoi via 4D_Tech
I found a solution that has good performance and does not require creating thousands of objects for rows that will never be displayed. - The listbox collection is initially setup as a collection of row numbers. Using ARRAY TO COLLECTION seems to be the fastest way to do this. About 30

Re: Memory leak with dynamic variables in list boxes?

2018-08-02 Thread John DeSoi via 4D_Tech
Try bringing up the "User Interrupt" menu and select the Go to Design Mode option. On the Mac it is control-option-click. Not sure about Windows. John DeSoi, Ph.D. > On Aug 2, 2018, at 10:55 AM, mferguson--- via 4D_Tech <4d_tech@lists.4d.com> > wrote: > > Puzzling. That doesn’t work on my

Re: v13 - Record to Blob?

2018-07-30 Thread John DeSoi via 4D_Tech
I think this would be very useful as a native command and trivial to implement (already in the plugin API, I think). If you agree, here is the feature request: http://forums.4d.com/Post/EN/17757394/1/17757547 John DeSoi, Ph.D. > On Jul 30, 2018, at 2:40 PM, Keisuke Miyako via 4D_Tech >

Re: selected rows for a collection listbox

2018-07-30 Thread John DeSoi via 4D_Tech
Hi Kirk, Great summary, thanks for posting. > On Jul 30, 2018, at 10:27 AM, Kirk Brooks via 4D_Tech <4d_tech@lists.4d.com> > wrote: > > Eventually I got the concept of manipulating the data in the collection > instead of in the listbox is the key. This is why it doesn't really matter > which

Re: selected rows for a collection listbox

2018-07-29 Thread John DeSoi via 4D_Tech
> On Jul 29, 2018, at 9:41 PM, Keisuke Miyako via 4D_Tech > <4d_tech@lists.4d.com> wrote: > > the beauty of working with collections (in ORDA) is that > when you operate via member methods or "For each", > the elements are loaded on demand. > there is no need to work with the "On Display

Re: selected rows for a collection listbox

2018-07-29 Thread John DeSoi via 4D_Tech
It is not ORDA. I'm displaying a server side cursor from PostgreSQL. The select result may have hundreds of thousands of rows. I can scroll that nicely in 4D using On Display Detail to load only the visible data. But to operate on the selected rows as a collection implies that every row has to

Re: selected rows for a collection listbox

2018-07-29 Thread John DeSoi via 4D_Tech
es.300-3743666.en.html > > use the 3rd one. > > 2018/07/30 0:27、John DeSoi via 4D_Tech > <4d_tech@lists.4d.com<mailto:4d_tech@lists.4d.com>>のメール: > > Is there a way to get all of the highlighted row numbers for a collection > listbox? It seems you can only g

selected rows for a collection listbox

2018-07-29 Thread John DeSoi via 4D_Tech
Is there a way to get all of the highlighted row numbers for a collection listbox? It seems you can only get the first highlighted row number via the currentItemPosition property. The selectedItems property would return a collection of highlighted items, but at best you would have to

Re: First ORDA runtime error - just like SQL

2018-07-27 Thread John DeSoi via 4D_Tech
> On Jul 27, 2018, at 1:52 PM, Jeffrey Kain via 4D_Tech <4d_tech@lists.4d.com> > wrote: > > It's also annoying that an error handler is running, yet a runtime error > appears instead of calling the error method. Also the lack of a call chain > makes this really hard to track down. So.

  1   2   3   >