Re: User Custom Forms

2018-01-23 Thread Keith Culotta via 4D_Tech
I used an inherited form in the user enterable form, so some changes could be made in the development environment without destroying the User's changes. Also, could OBJECT DUPLICATE be used during On Load to give a new object a name like "[Table1]Field1"? Keith - CDI > On Jan 23, 2018, at

Re: time entry filter

2018-03-12 Thread Keith Culotta via 4D_Tech
4D will interpret entries like 1.25p as 13:25:00, or 1.25 as 01:25:00 without requiring a filter. Keith - CDI > On Mar 12, 2018, at 8:07 AM, Randy Jaynes via 4D_Tech <4d_tech@lists.4d.com> > wrote: > > Does anyone know of a filter string or something that can be done so people > don’t have

ORDA query & pointers syntax question

2018-04-11 Thread Keith Culotta via 4D_Tech
Hello, I didn't recognize a solution for this in the docs. When the table and field are unknown until execution time, any suggestions on what the ORDA approach to this type of query would be? QUERY(pTable->;pField->=$aValue) Thanks - Keith - CDI

Re: ORDA query & pointers syntax question

2018-04-11 Thread Keith Culotta via 4D_Tech
name(pTable) >> $fieldName:=Field name(pField) >> QUERY(ds[$tableName];ds[$tableName][$fieldName]=$aValue) >> >> When an object property name is on a variable, you can use the >> “object[property]” syntax. >> >> hth >> julio >> >>&g

Re: ORDA on switch?

2018-04-12 Thread Keith Culotta via 4D_Tech
The table must have a primary key field to be seen. The old table was created before primary keys were used. Keith - CDI > On Apr 12, 2018, at 10:33 AM, Keith Culotta wrote: > > C_OBJECT($entAll) > $entAll:=ds.Table_1.all() > > The code works in a new structure. > It

Re: MSC Warnings

2018-04-24 Thread Keith Culotta via 4D_Tech
Try this. I don't remember if it was the stylesheet property at that time or another property, but you can see if it works. I have changed an object type that had no stylesheet in Properties to another type that had a stylesheet. After doing that the hidden stylesheet appeared and could be

Re: Multi-Table Query Into JSON?

2018-03-23 Thread Keith Culotta via 4D_Tech
The "Movable form dialog box" type became available for "Open form window" at some point. It is also constant 5. A "Plain form window" with Cancel in the Deactivate event is user friendly, but will probably appear behind a floating window. Keith - CDI > On Mar 23, 2018, at 12:15 PM,

Re: 4D Write licensing...

2018-06-28 Thread Keith Culotta via 4D_Tech
As I recall, any interaction with aWrite document requires the user to have a license. You could store a PDF copy of a document for others to print or view. Keith - CDI > On Jun 28, 2018, at 2:47 PM, Robert ListMail via 4D_Tech > <4d_tech@lists.4d.com> wrote: > > I appreciate your response;

Re: Shared Object - NOT!

2018-10-22 Thread Keith Culotta via 4D_Tech
If a method creates an object ($no:=new object), the object is destroyed when the method ends? and if a method creates a new shared object ($nso:=new shared object), the object continues to exist after the method ends, but the reference to it is lost? Does 4D know to clear the object in this

Re: Icon & Picture Button Sources...

2018-10-24 Thread Keith Culotta via 4D_Tech
Here's a simple example inspired by the 4d-component-generate-icon. //- $width:=3 $opacity:=80 $rw:=40 $color:="black" // normal $svg:=SVG_New (58;58) $ref:=SVG_New_rect ($svg;9;9;$rw;$rw;2;2;$color;"white";$width) SVG_SET_OPACITY ($ref;0;$opacity)

Re: Longing IDs or UUIDs as primary key?

2018-10-24 Thread Keith Culotta via 4D_Tech
Here's a possible approach to automating, but it depends last question. If you change a longint to an alpha field, the new new alpha field retains the longint value. You could send the modified Structure with the longint fields changed to alpha. When the Structure sees that a Datafile is not

Re: Longing IDs or UUIDs as primary key?

2018-10-24 Thread Keith Culotta via 4D_Tech
[some emoji that expresses a slight sense of relief, but not necessarily a feeling of being surprised] > On Oct 24, 2018, at 11:01 AM, Jeffrey Kain via 4D_Tech <4d_tech@lists.4d.com> > wrote: > > No it isn't. > >> On Oct 24, 2018, at 11:59 AM, Keith Culotta via

Re: Longing IDs or UUIDs as primary key?

2018-10-24 Thread Keith Culotta via 4D_Tech
RE: never use them to link between tables Is using them to link between tables (establish 4D Relations, correct?) a hazardous practice? Thanks, Keith - CDI > On Oct 24, 2018, at 10:49 AM, Charles Miller via 4D_Tech > <4d_tech@lists.4d.com> wrote: > > Rudy > > For me this always choose UUID

Re: Longing IDs or UUIDs as primary key?

2018-10-24 Thread Keith Culotta via 4D_Tech
Sorry, forgot the UUID properties would still have to be set for the fields after all that. Again, SQL? Name it the "No way, YOU click the 'OK to Update' button" method. > On Oct 24, 2018, at 12:01 PM, Keith Culotta via 4D_Tech > <4d_tech@lists.4d.com> wrote: > >

Re: Reindex

2018-11-06 Thread Keith Culotta via 4D_Tech
If you open the data file using your own copy of the structure, maybe your copy of the structure has a field indexed that the client's copy does not have indexed? Keith - CDI > On Nov 6, 2018, at 11:52 AM, stardata.info via 4D_Tech <4d_tech@lists.4d.com> > wrote: > > 1 - I select the tre

Re: Listbox multiple select

2018-11-09 Thread Keith Culotta via 4D_Tech
Look here at the "Selection Mode" section of the Listbox's Property list. http://doc.4d.com/4Dv16/4D/16.4/List-box-specific-properties.300-3998930.en.html Keith - CDI > On Nov 9, 2018, at 7:54 AM, vagelis fallias via 4D_Tech > <4d_tech@lists.4d.com> wrote: > > Hello all, > how do I make a

Re: Making a selection

2018-11-09 Thread Keith Culotta via 4D_Tech
Nothing built in, but one option is to put an invisible rectangle on a form, and make it visible and act like a selection rectangle when the mouse goes down. Another is to overlay (or underlay) a form sized picture on the form and use SVG to produce the selection rectangle. SVG is nice in

Re: can an array be added to a Form's object list i.e. Form.Array?

2018-10-02 Thread Keith Culotta via 4D_Tech
You can save ChoicesArray to the Form object with OB SET ARRAY(Form;"myarr";ChoicesArray). http://doc.4d.com/4Dv17/4D/17/OB-SET-ARRAY.301-3730702.en.html Also 'JSON Stringify array' will produce a string that can be reconstituted with JSON PARSE ARRAY. FORM.myarr:=$stringifiedArray

Re: can an array be added to a Form's object list i.e. Form.Array?

2018-10-02 Thread Keith Culotta via 4D_Tech
to the data object is whatever choice is made. > > It sounds like you're describing a situation where the data object includes > things like the choice lists. > > It's not a case of one being better than the other, more a case of > different approaches to managing the form

Re: can an array be added to a Form's object list i.e. Form.Array?

2018-10-02 Thread Keith Culotta via 4D_Tech
or for each value of ChoicesArray: OB SET(Form;"ChoicesArray"+string($i); ChoicesArray{$i}) ? Keith > On Oct 2, 2018, at 3:10 PM, Keith Culotta via 4D_Tech <4d_tech@lists.4d.com> > wrote: > > You can save ChoicesArray to the Form object with OB SET > ARRAY(For

Re: Related Fields in a Listbox (Manual Relations)

2018-11-16 Thread Keith Culotta via 4D_Tech
ks. Just what I needed! > > Sannyasin Siddhanathaswami > On Nov 16, 2018, 9:09 AM -1000, Keith Culotta via 4D_Tech > <4d_tech@lists.4d.com>, wrote: > These have worked: > > // ok > GET AUTOMATIC RELATIONS($o;$m) // before the listbox displays > SET AUTOMATIC RELATIONS(True;$m)

Re: Related Fields in a Listbox (Manual Relations)

2018-11-16 Thread Keith Culotta via 4D_Tech
These have worked: // ok GET AUTOMATIC RELATIONS($o;$m) // before the listbox displays SET AUTOMATIC RELATIONS(True;$m) // better : (Form event=On Display Detail) // in the listbox method RELATE ONE([many]linkField) Keith - CDI > On Nov 16, 2018, at 12:54 PM, Sannyasin

Re: How to Create a Browser-Like Tabbed Interface

2019-01-21 Thread Keith Culotta via 4D_Tech
A tab control will not report a click when the click is on the current tab "page", but Safari seems to work that way too (no reaction to a click on the current page's tab). Clicking another of the tab's areas will generate a click. SVG pictures offer a good way to see clicks. You'll always

Re: v13- Chasing Relations

2019-01-08 Thread Keith Culotta via 4D_Tech
Would these help? https://doc.4d.com/4Dv17/4D/17/GET-RELATION-PROPERTIES.301-3729513.en.html https://doc.4d.com/4Dv17/4D/17/dataClassAttributerelatedDataClass.303-3884018.en.html

Using a custom namespace in SVG

2018-09-17 Thread Keith Culotta via 4D_Tech
I'm taking a shot at using a custom namespace, but can't find an example of its implementation in 4D SVG. Experimenting, I noticed that all three attributes below assigned with SVG_SET_ATTRIBUTES worked without returning an error when created, when used with SVG_GET_ATTRIBUTES, or when opened

Loose Object attribute typing

2019-03-12 Thread Keith Culotta via 4D_Tech
This seems to be a really advantageous way to use objects. It compiles and returns good results. I can see where caution would be advised, but is using an object this way going to break eventually as the 4D language matures, or is it an advantage of objects? //

Re: Can't get to development mode!

2019-03-12 Thread Keith Culotta via 4D_Tech
I have seen it ignore the Development mode menu selection until I closed an open window. or Does it go to the compiled version, requiring you to select "restart interpreted" from the "run" menu. Keith - CDI > On Mar 12, 2019, at 5:49 PM, Doug Hall via 4D_Tech <4d_tech@lists.4d.com> >

Re: How to display read-only input form

2019-02-06 Thread Keith Culotta via 4D_Tech
Can you call Modify Record with code either lock and reload the record(s), or disable entry for all objects? Keith - CDI > On Feb 6, 2019, at 3:31 PM, Jim Crate via 4D_Tech <4d_tech@lists.4d.com> > wrote: > > From a listbox view, I’d like to open the input form for a record but not > allow

Re: How to display read-only input form

2019-02-06 Thread Keith Culotta via 4D_Tech
I have simulated that effect with code like this: If (Read only state([Docs])) & (Form event=On After Edit) vContent:=[Docs]Content End if Where vContent is editable (no entry filter). Keith - CDI > On Feb 6, 2019, at 3:31 PM, Jim Crate via 4D_Tech <4d_tech@lists.4d.com> > wrote: >

Re: How to get the Window ref of the 4D 64 bit app window

2019-01-31 Thread Keith Culotta via 4D_Tech
Doing WINDOW LIST($aWin) in On Startup will return the window's ref in the array (on the Mac anyway). Keith - CDI > On Jan 31, 2019, at 4:40 PM, Peter Hay via 4D_Tech <4d_tech@lists.4d.com> > wrote: > > Hi, > > I'm trying to get the Window reference of 4D's application window so that I > can

Re: Count in Text

2019-04-09 Thread Keith Culotta via 4D_Tech
...and this. It's probably slower than using Position, but I'd have to test to be sure. (3 Lengths and 1 Replace string) C_LONGINT($count;$len1;$len2;$lenFind) $string:="This message and any attached documents contain information which maybe confidential, subject to privilege or exempt from

Fast way to highlight a listbox entity selection

2019-04-15 Thread Keith Culotta via 4D_Tech
Hello, I'm looking for a fast way to highlight a selection of rows in an entity selection listbox. The way I am aware of works OK unless the listbox gets a large number of rows. Adding records to the Selected Items name in the Property list does not highlight the listbox contents. The

Re: Fast way to highlight a listbox entity selection

2019-04-16 Thread Keith Culotta via 4D_Tech
heel appears for three minutes. The highlight then appears and control is returned to the app. The fewer the records being highlighted, the shorter the macOS wheel spins. Regards, Keith - CDI > On Apr 15, 2019, at 7:50 PM, Justin Carr via 4D_Tech <4d_tech@lists.4d.com> > wrote: > &g

Re: Fast way to highlight a listbox entity selection

2019-04-16 Thread Keith Culotta via 4D_Tech
compiled mode before the change. Still have the spinning wheel however. Keith - CDI > On Apr 16, 2019, at 9:22 AM, Keith Culotta via 4D_Tech <4d_tech@lists.4d.com> > wrote: > > Justin, > > Thank you for the suggestion. > > I switched the deselect-all code

Re: Fast way to highlight a listbox entity selection

2019-04-16 Thread Keith Culotta via 4D_Tech
ction > command can be helpful BUT it does move the actual entity data to the > collection. For something like a 40k element entity selection this might > matter. So be sure to stick with your entity selection when it's large. And > in this case the data would be in entitySelectio

Re: Fast way to highlight a listbox entity selection

2019-04-16 Thread Keith Culotta via 4D_Tech
want to do > that (if you don’t have to)?”, comes to mind. :-) > > -- > Douglas von Roeder > 949-336-2902 > > > On Tue, Apr 16, 2019 at 7:22 AM Keith Culotta via 4D_Tech < > 4d_tech@lists.4d.com> wrote: > >> Justin, >> >> Thank you for the su

Re: v17 64Bit Label Format Numbers

2019-05-16 Thread Keith Culotta via 4D_Tech
The good news is that you can enter this into the field on the label: String([Inventory]Sell1;"$###,##0.00"). The bad news is that it seems only one label from the selection will print when that is on the form :( Keith - CDI > On May 16, 2019, at 5:25 PM, Clive Wilson via 4D_Tech

Re: v17 64Bit Label Format Numbers

2019-05-17 Thread Keith Culotta via 4D_Tech
label. BEEP worked the same way. It will also print the value for [Table]Object.FirstName when a field has been so edited. However, like the String command, only one label in the selection will print when that appears on the form. Keith - CDI > On May 16, 2019, at 5:44 PM, Keith Culotta via

Re: Dialog (;*) question

2019-06-25 Thread Keith Culotta via 4D_Tech
"If the current process terminates, the forms created in this way are automatically closed". I have always had a DIALOG() window to keep the process from terminating, and called the DIALOG(*) windows from within it. However, you may be able to start a process with CALL WORKER, which does not

Re: Window type -724 (more info)

2019-06-19 Thread Keith Culotta via 4D_Tech
Chip, How did you find this window type? I accidentally created a window in 4D v15 that has a thin vertical window title with small type on the left side: -1*(Palette window+Has zoom box). However, in v17 the title looks the same but is on top. Is there a list that is not in the Docs?

Re: Window type -724 (more info)

2019-06-19 Thread Keith Culotta via 4D_Tech
All good advice, but still interesting to explore. Keith - CDI ** 4D Internet Users Group (4D iNUG) Archive: http://lists.4d.com/archives.html Options: https://lists.4d.com/mailman/options/4d_tech Unsub:

Re: Rotate Picture

2019-06-23 Thread Keith Culotta via 4D_Tech
Not that it is good form to rely on this, but does a SVG document referenced in a local variable get cleared when the method in which it was created terminates? Thanks, Keith - CDI > On Jun 22, 2019, at 9:01 PM, Keisuke Miyako via 4D_Tech > <4d_tech@lists.4d.com> wrote: > > I think the

Re: Log integration issue in mirror database

2019-05-19 Thread Keith Culotta via 4D_Tech
I saw error "Cannot find any record with that primary key" when a field marked "unique" had lost its index. After indexing the field the problem went away. Keith - CDI > On May 19, 2019, at 10:47 AM, Charles Miller via 4D_Tech > <4d_tech@lists.4d.com> wrote: > > Is there any way you are

Re: Using the HELP Menu for my own purposes.

2019-04-29 Thread Keith Culotta via 4D_Tech
The exception to the menu being empty for a standard build (with no additional components or plugins) is the SVG Component. It has a help file of its own inside 4D that needs to be removed at some point. Show 4D Contents and navigate to 4D/Contents/Components/4D SVG.4dbase. Show Contents of 4D

Re: Splitter behaviour

2019-07-12 Thread Keith Culotta via 4D_Tech
This may be related. When an object lies on the right (or maybe bottom too) of a window boundary, trying to change the size of the window makes it expand like you described. I get bit by this when a user double clicks a list form line to open an edit form in the same window. If the user

Re: Deleting a record from a listbox

2019-07-03 Thread Keith Culotta via 4D_Tech
I recall there being a bit more work in between these two lines, but LONGINT ARRAY FROM SELECTION will create ordered arrays representing the records. Then delete the missing records from the after array, and used CREATE SELECTION FROM ARRAY to get the new selection. Keith - CDI > On Jul 3,

Re: Deleting a record from a listbox

2019-07-03 Thread Keith Culotta via 4D_Tech
size;1;-1) $pos:=Find in array($aBefore{$i};$aAfter) If ($pos=-1) DELETE FROM ARRAY($aBefore;$pos) End if End for CREATE SELECTION FROM ARRAY($tablePtr->;$aBefore Keith - CDI > On Jul 3, 2019, at 3:03 PM, Keith Culotta via 4D_Tech <4d_tech@list

Re: Deleting a record from a listbox

2019-07-03 Thread Keith Culotta via 4D_Tech
Here is a version with all the parts in the right place, although it seems like Carl's example from the manual, searching a boolean array, would be faster. LONGINT ARRAY FROM SELECTION($tablePtr->;$aBefore) USE SET($highlightSet) LONGINT ARRAY FROM SELECTION($tablePtr->;$aAfter) DELETE

Re: Subform — how to get the CONTAINER OBJECT NAME in the subform form method? (17r5)

2019-07-08 Thread Keith Culotta via 4D_Tech
After using OBJECT Get pointer(Object current)->:=New object("subformName";OBJECT Get name(Object current)), I got Form ={} or Form=null, depending on where the code was put (subform's form method or container's method). If the subform container's code is: --- Case of : (Form

Re: Fast way to highlight a listbox entity selection

2019-04-17 Thread Keith Culotta via 4D_Tech
Hi JPR, Fuzziness is a good description, but things stand in sharper relief today. I was more focused on the syntax than the mechanics and for no particular reason started out with collections. Converting the app to an entity selection approach is turning out to be much easier than expected,

Re: POS systems

2019-08-03 Thread Keith Culotta via 4D_Tech
I have no direct experience using PIMS, but it gets very high marks from everyone who uses it. http://www.executron.com Keith - CDI > On Aug 3, 2019, at 7:03 AM, Dave Tenen via 4D_Tech <4d_tech@lists.4d.com> > wrote: > > To all of the 4D universe, > > Does anyone have any experience with a

Re: zooming and panning

2019-08-26 Thread Keith Culotta via 4D_Tech
From the description of your setup on page 1 it sounds like you already know this, but... If pic0 (on page 0) and pic1 (on page1) are both the same size and formatted to Truncated (non aero) you can OBJECT GET SCROLL POSITION ( pic1 ; vPosition ; hPosition ) // marker pic OBJECT SET SCROLL

Re: Regex expert needed??

2019-08-24 Thread Keith Culotta via 4D_Tech
<4d_tech@lists.4d.com> > wrote: > > See > > https://en.wikipedia.org/wiki/Longest_common_substring_problem > > John DeSoi, Ph.D. > > >> On Aug 24, 2019, at 10:48 AM, Keith Culotta via 4D_Tech >> <4d_tech@lists.4d.com> wrote: >>

Re: Regex expert needed??

2019-08-24 Thread Keith Culotta via 4D_Tech
This version stands alone, and runs a little more efficiently. It's not been tested in every way, but the results are encouraging. Interesting problem. I can't think of a way to do it without comparing every character combination. The new "Split string" command would speed part of this up

Re: v13 - Lists

2019-08-28 Thread Keith Culotta via 4D_Tech
Try pressing the enter or return keys before you do the tab switch? Keith - CDI > On Aug 28, 2019, at 11:01 AM, Chip Scheide via 4D_Tech <4d_tech@lists.4d.com> > wrote: > > I have a bunch of lists I use as contents for popup menus. > I initially was not consistent with my naming convention, in

Re: v13, v15 & OS X 10.14

2019-08-25 Thread Keith Culotta via 4D_Tech
A lot of v13 works. I have made small modifications to methods and forms, and have not yet destroyed a structure. In particular, when a user right-clicks a picture field in an entry form, the spinning wheel locks the program just after the contextual menu appears. Keith - CDI > On Aug 25,

Re: Regex expert needed??

2019-08-23 Thread Keith Culotta via 4D_Tech
This behaves better, in that it works for the whole of both strings. It could still be optimized. The array that gets returned has all (afaict) the matches. $str1:="This is my dog" $str2:="My dog does not have fleas" //$str2:="My dog does not have fleas" //$str1:="The quick brown fox

Re: Regex expert needed??

2019-08-23 Thread Keith Culotta via 4D_Tech
I realize you said "efficiently", but if you ever miss that old Bubble Sort feeling... $str1:="This is my dog" $str2:="My dog does not have fleas" $str1:="The quick brown fox jumps over the lazy dog" $str2:="The quick black fox leaps over the laziest dog" ARRAY TEXT($aMatch;0) getCommon

Re: FORMAT NUMBER

2019-08-05 Thread Keith Culotta via 4D_Tech
This ##0.###; ; produces good results for the example of 0.5 There are some things to watch for in the display detail event 4D v17 0 as blank 1 as 1 .5 as 0.5 .007 as 0.007 .0007 as 0 <- not blank 10.12345 as 10.123 10.1237 as 10.123 <- rounding Keith - CDI > On Aug 5, 2019, at 9:58 AM,

Re: [SPAM] Re: Finding duplicates

2022-03-19 Thread Keith Culotta via 4D_Tech
Here is a classic routine for finding duplicates. It has not been tested with null fields. // // Method: DuplicatesToSet //Search the current selection for duplicate values in a field. // // INPUT1: Pointer - to field to

Re: Image from print form

2022-03-19 Thread Keith Culotta via 4D_Tech
Mac's Automator has a PDF action to render each page of a passed PDF document as an image. in 4D: C_PICTURE($pic) READ PICTURE FILE(""; $pic) // read in PDF, all pages are in $pic, only page 1 is accessible to 4D If (OK=1) CONVERT PICTURE($pic; ".png") // only page 1 is in $pic End if

Re: Client communication

2024-03-05 Thread Keith Culotta via 4D_Tech
Can you use a Record in a Table that all Clients share? Also, EXECUTE ON CLIENT can have parameters. ** 4D Internet Users Group (4D iNUG) New Forum: https://discuss.4D.com Archive: http://lists.4d.com/archives.html Options:

<    1   2