Re: Scope of entity selection

2018-10-13 Thread Alan Chan via 4D_Tech
Hi Peter, I haven't touched v17 yet. There might be easier way. If not, you could try LONGINT ARRY FROM SELECTION and pack the array into shared object. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >This may be related to other thread - Defining and documentin

Re: Scheduled ISP Maintenance @ 4D Office (France)

2018-08-07 Thread Alan Chan via 4D_Tech
I guess most engineers of its ISP were on vacation (the famous French summer vacation). Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >I have been trying to get licensing since Friday Still no luck. > >dave > >On Tue, Aug 7, 2018 at 4:26 AM, Pat Bensky

Re: v16 & 17 components and plugins

2018-07-18 Thread Alan Chan via 4D_Tech
d.com/What-s-new/Deprecated-and-Removed-Features-17/Deprecated-or-removed-features-in-v17-product-range.200-3761903.en.html Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >Hi All, > >I am starting upgrade and can not see to find the following in install image > &

Re: What do you use to monitor your offsite servers?

2018-07-16 Thread Alan Chan via 4D_Tech
We use RealVNC on all servers but use TeamViewer for client machines. We used to use LogMeIn for client machines but our support guys prefer Teamviewer and I didn't ask why. Alan Chan ** 4D Internet Users Group (4D iNUG) FAQ

Re: just a curiosity - pre emptive threads

2018-07-13 Thread Alan Chan via 4D_Tech
Oops... I reply too fast. You've answered your question. Alan Chan Chip Scheide <4d_o...@pghrepository.org> writes: >(I think that to get around the Set process variable you would use >'Storage') ** 4D Internet Use

Re: just a curiosity - pre emptive threads

2018-07-12 Thread Alan Chan via 4D_Tech
May be using Shared Object to replace variable. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >1 - doesn't this idea 'break' with preemptive code (using Set Process >Variable)? >(I think that to get around the Set process variable you would use >'Storage'

Re: just a curiosity - pre emptive threads

2018-07-12 Thread Alan Chan via 4D_Tech
. When trigger was rejected, other updated tables won't roll back except the trigger invoking table. This would cause serious data integrity issue. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >transactional data entry is kind of task you would typically want to avoi

Re: just a curiosity - pre emptive threads

2018-07-12 Thread Alan Chan via 4D_Tech
even in LV shops. In some cases, shops do crowd control:-( For me, preemptive 4D Remote (if it's available) might be helpful on progress bar update in tight loop operations. Redrawing progress bar in cooperative process take up way more time than actual loop. Alan Chan 4D iNug Technical <4d_t

Re: just a curiosity - pre emptive threads

2018-07-12 Thread Alan Chan via 4D_Tech
in preemptive mode in server. However, Miyako San said it won't work on first reply due to UI but seems OK on 2nd reply (because of my unclear description). Just want to confirm before I rewrite all trigger codes (not trivial) and move away all IP variables. Alan Chan 4D iNug Technical <4d_tech@li

Re: just a curiosity - pre emptive threads

2018-07-12 Thread Alan Chan via 4D_Tech
16 and 17 are only beneficial for 4D based web server but not traditional client/server solution developers. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >DB4D requests (19814) are all preemptive since v11, >so if you call the command SAVE RECORD on the client side (a

Re: just a curiosity - pre emptive threads

2018-07-12 Thread Alan Chan via 4D_Tech
based on value in object and do SAVE RECORD in transaction - worker process call form to notify the entry dialog if transaction if OK or rejected Would it be OK? Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >UI cannot run in preemptive process, that is requirement of u

Re: just a curiosity - pre emptive threads

2018-07-12 Thread Alan Chan via 4D_Tech
are all preemptive-compliant - In this case, trigger won't be preemptive because the method above was called from UI. Am I correct? TIA Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >I agree it would be nice to eventually have preemptive mode on the client >side, but

Re: just a curiosity - pre emptive threads

2018-07-11 Thread Alan Chan via 4D_Tech
Of course, SAVE RECORD, DELETE RECORD is needed to invoke trigger. However, the method that call SAVE RECORD would be executed in 4D Remote and 4D Remote isn't supported. A dead lock? Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >there is no "thread safe" pr

Re: just a curiosity - pre emptive threads

2018-07-11 Thread Alan Chan via 4D_Tech
Hopefully, 4D remote could be supported in 4D 18:-( However, 4D server (thus triggers) is supported. I'm just wondering does anyone try that out on triggers? Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >Are you doing all this in single user mode? > >I think a lot

Re: "Your password does not allow you to use this form"

2018-05-24 Thread Alan Chan via 4D_Tech
May be trying to use Char(1) instead of "xxx". Char(1) works well for us. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >On v13.5: > >Forever, we've had a Labels option with this code: > >PRINT LABEL(Table(iTableNumber)->;"xxx") >

Re: Preventing Return and Enter from Closing a Dialog

2018-05-20 Thread Alan Chan via 4D_Tech
for decades. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >Thanks for everyone's help. I couldn't get the Database Settings >solution to work. Very weird. I set it to this and still "Enter" closed >the window. >https://www.dropbox.com/s/drzxr3othn8

Re: Preventing Return and Enter from Closing a Dialog

2018-05-20 Thread Alan Chan via 4D_Tech
Our system has all default Accept/Cancel shortcut unchecked in Database Design Interface setting. We disabled it 20+ years ago:-) It was a tough call back then. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >It gets weird if you have an application-wide default close a

Re: Preventing Return and Enter from Closing a Dialog

2018-05-20 Thread Alan Chan via 4D_Tech
Would setting the Standard Action to No Action be OK in button properties? Then add a method in button to do whatever you like. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >Aloha, > >I'm playing with the "proper" way to open up a form. Here's what I hav

Re: 4d servers down

2018-04-22 Thread Alan Chan via 4D_Tech
We can't access it either:-( Very unstable recently. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >livedoc, taow, 4dbb web servers do not respond. >So do you? > >-- >Arnaud de Montard > > > >**

Re: Error Code reserved by 4D

2018-02-03 Thread Alan Chan via 4D_Tech
Hmm... I didn't see -20002 there. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >which should logically exclude predefined error codes, >but even then, you are not prohibited from using a certain range. > >http://doc.4d.com/4Dv16R4/4D/16-R4/Error-Codes.2

Re: Error Code reserved by 4D

2018-02-02 Thread Alan Chan via 4D_Tech
Thanks for the info. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >adding to Tim's comments: > >you can return an arbitrary error code from on backup startup / shutdown > >http://doc.4d.com/4Dv16R4/4D/16-R4/On-Backup-Startup-database-method.301-3316874.en.ht

Re: Error Code reserved by 4D

2018-02-02 Thread Alan Chan via 4D_Tech
specific business rules. The error codes would be converted to verbose form to users. We use error code from -15001 to -2. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >Alan, > >Are you thinking about plugin id numbers? >ftp://ftp.4d.com/ACI_TECHNICAL_NOTES/2009/Ma

Error Code reserved by 4D

2018-02-02 Thread Alan Chan via 4D_Tech
I thought error codes under -15000 were not reserved by 4D. Now it produces error -20002 that might crash with user generated error for business rules control. Could anyone tell if 4D changes error code range reserved by 4D? TIA. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writ

Re: "Goodbye 4D Write" email

2018-02-01 Thread Alan Chan via 4D_Tech
Omnis is still around and very alive. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >How many of you >used to work using Foxbase, dBase, Omnis, to name a few. Just be greatful >that the company has been able to keep up with the times and is still a

Re: 4D v13 and Windows 10

2018-01-28 Thread Alan Chan via 4D_Tech
We don't know about 13.5. However, with 13.6, we haven't encountered any issue on Windows 10 so far. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >Hey everyone - in a nutshell, what's the current wisdom on 4D v13.5 >compatibility with the different flavors of Wind

Re: localisation (again)

2017-12-13 Thread Alan Chan via 4D_Tech
If ($k=46) //decimal $num:=$num*(10^-($len-$i-$j)) $len:=$i $j:=1 //$j+1 Else $len:=$len-1 End if End if End for If ($k=45) $num:=$num*-1 End if $0:=$num Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >Hi >But Thats what I'm doing, and its not working. &g

Re: poor performance LISTBOX INSERT COLUMN

2017-12-04 Thread Alan Chan via 4D_Tech
lumn instead of inserting column before existing columns. Optimization is fun although some developers are against it. Health warning : Optimization could be highly addictive and hazardous to your mentality. Alan Chan ** 4D

Re: poor performance LISTBOX INSERT COLUMN

2017-12-03 Thread Alan Chan via 4D_Tech
I just tested LISTBOX INSERT COLUMN command on array based LB that takes only 0 to 1 ms to complete on my MBP 2.90GHZ with 16G memory. I'm not sure if size of array is the factor. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >The LISTBOX INSERT COLUMN command takes o

Re: poor performance LISTBOX INSERT COLUMN

2017-12-03 Thread Alan Chan via 4D_Tech
with total 477 columns (unknow number of rows). Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >When customers ask for showing 10 listboxes at once on screen, with each >listbox having 20 columns I don't know if it is reasonable, but as you >probably know c

Re: Connection is broken, cannot receive request reply

2017-11-14 Thread Alan Chan via 4D_Tech
Just curious, 4 seconds for idle connections timeout? Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >SET DATABASE PARAMETER(54;4)// Idle connections timeout ** 4D Internet Users Group (4D iNUG) FAQ: htt

Re: Gridline for header in Listbox

2017-11-11 Thread Alan Chan via 4D_Tech
democracy . except on pricing:-) Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >really no alternating color?? >it makes reading the listboxes SO much easier. > >I use a pale green and white (like the old tractor fed paper), but let my >users select

Re: Gridline for header in Listbox

2017-11-10 Thread Alan Chan via 4D_Tech
Hi Keith, Good trick. For the moment, we didn't use zebra stripes for other reasons. We might simply draw a line under the header for Windows 10 users with Miyako's approach. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >Alan, I noticed this too - it does look od

Re: Gridline for header in Listbox

2017-11-10 Thread Alan Chan via 4D_Tech
this: > >https://github.com/4D-JP/4d-tips-listbox-header-border > >> 2017/11/10 17:47、Alan Chan via 4D_Tech <4d_tech@lists.4d.com> のメール: >> no line for header which looks odd. > > ** 4D Internet Use

Gridline for header in Listbox

2017-11-10 Thread Alan Chan via 4D_Tech
SET GRID($pheader->;true;true) LISTBOX SET GRID(*;$headerName;true;true) Any clue? TIA Alan Chan ** 4D Internet Users Group (4D iNUG) FAQ: http://lists.4d.com/faqnug.html Archive: http://lists.4d.com/archives.html Opti

Re: Normalization question

2017-11-08 Thread Alan Chan via 4D_Tech
Table Project Master Employee Master Project member Project master <- Project member -> Employee master Project member table contains Role (integer) 0=regular member; 1=role A; 2=role B; 3=whatever role Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >Given

Re: [Warning] Settings properties values on object field by object notation

2017-11-02 Thread Alan Chan via 4D_Tech
.nabble.com/Re-Warning-Settings-properties-values-on-object-field-by-object-notation-td5755127.html I guess 4D does not allow internal staffs filing feature request. Alan chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >These arguments should be posted on the feature request fo

Re: San Fransisco Font

2017-10-10 Thread Alan Chan via 4D_Tech
and not there yet. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >changing the font according to what you get from this, >or any other ways to obtain the system font name, >is going to fail when the app starts to display and accept text outside the

Re: v13 - replace string, odd slowness

2017-09-30 Thread Alan Chan via 4D_Tech
Just rewrite it not to use variable to blob which might be easier to read. C_TEXT($0;$1;$2;$3;$source;$oldStr;$newStr;$result;$tempTxt) //ES_ReplaceStr($source;$oldString;$newString;{$count pointer})->Resulted text C_POINTER($4)

Re: v13 - replace string, odd slowness

2017-09-30 Thread Alan Chan via 4D_Tech
Hi Chip, I forgot to mention that the method is for doc which is in utf16 format. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >To replace shorter old string with longer one, you could try the following:

Re: v13 - replace string, odd slowness

2017-09-29 Thread Alan Chan via 4D_Tech
;L") $blob{0x0003}:=Character code("B") $blob{0x0004}:=0x0021 $blob{0x0005}:=$newlen%256 $blob{0x0006}:=($newlen\256)%256 $blob{0x0007}:=($newlen\65536)%256 $blob{0x0008}:=($newlen\16777216) $offset:=0 BLOB TO VARIABLE($blob;$result;$offset) $0:=$result Else $0:=$1 End if If (Cou

Re: 4D v16.2 false record locks

2017-09-20 Thread Alan Chan via 4D_Tech
Hi Koen, I think your case is very different and might be v16 issue as user was still on server list and you couldn't disconnet it. The trigger issue (not actually an issue) I mentioned was the record was locked and the related user wasn't even on the server list. Alan Chan 4D iNug Technical

Re: 4D v16.2 false record locks

2017-09-19 Thread Alan Chan via 4D_Tech
If a record wasn't unloaded in trigger properly, the record would be locked even after the invoking client user left the system (no longer signed in). The only way is to restart the server. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >The client timeout will remove a

Re: Unable to Compile - Crash - looking for ideas - SOLVED

2017-08-21 Thread Alan Chan via 4D_Tech
Yes, this is highly recommended. "All Variables are typed" is one of greatest debug tool in 4D. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >I would also recommend changing the settings from > Generate Typing >to >

Re: Arrays vs Object for Key/Value pair lookups

2017-07-17 Thread Alan Chan via 4D_Tech
Case sensitive comparison support in Find in array/Find in sorted array is long overdue. Even best, supported in string compariosn operator (or new operator for string) $true:=($string1=*$string2) $true:=($string1>*$string2) $true:=($string1<*$string2) Alan Chan 4D iNug Technical &l

Re: Quick report strange behavior

2017-07-11 Thread Alan Chan via 4D_Tech
We do use v13.6 on Windows 8 and 10 without your problem. Did you try 13.6 instead of 13.3? v11 of 4D does exhibit problem you mentioned. I'm not sure if the problem exists in 13.3 or not. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >Hi all, > >No one use 4D V

Re: Interesting(?) Tales of Coding Was : Request for tech note

2017-07-11 Thread Alan Chan via 4D_Tech
I wrote a Get Prime routine in 56 lines of 4D code years ago for fun to generate prime number in array of whatever number users enter as parameter. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >https://i.redd.it/fjcv9ev

Re: What exactly is the scope of the On err call between 4D server & Client?

2017-07-07 Thread Alan Chan via 4D_Tech
We always install new On err call on triggers. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >I don't remember...triggers? ** 4D Internet Users Group (4D iNUG) FAQ: http://lists.4d.com/faqnug.html Archi

Re: Request : Text utilities

2017-07-06 Thread Alan Chan via 4D_Tech
Thanks. It's good to know. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >Well observed. Aussies can be *way* to polite to tell someone when they're >being rude, so, yeah, they might not complain about a little thing that &g

Re: Request : Text utilities

2017-07-06 Thread Alan Chan via 4D_Tech
We have been formatting Australia phone number like (2) 3456 7899 434 567 899 Are these acceptable by Australian? So far, we haven't got any complaint (may be they're too nice to say anything). TIA Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >Note that local cust

Re: Nested transactions - most appreciated feature

2017-07-02 Thread Alan Chan via 4D_Tech
It's our standard design to do test "In Transaction" and Trigger Level in trigger. We never used cascade trigger either. Error handling in trigger is also standard in our design. We have to create large error code base for error interpretion in multiple language. Alan Chan 4D iNug

Re: Nested transactions - most appreciated feature

2017-07-02 Thread Alan Chan via 4D_Tech
1 nested transaction n for task n End Master transaction or Transaction update task 1 update task n End transaction Any difference? Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >I have a slightly different take from Peter's - consider attempting to make >changes i

Re: Nested transactions - most appreciated feature

2017-07-02 Thread Alan Chan via 4D_Tech
don't see nested transaction is required except the component part that I have no knowledge at all. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: > >I’ve never considered transactions as a UI tool (mainly because it’s a bit of >a nightmare matching the scope of the open

Re: Nested transactions - most appreciated feature

2017-07-02 Thread Alan Chan via 4D_Tech
on assumption of my understanding on nested transaction and could be wrong. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >They execute in milliseconds as I never put user interfaces - or even alerts - >inside transactions. Just a lot of error handling and then report the e

Re: Nested transactions - most appreciated feature

2017-07-01 Thread Alan Chan via 4D_Tech
It's a great feature if long transaction that holding up records isn't an issue to your operation. Of course, make sure no one would take coffee in the middle of a transaction:-) We could only afford single transaction started and ended within a short wrapper method. Alan Chan 4D iNug

Re: v13 (+?) - Replace String [warning]

2017-06-27 Thread Alan Chan via 4D_Tech
5}:=$newlen%256 $blob{0x0006}:=($newlen\256)%256 $blob{0x0007}:=($newlen\65536)%256 $blob{0x0008}:=($newlen\16777216) $offset:=0 BLOB TO VARIABLE($blob;$result;$offset) $0:=$result Else $0:=$1 End if If (Count parameters>3) $4->:=$count End if Alan Chan 4D iNug Technical <

Re: USE DATABASE from 4D client

2017-05-31 Thread Alan Chan via 4D_Tech
I might be missing something obvious. Why not simply using SQL login to access external database and the data could be accessed by multiple 4D clients. SQL LOGIN($externaAddress;$user;$pswd;*) If (OK=1) Begin SQL //do whatever SQL query End SQL SQL LOGOUT End if Alan Chan 4D iNug Technical

Re: Compatibility Mode v12 (How to change to Unicode?)

2017-05-23 Thread Alan Chan via 4D_Tech
. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >there is a way to apply a specific encoding for each table during conversion > >ftp://ftp-public.4d.fr/Documents/Products_Documentation/LastVersions/Line_11/VIntl/PDF_Format/4D_v11_Upgrade.pdf > >see the descripti

Re: Compatibility Mode v12 (How to change to Unicode?)

2017-05-23 Thread Alan Chan via 4D_Tech
could be veiwed in new version. However, data in other non-roman character sets couldn't be viewed correctly and requires manual update (re-enter the field). YMMV Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >3) How do I convert the existing text data in records (an

Re: Corrupted index that won't fix

2017-05-21 Thread Alan Chan via 4D_Tech
If you have removed a table or field, then add new table or field, it might cause problem if the old data is still there. Repair it might help. It won't harm if it doesn't. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >I verified a data file and MSC reported the data

Re: v13 - Send record

2017-05-17 Thread Alan Chan via 4D_Tech
Did you check OK variable after SET CHANNEL? By the way, I prefer using Goto Selected Record instead of Next Record. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >SET CHANNEL(10;$File_Path) > >For ($i;1;Records in selection([Bug_Reporting])) >SEND RECORD([Bug

Re: How to detect EOL character in text file

2017-05-15 Thread Alan Chan via 4D_Tech
Replace String($text;lf;cr) -> all lf becomes cr including crlf becoming crcr Replace string($text;crlf;cr) -> none would be found That's why you need to run Replace String($text;crlf;cr) first. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >That should have read

Re: Schemes for record level access control

2017-05-15 Thread Alan Chan via 4D_Tech
:-) Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >Much like others have indicated, stay as far away as you can from the built in >4D access shit, it's for amatures. ** 4D Internet Users Group (4D iNUG) FAQ:

Re: Schemes for record level access control

2017-05-12 Thread Alan Chan via 4D_Tech
It would be a lot easier if 4D password system is activated. Just a new group "TeamAccess_Bypass". LIke I said before, 4D password system does great help on achieving this. While we find 4D password system is invaluable, I know many developers don't like it. Alan Chan 4D iNug

Re: Schemes for record level access control

2017-05-12 Thread Alan Chan via 4D_Tech
aded from team member table at startup method. Query selection with array is NOT preemptive in 4D 13/15 that might have performance hit on server. Based on v16 doc, this command would be preemptive and hopefully it does not have hidden limitation. Alan Chan 4D iNug Technical <4d_tech@lists.4d.c

Re: Schemes for record level access control

2017-05-12 Thread Alan Chan via 4D_Tech
I assume a member might belongs to multiple teams but will a member belongs to multiple clubs? Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >Hi Alan, >Those are the go-to solutions. In my case we aren't using the 4D password >system so I can't rely on that. Plu

Re: Counting # of specific characters in string/text

2017-05-08 Thread Alan Chan via 4D_Tech
Hi Chip, Thanks for your advice. The discussion is about how optimized Replace String is in v16 especially on * operation even comparing with position(*) which supposed to be very fast. It's not about how to design a 4D app with those commands. Alan Chan 4D iNug Technical <4d_tech@li

Re: Counting # of specific characters in string/text

2017-05-06 Thread Alan Chan via 4D_Tech
Hi Chip We have been talking about * all along. Without * has never been in my test. My test always consider total length of text "and" total count of occurrence. My test is for 4,300,000 length text and 100,000 occurrence. It took 14ms on my machine. Alan Chan 4D iNug Technica

Re: Counting # of specific characters in string/text

2017-05-06 Thread Alan Chan via 4D_Tech
Oops... my bad. Reading too fast. Please ignore this. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >I found out why your result is quite different from mine. In your code, you >evaluate the time once per execution of position. However, the replace string >was eva

Re: Counting # of specific characters in string/text

2017-05-06 Thread Alan Chan via 4D_Tech
Hi Arnaud, I found out why your result is quite different from mine. In your code, you evaluate the time once per execution of position. However, the replace string was evaluated once per 10,000 replacement (per execution of replace string). Alan Chan 4D iNug Technical <4d_tech@lists.4d.

Re: v13: what causes boolean fields to display radios instead of check boxes

2017-04-20 Thread Alan Chan via 4D_Tech
This was a known problem only happened on Mac. The issue seems fixed in 13.6. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >Hi Walt, > >No, not grouped. > >I worked around it by using OBJECT SET FORMAT in the on load event. Which >works but begs th

Re: y2038 -- is 4D ready?

2017-03-29 Thread Alan Chan via 4D_Tech
I agree. Longint for sequence number would definitely outlast me:-( Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >last I knew (this could easily have changed) >Sequence number range is +/- MAX LONGINT (so ~2.1 x 10^9) > > >On Wed, 29 Mar 2017 18:38:56 +0800,

Re: y2038 -- is 4D ready?

2017-03-29 Thread Alan Chan via 4D_Tech
4D would support 64bit integer by then. If not, sequence number (or auto-increment) would be the first one to get in trouble. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >so code to convert date to epoch time like that one just recently discussed >(Re: [4DTidbits

Re: 4D v15.4: Sequence number issue / Duplicate key error

2017-03-08 Thread Alan Chan via 4D_Tech
ey->=0) //only if auto-increment wasn't activated yet $pTable:=FieldToFilePtr ($2)`return table pointer $SeqNo:=Sequence number($pTable->) $F:=Find in field($pSeqkey->;$SeqNo) If ($F=-1) $pSeqkey->:=$seqNo Else $error:=SetError ($error;-17160) End if End if End if $0:=$error

Re: Sierra 10.12.3

2017-02-17 Thread Alan Chan via 4D_Tech
Hi David, It WORKS like a charm! THANKS for sharing the tips. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >We ran into the v13 / MacBook Pro with touchbar crashing issue in Sierra >10.12.1 and 10.12.2. The fix was maddeningly simple - instead of attempting

Re: Move v12 to v15 or v16

2017-01-18 Thread Alan Chan
For v16 on pure Mac environment, would it be possible to use 32bit client but 64bit server in new network layer? Alan Chan ** 4D Internet Users Group (4D iNUG) FAQ: http://lists.4d.com/faqnug.html Archive: http://lists.4d.com

Re: Move v12 to v15 or v16

2017-01-18 Thread Alan Chan
Not until you have clients using touch bar macbook pro. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >What other info do you have re OS version on Mac. I am having NO problems with >15.2 ** 4D In

Re: Query editor in v15

2016-12-09 Thread Alan Chan
Interesting. Most IT folks like the old query editor when we showed it the first time. Also, most mid managers found it easy to understand and use even they don't have IT knowledge. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >The old query editor is really confusing

Re: Query editor in v15

2016-12-09 Thread Alan Chan
before) or better performance. We have written few libraries for type ahead with/without entry box for table/fields or column content for our other works. However, writing entire interface simulating the classic query editor takes time. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com>

Re: Query editor in v15

2016-12-09 Thread Alan Chan
Aruh we have 204 tables:-( Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >Miyako has done a great job here. > >However, it takes about 10 seconds for the dialog to open. I suppose it’s >because we have about 220 tables and it’s taking the time to analy

Re: Query editor in v15

2016-12-09 Thread Alan Chan
Hi Paul, Please let us know how it works. I love its localization. Thanks to another great work from Miyako that ease migration to v15. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >Thanks, > >I’ll look at that! > > >Paul > > >> Le 9 déc. 2016

Re: Memory settings

2016-12-04 Thread Alan Chan
a few bucks on ram. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >I have one 4d application on windows that work on many records. >The machine: >Xeon, Windows server, 4 GB of ram and run only 4D. >The application is compiled, and work in client server. > >

Re: is keyword indexed a field?

2016-11-24 Thread Alan Chan
Yes, it's a bit confusing. I tested the field type and if it's text or apha field has length more than 50, it's keyword index, else it's cluster Btree. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >I'd like to know if a field (alpha or text) has a keyword index. &

Re: Date Question...

2016-11-19 Thread Alan Chan
I forgot 4D doesn't do that, my code did that. I apologized for the confusion. Simply use Add to date(!00/00/!;year;month;day) Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >Anyway, if fixed date is really required for any reason, use internationally >recognizable

Re: Date Question...

2016-11-19 Thread Alan Chan
is really required for any reason, use internationally recognizable "-MM-DD". Your app would work regardless regional settings your users are using. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >What do you use instead of date constants to specify a sp

Re: v12+ parsing text [summary]

2016-11-17 Thread Alan Chan
Isn't it fun and rewarding:-) Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >My new code imports the same 50 meg file (compiled) in just over 1 >minute. ** 4D Internet Users Group (4D iNUG) FAQ:

Re: v12+ parsing text

2016-11-17 Thread Alan Chan
I can't agree more. Array was not mentioned in Chip's original post. Always decide size of array before hand by evaluating the source using position to count stop char or using \ and % to calculate if length of element is deciding factor. Alan Chan 4D iNug Technical <4d_tech@lists.4d.

Re: v12+ parsing text

2016-11-16 Thread Alan Chan
You're running only substring and your modifiedSubstring. A piece of code segment cannot tell much how you use substring and your modifiedSubstring. For your information, using blob should be able to take less than 2 seconds in compiled. Alan Chan 4D iNug Technical <4d_tech@lists.4d.

Re: v12+ parsing text

2016-11-16 Thread Alan Chan
be very fast. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >I have a routine which parses text. >It seemed to function well, until recently, when I had to feed it 50 >megs of text (48.3 million characters). >The data is Cr delimited, and each line of text is of variab

Re: Sequence Number Not Incrementing

2016-11-16 Thread Alan Chan
Why do you want to do [contact_Listing]ID+1? I believe the command will add one to the number you entered next time sequence number is called. In your case, the system will skip one number. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >ALL RECORDS([Contact_Listing

Re: Sequence Number Not Incrementing

2016-11-16 Thread Alan Chan
is Transaction > You mean the record was not saved in transaction or it was saved but doesn't generate correct sequence number? Alan Chan ** 4D Internet Users Group (4D iNUG) FAQ: http://lists.4d.com/faqnug.html Archi

Re: Intermittent no splash screen with a 4D Server 2004.8 database

2016-11-12 Thread Alan Chan
Startup method? Alan Chan dgarr...@gmail.com writes: >I am wondering if anyone has experienced the following: > > > >On a long-time installation now using Windows 4D Server 2004.8 in >interpreted mode, I have recently had reports of intermittent opening of the >spl

Re: Automatic Variable Assignment and Web Get Variables - Bad usage of pointer or pointer to an unknown variable

2016-11-10 Thread Alan Chan
it with object since I am still using v13. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: > >try it 1000 times and compare it with the object method > >> Am 10.11.2016 um 16:18 schrieb 4d_tech-requ...@lists.4d.com: >> >> Find in Array is sequential

Re: Automatic Variable Assignment and Web Get Variables - Bad usage of pointer or pointer to an unknown variable

2016-11-10 Thread Alan Chan
Find in Array is sequential search. I just try to use Binary search on sorted text array with 2,000,000 elements. It took 0 ms. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >If I change the search parameter to Variable_2_name, the array takes twice &g

Re: What's it take to get access to the Super Reports forum?

2016-10-20 Thread Alan Chan
Same here. We made a feature request on ALP and got replied in few hours and a new beta version in just a few days. No, they didn't request us to create a demo first. Oops.. I can't believe I said that:-) Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >With PrintList Pr

Re: 4D Server in the cloud

2016-10-05 Thread Alan Chan
didn't see any doc mentioned about that in any new versions .. That's why I wonder if it has been done or ... Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >I'm *sure* those are read from local resources, and most probably many >commands from the chapter "Stru

Re: 4D Server in the cloud

2016-10-02 Thread Alan Chan
Hi Arnaud, Thanks for your test. Definitely i hope that mine is wrong. I'll do a clean sniffer by segmenting a single client/server once I finish a little project on hand to clear my doubt for these years. I hate being lazy:-( Alan Chan 4D iNug Technical <4d_tech@lists.4d.com>

Re: 4D Server in the cloud

2016-09-30 Thread Alan Chan
d that I was surprise. I still hope that I was misinformed but too lazy to *sniffer* it. We have been running 4D over WAN since v3.5x, this made us very traffic cautious for decades. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: > >> Le 30 sept. 2016 à 11:00, Al

Re: XLIFF Editor for macOS?

2016-09-25 Thread Alan Chan
Why not writing your own XLIFF converter in 4D? We prepare the language in simple text in CSV format just in TextEdit. After translation, we simply convert the text into XLIFF with 4D code. Alan Chan 4D iNug Technical <4d_tech@lists.4d.com> writes: >I am using XLIFF with the resna

Re: Searching Nul UUIDS

2016-09-24 Thread Alan Chan
When the field is null, it's not index. Query won't work well. I guess the single user mode would use non-index query by loading record. I used different approach by using set that work well and doesn't need to load every record just for checking if it's null. Alan Chan 4D iNug Technical

Re: Why is there not a Month (and Day) Name function?

2016-08-11 Thread Alan Chan
Oops... I replied too fast. Chinese grammer shouldn't have "," after weekday. I just checked on my Mac, Apple does add "," after weekday by default unless users modify it. Your code work:-) But again, adding element in xliff is easier for me and fool proof. Alan Chan 4D iNu

  1   2   >