Re: Pluggers Software releases NTK Plugin 3.0

2016-11-17 Thread Paul Dennis
Blimey, that is a major update Rob, Framework looks very interesting. For
anyone else trying the demo its v13 on port 8080. With the web demo I
couldnt get past the web login page or create account. Bit more info on demo
would be useful.
Cheers
Paul 



--
View this message in context: 
http://4d.1045681.n5.nabble.com/Pluggers-Software-releases-NTK-Plugin-3-0-tp5748811p5748827.html
Sent from the 4D Tech mailing list archive at Nabble.com.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Date Question...

2016-11-17 Thread Keisuke Miyako
I guess it just affirms the point that date constants are too ambiguous and not 
worth your while.

$dateA:=!2016-12-15!
$yearA:=Year of($dateA)  //2016

$dateB:=!16-12-15!
$yearB:=Year of($dateB)  //16?
ASSERT($dateA=$dateB)

> 2016/11/18 7:23、Dennis, Neil  のメール:
>
> The 4D manual says this about dates:
>Date: 1/1/100 to 12/31/32767
>
> So what is this date constant?
>$d:=!16-12-15!
>
> FYI - It is not the same as !2016-12-15!




宮古 啓介
セールス・エンジニア

株式会社フォーディー・ジャパン
〒150-0043
東京都渋谷区道玄坂1-10-2 渋谷THビル6F
Tel: 03-6427-8441
Fax: 03-6427-8449

keisuke.miy...@4d.com
www.4D.com/JP

**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

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

2016-11-17 Thread Keisuke Miyako
> 2016/11/18 12:28、Michael McCall  のメール:
> Keisuke made a reference to using Not(Nil( $p))) and Type($p->) following Get 
> pointer.
> I played with that but can't quite see how that would work.

I was thinking of something like:

> C_TEXT(V1)
> C_REAL(V2)
>
> ARRAY TEXT($names;2)
> $names{1}:="V1"
> $names{2}:="V2"
>
> ARRAY TEXT($values;2)
> $values{1}:="abc"
> $values{2}:="123"
>
> For ($i;1;Size of array($names))
>
>   ON ERR CALL("myErrorHandler")
>   $p:=Get pointer($names{$i})
>   ON ERR CALL("")
>
>   If (Not(Nil($p)))
>   $type:=Type($p->)
>   Case of
>   : ($type=Is text)
>   $p->:=$values{$i}
>   : ($type=Is real)
>   $p->:=Num($values{$i})
>   End case
>   End if
>
> End for


an error handler is needed because Get pointer will throw an error if the 
string doesn't evaluate as a variable.

e.g. Get pointer("type")


宮古 啓介
セールス・エンジニア

株式会社フォーディー・ジャパン
〒150-0043
東京都渋谷区道玄坂1-10-2 渋谷THビル6F
Tel: 03-6427-8441
Fax: 03-6427-8449

keisuke.miy...@4d.com
www.4D.com/JP

**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

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

2016-11-17 Thread David Adams
> Since OB Is Defined is case sensitive I cannot use it unless I spend days
cleaning up my code.

I haven't followed this thread and just have a minute, but thought I'd
mention that a standard cheat for defeating unwanted case-sensitivity in
comparisons it to convert everything to lower or uppercase before
comparing. 4D variable names are not case-sensitive, so just set the string
of the name to all to lower or upper before storing the names in your
object. Same with the incoming values that you want to check, set them to
the matching case before comparison with the values in the object.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

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

2016-11-17 Thread Michael McCall
In brief and as a reminder, I need a way to quickly assign values to variables 
received from a web page. The problem I have is that if a field submitted on a 
web page does not exist it produces a  runtime error messages in a compiled 
data base indicating a bad usage of a pointer. The process stops until continue 
or abort is selected. 

I want a way to just ignore any instances where the variable does not exist in 
the data base.  Lee's suggestion of putting my 25,000 variables in an object 
and using OB Is Defined looked like a fast easy solution. Unfortunately I was 
sloppy over the last 25 years it turns out and I have not consistently made use 
of case convention in my variable names. Since OB Is Defined is case sensitive 
I cannot use it unless I spend days cleaning up my code. I will put that on the 
list for the future, but, in the meantime, does anyone have any other quick 
solutions? 

Keisuke made a reference to using Not(Nil( $p))) and Type($p->) following Get 
pointer. I played with that but can't quite see how that would work. In essence 
I would just like to bypass or ignore any situations where the 
arr_Web_Field_Name is not actually a defined variable name so I don't get the 
runtime error messages related to bad usage of a pointer which in turn halts 
the process until I click the continue button.  

Any suggestions? Hopefully I'm just missing something obvious and simple here.

WEB GET VARIABLES(arr_Web_Field_Name;arr_Web_Field_Value)
For ($i;1;Size of array(arr_Web_Field_Name))
$p:=Get pointer(arr_Web_Field_Name{$i})
$p->:=arr_Web_Field_Value{$i}
End for


Thanks again,
Mike McCall





ORIGINAL POST FROM NOVEMBER 9, 2016: 

Thanks in advance for any assistance,

This is probably something I should know and clearly something I could do 
differently but for now I'm hoping for an easy solution.

I believe 4D is moving away from the Automatic Variable Assignment option when 
using a browser to access a 4D enabled Web server. As they do that I believe 
the replacement approach is to use Web Get Variables. Because we have a silly 
number of variables (i.e., 20,000) which could be called from any given web 
page we'd like use something similar to the code below to assign the values 
received using Web Get Variables to their corresponding and existing variables 
using pointers. That would allow us to move away from the Automatic variable 
assignment without a major rewrite to our code.

In an uncompiled application the code works fine. 

In a compiled application it works fine as well unless someone were to 
maliciously or somehow inadvertently submit a web page with a field name which 
was not defined in our application. In brief if they modified an html form to 
submit to our application and added a non-existent field, then a -20010 error - 
Bad usage of pointer or pointer to an unknown variable message would be 
generated and the connection would hang until we clicked OK on the message on 
the server.

Is there any way we could avoid this from happening? We were hopeful that using 
"undefined" would help but that doesn't work in a compiled database. 

Aside from a major rewrite of how we handle the fields from a form statement 
does anyone know how we could just ignore unknown field names o handle them 
without the error message being generated in a compiled database?

Code used during On Web Authentication

C_TEXT($1;$2;$3;$4;$5;$6)
C_TEXT(vtSystem_Password;vtSystem_User;vtSystem_Server_IP;vtSystem_Client_IP;vtSystem_Hdr;vtSystem_URL)
$0:=True
vtSystem_URL:=$1
vtSystem_Hdr:=$2
vtSystem_Client_IP:=$3
vtSystem_Server_IP:=$4
vtSystem_User:=$5
vtSystem_Password:=$6

C_TEXT(Dummy;Web_TM_Accessed_By)  //variables which are not typed explicitly or 
by reference during compilation. They could be deleted
$vt_GetOrPost:=""
$vt_GetOrPost:=Substring(vtSystem_Hdr;1;4)
If ($vt_GetOrPost="Post")
ARRAY TEXT(arr_Web_Field_Name;0)
ARRAY TEXT(arr_Web_Field_Value;0)
WEB GET VARIABLES(arr_Web_Field_Name;arr_Web_Field_Value)

C_BOOLEAN($test)
  //  $start:=Milliseconds

For ($i;1;Size of array(arr_Web_Field_Name))
  //ALERT(string($i)+" - "+arr_Web_Field_Name{$i})
Case of 
: (arr_Web_Field_Name{$i}="vbFileName")

C_TEXT($vPartName;$vPartMimeType;$vPartFileName;$vDestinationFolder)
C_BLOB($vPartContentBlob)
C_BLOB(vbFileName)
C_LONGINT($i)
  //$vDestinationFolder:=Get 4D folder(HTML 
Root folder)+"photos"+Folder separator
For ($j;1;WEB Get body part count)  //for each 
part
WEB GET BODY 
PART($i;$vPartContentBlob;$vPartName;$vPartMimeType;$vPartFileName)
If ($vPartFileName#"")
 

RE: Saving a backup to a network share when running as a service

2016-11-17 Thread Joshua Hunter
Thanks Tom & Bill for the replies.

It looks like the issue is that when selecting a backup location 4D uses the 
mapped drive letter. When running as a service you cannot used mapped drives, 
but need to use the full UNC path. That doesn't seem to be possible with 4D.

We have recommended exactly what Tom suggests: backup locally and copy to 
another location as separate operations.

Thanks,

Joshua

From: Benedict, Tom [mailto:tom.bened...@optum.com]
Sent: Thursday, November 17, 2016 2:31 PM
To: Joshua Hunter; 4D_Tech@lists.4D.com
Subject: Re: Saving a backup to a network share when running as a service


Joshua Hunter writes:



We have a customer running our 4D server application (compiled) as a Windows 
service. They want to direct their backup to a network location. This works 
when they run the application interactively, but not when they run it as a 
service.



I recommend that they do both. 4D Backup to the same drive that the data file 
is on followed by a windows copy of the backup file to another drive anywhere 
that they have permission. That uncouples the process into two independent, 
highly reliable processes. Each can run without affecting the other.



And if the environment/business can support it, consider mirroring. But that is 
usually beyond the range of all but enterprise customers.



HTH,



Tom Benedict

Optum


This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Pluggers Software releases NTK Plugin 3.0

2016-11-17 Thread Rob Laveaux
My apologies for double posting. The original email contained a typo in the 
link. Here is the corrected version.


Pluggers Software releases NTK Plugin 3.0

Networking ToolKit (NTK) is a plugin that offers a rich tool set for network 
communication. Version 3.0 includes many new exciting features. The most 
important new features are:

- 64-bit mode support on Mac & Windows
- A built-in JavaScript interpreter with an object oriented framework for 
interacting with the 4D database and an ExpressJS inspired framework for 
writing REST services.
- An updated example database demonstrating an AngularJS based front-end 
interacting with the JavaScript interpreter.
- Support for TLS Server Name Identification (SNI).
- A random password generator.
- Updated encryption commands with support for initialisation vectors and 
passwords in hex and base64 encoding.
- Improved Markdown functionality with support for GitHub flavoured markdown.

Please refer to the section "Version history" of the documentation for a 
complete overview of the changes.

For more information:
http://www.pluggers.nl/product/ntk-plugin/

- Rob Laveaux


Pluggers Software
Scholekstersingel 48
2496 MP  Den Haag
The Netherlands

Email: rob.lave...@pluggers.nl
Website: http://www.pluggers.nl





**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Saving a backup to a network share when running as a service

2016-11-17 Thread Benedict, Tom
Joshua Hunter writes:



We have a customer running our 4D server application (compiled) as a Windows 
service. They want to direct their backup to a network location. This works 
when they run the application interactively, but not when they run it as a 
service.



I recommend that they do both. 4D Backup to the same drive that the data file 
is on followed by a windows copy of the backup file to another drive anywhere 
that they have permission. That uncouples the process into two independent, 
highly reliable processes. Each can run without affecting the other.



And if the environment/business can support it, consider mirroring. But that is 
usually beyond the range of all but enterprise customers.



HTH,



Tom Benedict

Optum

This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Date Question...

2016-11-17 Thread Dennis, Neil
The 4D manual says this about dates:
Date: 1/1/100 to 12/31/32767

So what is this date constant?
$d:=!16-12-15!

FYI - It is not the same as !2016-12-15!



Neil




--


Privacy Disclaimer: This message contains confidential information and is 
intended only for the named addressee. If you are not the named addressee you 
should not disseminate, distribute or copy this email. Please delete this email 
from your system and notify the sender immediately by replying to this email.  
If you are not the intended recipient you are notified that disclosing, 
copying, distributing or taking any action in reliance on the contents of this 
information is strictly prohibited.

The Alternative Investments division of UMB Fund Services provides a full range 
of services to hedge funds, funds of funds and private equity funds.  Any tax 
advice in this communication is not intended to be used, and cannot be used, by 
a client or any other person or entity for the purpose of (a) avoiding 
penalties that may be imposed on any taxpayer or (b) promoting, marketing, or 
recommending to another party any matter addressed herein.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: v12+ parsing text [summary]

2016-11-17 Thread Chip Scheide
for posterity  :)

My new parsing routine (followed by new substring routine)

  //Project Method: utl_Text_Fast_Parse
  //$1 - pointer - to text to parse
  //$2 - longint (optional) - number of times to find character(s) 
(default is one)
  //$3 - text (optional) - text delimter to find (default is tab)

  //rewritten utl_text_ParseString

  //l_Last_Position is a 'pointer' to last character in source text 
that was found
  //in any previous call to this method - on the same source text 

  //NOTE : MUST call utl_Text_Fast_Parse_Init first

  //Ex:  utl_Text_Fast_Parse("A,B,C,D,E,F"; 3; ",") -> "C"
  //   utl_Text_Fast_Parse("A,B,C,D,E,F"; 1; ",") -> "A"
  //   utl_Text_Fast_Parse("A,B,C,D,E,F"; 6; ",") -> "F"

  //RETURNS - text - text located between the last occurence and the 
most
  //recent occurence of the Find text, or text between last 
occurence, and end of source
  //if the FInd text is not located
  // ∙ Created 11/16/16 by Chip - 
C_LONGINT(l_Last_Position;$Start_Loc;$Current_Loc;$2;$How_Many;$Find_Length)
C_LONGINT($i;$Found_Location)
C_TEXT($3;$Find;$0;$Return_Text)
C_POINTER($1)  //for compatability with old utl_text_ParseString
C_BOOLEAN($Truncate)

$Source:=$1

Case of 
: (Count parameters=1)
$Find:=<>x_Tab
$How_Many:=1

: (Count parameters=2)  //2 parameters
$How_Many:=$2
$Find:=<>x_Tab

: (Count parameters>=3) & ($3#"")  //3 parameters and not blank
$Find:=$3
$How_Many:=$2

: (Count parameters>=3)  //3 parameters and blank
$How_Many:=$2
$Find:=<>x_Tab
End case 
$Find_Length:=Length($Find)

For ($i;1;$How_Many)  //for however many delimeters requested
$Start_Loc:=l_Last_Position+1  //start at the next character after last 
iteration
$Found_Location:=utl_text_Position ($Find;$Source->;$Start_Loc)

If ($Found_Location>0)  //found
l_Last_Position:=$Find_Length+$Found_Location-1
Else   //does not exist
$i:=utl_Exit_Loop 
End if 
End for 

If ($i=MAXLONG)  //not found. or not found enough times
$Return_Text:=utl_text_Faster_Substring ($Source->;$Start_Loc)
Else   //found requested occurence count of Find
$Return_Text:=utl_text_Faster_Substring 
($Source->;$Start_Loc;l_Last_Position-$Start_Loc)
End if 
$0:=$Return_Text
  //End utl_Text_Fast_Parse
---

  //Project Method: utl_text_Faster_Substring
  //$1 - pointer - to text source text to find substring
  //$2 - longint - Start Location
  //$3 - longint (optional) - Character count, 
  //   if not provided, or zero, return all beginning at $2

  //faster substring code

  // ∙ Created 11/16/16 by Chip - 
C_POINTER($1;$Source)
C_TEXT($0;$Return_Text)
C_LONGINT($2;$Start_Location;$3;$Return_Length)
C_LONGINT($i;$Source_Length;$Current_Char)

$Source:=$1
$Start_Location:=$2
$Source_Length:=Length($Source->)

Case of 
: (Count parameters=2)
$Return_Length:=Length($Source->)

: ($3=0)
$Return_Length:=Length($Source->)
Else 
$Return_Length:=$3
End case 

Case of 
  //these values need to be tweeked, as they are just guesses
  //but looping over the characters *IS* faster then substring -
  //for some lengths these values worked well as a starting point
: (($Return_Length<=30) & (Not(Is compiled mode))) | \
((Is compiled mode) & ($Return_Length<=130))

For ($i;1;$Return_Length)
$Current_Char:=$i+$Start_Location-1

If ($Current_Char<=$Source_Length)
$Return_Text:=$Return_Text+$Source->≤$Current_Char≥
Else 
$i:=utl_Exit_Loop 
$Return_Text:=""
End if 
End for 
Else   //long return length use substring - faster
$Return_Text:=Substring($Source->;$Start_Location;$Return_Length)
End case 
$0:=$Return_Text
  //End utl_text_Faster_Substring



On Thu, 17 Nov 2016 13:41:48 -0800, Douglas von Roeder wrote:
> Chip:
> 
> Nice recap.
> 
> I'm interested in understanding the difference between passing a pointer
> and dereferencing the pointer during the operation versus passing a
> pointer, working on a local, and then doing Copy
> array($localTextArr_AT;t$arrayPtr_P->).
> 
> Over the years, I've wondered about the performance penalty of passing by
> reference and, when I asked the question at the Summit, the immediate
> answer was that operations took 1.6 times as long.
> 
> With that in mind, I'm following the Copy array approach when working with
> anything but trivial amounts of data. Given that you're dealing with large
> amounts of data, it might be interesting to see if the 1 minute elapsed
> time could be reduced by that change.
> 
> 
> --
> Douglas von Roeder
> 949-336-2902
> 
> On Thu, Nov 17, 2016 at 1:29 PM, Alan Chan  wrote:
> 
>> 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:  http://lists.4d.com/faqnug.html
>> Archive:  http://lists.4d.com/archives.html
>> Options: http://lists.4d.com/mailman/options/4d_tech
>> Unsub:  

Re: v12+ parsing text [summary]

2016-11-17 Thread Chip Scheide
I'm not working with arrays (being passed)
but a single text variable.

x_Parse:=ax_File_Contents{$Current_File_Text_Block}
then x_Parse is worked on/with

So a method call looks like this:
utl_text_Fast_Parse(->x_Parse;$Delimeter_Count;$Delimeter)


BUT if I were working with the array directly, I would pass a pointer 
to the element
utl_text_Fast_Parse(-> 
ax_File_Contents{$Current_File_Text_Block};$Delimeter_Count;$Delimeter)


On Thu, 17 Nov 2016 13:41:48 -0800, Douglas von Roeder wrote:
> 
> I'm interested in understanding the difference between passing a pointer
> and dereferencing the pointer during the operation versus passing a
> pointer, working on a local, and then doing Copy
> array($localTextArr_AT;t$arrayPtr_P->).
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Pluggers Software releases NTK Plugin 3.0

2016-11-17 Thread Rob Laveaux
Pluggers Software releases NTK Plugin 3.0

Networking ToolKit (NTK) is a plugin that offers a rich tool set for network 
communication. Version 3.0 includes many new exciting features. The most 
important new features are:

- 64-bit mode support on Mac & Windows
- A built-in JavaScript interpreter with an object oriented framework for 
interacting with the 4D database and an ExpressJS inspired framework for 
writing REST services.
- An updated example database demonstrating an AngularJS based front-end 
interacting with the JavaScript interpreter.
- Support for TLS Server Name Identification (SNI).
- A random password generator.
- Updated encryption commands with support for initialisation vectors and 
passwords in hex and base64 encoding.
- Improved Markdown functionality with support for GitHub flavoured markdown.

Please refer to the section "Version history" of the documentation for a 
complete overview of the changes.

For more information:
http://www.pluggers.nl/ntk_plugin.html


- Rob Laveaux


Pluggers Software
Scholekstersingel 48
2496 MP  Den Haag
The Netherlands

Email: rob.lave...@pluggers.nl
Website: http://www.pluggers.nl





**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Saving a backup to a network share when running as a service

2016-11-17 Thread Bill Weale
I would get to the point where things would run for a few days, then break, for 
reasons I couldn’t explain. Only thinking was that of all the permissions 
potentially involved, network configuration change or OS patch could easily 
break things.

—Bill

> On Nov 17, 2016, at 4:19 PM, Joshua Hunter  wrote:
> 
> We have a customer running our 4D server application (compiled) as a Windows 
> service. They want to direct their backup to a network location. This works 
> when they run the application interactively, but not when they run it as a 
> service.
> 
> I've let them know that backing up locally is preferred for a number of 
> reasons, but they still want to backup to the network location.  I've tried 
> providing the same user credentials to the service that we use to run 
> interactively without any luck.
> 
> Has anyone had success with this?

**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

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:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Saving a backup to a network share when running as a service

2016-11-17 Thread Joshua Hunter
We have a customer running our 4D server application (compiled) as a Windows 
service. They want to direct their backup to a network location. This works 
when they run the application interactively, but not when they run it as a 
service.

I've let them know that backing up locally is preferred for a number of 
reasons, but they still want to backup to the network location.  I've tried 
providing the same user credentials to the service that we use to run 
interactively without any luck.

Has anyone had success with this?

Thanks,
Joshua

Joshua Hunter
jos...@dwdev.com
(425) 673-1974
www.dwdev.com
Dataworks Development, Inc.
Providing secure and configurable data management solutions for research and 
clinical labs since 1987.


**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: v12+ parsing text [summary]

2016-11-17 Thread Chip Scheide
I am using a text array (only 1 element)
The array is created on import of the text from the disk file and is 
NOT resized (except to clear) after this. The element(s) of the array 
are filled via Receive Packet(Doc;Array_Element;1,500,000,000)

Original Issue - I tired to import a large (50meg) document -- time to 
import was excessive.
The 50 meg file I was trying to import failed to complete after running 
over night (~16 hours).

Resolutions:
- New text parsing code -- this code keeps track of how much of the 
text has been processed via longints, and does NOT manipulate the text 
(being parsed) directly, only getting substrings from it, and never 
changing it's size.
- New routine to replace/wrap substring
- Pass text to be parsed to various methods VIA POINTER*

My original code, truncated the source text to the next character after 
the text to Find (delimiter)
This, added SERIOUS time overhead.

The import process includes creating slightly more then 332,000 records
My new code imports the same 50 megs file (interpretedly) in about 7 
minutes.
My new code imports the same 50 meg file (compiled) in just over 1 
minute.

4D v12 (stand alone), OSX 10.6.8, Mac Mini 8gb RAM, 2.4ghz Core 2 duo, 
spinning metal hard drive


* using the new code, and passing the Source text (to be parsed) as a 
text parameter my new import routine took about an hour to complete.

Chip
On Thu, 17 Nov 2016 14:23:06 -0500, Charles Miller wrote:
> On Thu, Nov 17, 2016 at 11:43 AM, Arnaud de Montard  wrote:
> 
>> huge text in a text array makes it much easier to manipulate, but, at the
>> end, 4D memory is the same. In my example of 6,6Gb file, it was not a
>> solution.
> 
> 
> Also it might be creation of array. Remember that every time 4D resizes an
> array especially bigger, it looks for a block of memory that can hold it
> all. In effect copying array over and over
> 
> Think of it this way
> 
> Array text($Somtext;0)
> insert element($Somtext;size of array(Somtext)+1)
> $Somtext{size of array(Somtext)}:="bkjbkjbkb" `copy one
> 
> 
> insert element($Somtext;size of array(Somtext)+1)
> $Somtext{size of array(Somtext)}:="bkjbkjbkb" `copy two
> 
> etc each looking for larger chunks of continuos memory
> 
> Regards
> 
> Chuck
> 
> 
> -- 
> 
-
>  Chuck Miller Voice: (617) 739-0306 Fax: (617) 232-1064
>  Informed Solutions, Inc.
>  Brookline, MA 02446 USA Registered 4D Developer
>Providers of 4D, Sybase & SQL Sever connectivity
>   http://www.informed-solutions.com
> 
-
> This message and any attached documents contain information which may be
> confidential, subject to privilege or exempt from disclosure under
> applicable law.  These materials are intended only for the use of the
> intended recipient. If you are not the intended recipient of this
> transmission, you are hereby notified that any distribution, disclosure,
> printing, copying, storage, modification or the taking of any action in
> reliance upon this transmission is strictly prohibited.  Delivery of this
> message to any person other than the intended recipient shall not
> compromise or waive such confidentiality, privilege or exemption
> from disclosure as to this communication.
> **
> 4D Internet Users Group (4D iNUG)
> FAQ:  http://lists.4d.com/faqnug.html
> Archive:  http://lists.4d.com/archives.html
> Options: http://lists.4d.com/mailman/options/4d_tech
> Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
> **
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Server Backup when running as a Service

2016-11-17 Thread Bill Weale
Can you check (manually or by code) if the target volume is mounted when the 
backup is run? I had so many problems with this at one site that we gave up 
trying.

A more serious problem, imo, is not having a reliable place to maintain the log 
file…

Bill




> On Nov 17, 2016, at 2:41 PM, Cheryl Michels  wrote:
> 
> This seems simple so I must be missing something very basic.  We have a 
> merged/built server application.  Customer wants to run it as a Service and 
> backup the data to a drive other than the one that it is currently installed 
> on.  The backups are not getting written.  There is no error.  They simply 
> don't write.  If the backup is configured to write to the same drive that 
> Server is on, then the backup writes without error.
> 
> 

**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

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.com> writes:
>On Thu, Nov 17, 2016 at 11:43 AM, Arnaud de Montard  wrote:
>
>> huge text in a text array makes it much easier to manipulate, but, at the
>> end, 4D memory is the same. In my example of 6,6Gb file, it was not a
>> solution.
>
>
>Also it might be creation of array. Remember that every time 4D resizes an
>array especially bigger, it looks for a block of memory that can hold it
>all. In effect copying array over and over
>
>Think of it this way
>
>Array text($Somtext;0)
>insert element($Somtext;size of array(Somtext)+1)
>$Somtext{size of array(Somtext)}:="bkjbkjbkb" `copy one
>
>
>insert element($Somtext;size of array(Somtext)+1)
>$Somtext{size of array(Somtext)}:="bkjbkjbkb" `copy two
>
>etc each looking for larger chunks of continuos memory
>
>Regards
>
>Chuck
>
>

**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: v15.3 seems to be crashing on MACOS 10.12.1 & the new MBP

2016-11-17 Thread Spencer Hinsdale

if you're bored, try v16 beta or 15R5.  i think these avoid some problems by 
being carbon free.  i would be curious to know if they work with the bad build.

i have been running 15.3 with the good build and it's awesome.  just saying. :)

> On Nov 17, 2016, at 11:51 AM, Kirk Brooks  wrote:
> 
> I don't have a 15.2 dmg with me. If someone has the link to it I'll try
> again. Otherwise I'll try when I get home.
> 

**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Server Backup when running as a Service

2016-11-17 Thread Charles Miller
On Thu, Nov 17, 2016 at 2:41 PM, Cheryl Michels  wrote:

> This seems simple so I must be missing something very basic.  We have a
> merged/built server application.  Customer wants to run it as a Service and
> backup the data to a drive other than the one that it is currently
> installed on.  The backups are not getting written.  There is no error.
> They simply don't write.  If the backup is configured to write to the same
> drive that Server is on, then the backup writes without error.


What happens with manual backup? Permissions? what type of volume. Mounted
or local?

Regards
Chuck


-- 
-
 Chuck Miller Voice: (617) 739-0306 Fax: (617) 232-1064
 Informed Solutions, Inc.
 Brookline, MA 02446 USA Registered 4D Developer
   Providers of 4D, Sybase & SQL Sever connectivity
  http://www.informed-solutions.com
-
This message and any attached documents contain information which may be
confidential, subject to privilege or exempt from disclosure under
applicable law.  These materials are intended only for the use of the
intended recipient. If you are not the intended recipient of this
transmission, you are hereby notified that any distribution, disclosure,
printing, copying, storage, modification or the taking of any action in
reliance upon this transmission is strictly prohibited.  Delivery of this
message to any person other than the intended recipient shall not
compromise or waive such confidentiality, privilege or exemption
from disclosure as to this communication.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: v15.3 seems to be crashing on MACOS 10.12.1 & the new MBP

2016-11-17 Thread Kirk Brooks
I don't have a 15.2 dmg with me. If someone has the link to it I'll try
again. Otherwise I'll try when I get home.

On Thu, Nov 17, 2016 at 11:44 AM, Douglas von Roeder 
wrote:

> Kirk:
>
> I was just reading the release notes on 15.3 
> and I think you're wise to roll back to 15.2.
>
> For 15.3, they're distinguishing between two different builds of 10.12.1.
> They conclude "As a consequence, we have decided to postpone the macOS
> Sierra certification until the final version of 10.12.2 has been shipped by
> Apple."
>
>
>
>
> --
> Douglas von Roeder
> 949-336-2902
>
> On Thu, Nov 17, 2016 at 11:31 AM, Kirk Brooks 
> wrote:
>
> > Just unboxed a new MBP. And it's pretty fricking awesome! Just saying.
> >
> > After about 45 mins I had it setup to the point I was ready to download
> 4D
> > give it a spin. Just in time for the brand new 15.3 update to boot. Sadly
> > things are not going well. 4D 15.3 crashes on start up.
> >
> > I use Little Snitch to monitor IO. I noticed the 4D login screen appears
> as
> > expected while Little Snitch is blocking the network connection. As soon
> as
> > I authorize 4D it crashes. I turned off Little Snitch on the chance that
> > was somehow creating the problem. In this case 4D just crashes
> immediately.
> >
> > I'll try installing v15.2 later.
> >
> > Relevant part of the crash log follows:
> >
> > Process:   4D [619]
> > Path:  /Volumes/VOLUME/*/4D.app/Contents/MacOS/4D
> > Identifier:com.4d.4d
> > Version:   15.3 build 15.205412 (15.0.3)
> > Code Type: X86 (Native)
> > Parent Process:??? [1]
> > Responsible:   4D [619]
> > User ID:   501
> >
> > Date/Time: 2016-11-17 11:22:22.973 -0800
> > OS Version:Mac OS X 10.12.1 (16B2659)
> > Report Version:12
> > Anonymous UUID:67231E46-95B1-C702-37FC-EEF6DF76FDDF
> >
> >
> > Time Awake Since Boot: 100 seconds
> >
> > System Integrity Protection: disabled
> >
> > Crashed Thread:0   (id = 1027)  Dispatch queue:
> > com.apple.main-thread
> >
> > Exception Type:EXC_BREAKPOINT (SIGTRAP)
> > Exception Codes:   0x0002, 0x
> > Exception Note:EXC_CORPSE_NOTIFY
> >
> > Termination Signal:Trace/BPT trap: 5
> > Termination Reason:Namespace SIGNAL, Code 0x5
> > Terminating Process:   exc handler [0]
> >
> > Application Specific Information:
> > *** Terminating app due to uncaught exception
> 'NSInvalidArgumentException',
> > reason: '-[WK4D_CarbonWindowFrame contentFill]: unrecognized selector
> sent
> > to instance 0xa110140'
> >
> > Application Specific Backtrace 1:
> > 0   CoreFoundation  0x9476412b __raiseError + 187
> > 1   libobjc.A.dylib 0x9ee466e6 objc_exception_throw +
> > 273
> > 2   CoreFoundation  0x94767fcc -[NSObject(NSObject)
> > doesNotRecognizeSelector:] + 172
> > 3   CoreFoundation  0x9464b745 ___forwarding___ +
> 1013
> > 4   CoreFoundation  0x9464b32e _CF_forwarding_prep_0
> +
> > 14
> > 5   AppKit  0x927133fc -[NSWindow
> > backgroundColor] + 89
> > 6   ViewBridge  0x9d5eb920 -[NSRemoteView
> > _fontSmoothingColorForWindow:] + 376
> > 7   ViewBridge  0x9d6033dc -[NSRemoteView
> > _advanceToConfigPhase:] + 1086
> > 8   ViewBridge  0x9d603e28 -[NSRemoteView
> > advanceToConfigPhaseIfNeeded:] + 826
> > 9   ViewBridge  0x9d6044e1 -[NSRemoteView
> > advanceToRunPhaseIfNeeded:] + 219
> > 10  ViewBridge  0x9d6170aa
> +[NSRemoteViewController
> > requestViewController:withServiceSubclassIdentifier:
> > connectionHandler:withBlock:]
> > + 626
> > 11  ViewBridge  0x9d6174f6
> +[NSRemoteViewController
> > requestViewController:fromServiceListenerEndpoint:connectionHandler:] +
> 91
> > 12  HIToolbox   0x940527a0 -[IMKInputSession
> > presentFunctionRowItemTextInputViewWithEndpoint:completionHandler:] +
> 1755
> > 13  HIToolbox   0x94047d9f __80-[IMKInputSession
> > imkxpc_presentFunctionRowItemTextInputViewWithEndpoint:reply:]_
> > block_invoke
> > + 524
> > 14  CoreFoundation  0x9466f7d0
> > __CFRUNLOOP_IS_CALLING_OUT_TO_A_BLOCK__ + 16
> > 15  CoreFoundation  0x9464ffdc __CFRunLoopDoBlocks +
> > 348
> > 16  CoreFoundation  0x9464fd2f __CFRunLoopRun + 2751
> > 17  CoreFoundation  0x9464f00a CFRunLoopRunSpecific +
> > 506
> > 18  CoreFoundation  0x9464edfb CFRunLoopRunInMode +
> 123
> > 19  HIToolbox   0x940d
> > -[IMKInputSessionXPCInvocation invocationAwaitXPCReply] + 670
> > 20  HIToolbox   0x940248cc 

Re: v15.3 seems to be crashing on MACOS 10.12.1 & the new MBP

2016-11-17 Thread cswirth
Douglas,

Rolling back to 15.2 may not work either. We are having issues with Sierra
build 16B2657 and 4D v15.2. Build 16B2555 works fine.

Scott Wirth



--
View this message in context: 
http://4d.1045681.n5.nabble.com/v15-3-seems-to-be-crashing-on-MACOS-10-12-1-the-new-MBP-tp5748789p5748798.html
Sent from the 4D Tech mailing list archive at Nabble.com.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: v15.3 seems to be crashing on MACOS 10.12.1 & the new MBP

2016-11-17 Thread cswirth
Kirk,

Same problem here with a MacBook Air recently upgraded to Sierra. The issue
for us is that 4D crashes anytime a 4D Write area is touched. I am running
Sierra on an iMac with no issues and thought it may be related to the
laptop, however see the release notes for 15.3, what they state is
consistent with our experience. Running 4D on the older build of Sierra
10.12.1 is fine, not so on the more recent build.

Regards,
Scott Wirth


http://download.4d.com/Documents/Products_Documentation/LastVersions/Line_15/VIntl/4D_v15_3_ReleaseNotes_US.pdf?mkt_tok=eyJpIjoiTkdRd05tWm1PVFpsTTJWaiIsInQiOiJxSm93SWdQNWR6TzQ5SHIzRFlRT0hWQ2ljdjBhUXhsYUJhWkZMd0R4QVVpbDUxVStTZjA4bHlCcHlQOFNHU25MeGs1OHdSMmtNaUUrVWkxRFpCb2UzVXhLYUZEWHBoQVZuSXFoUTZvbkV3UT0ifQ%3D%3D



--
View this message in context: 
http://4d.1045681.n5.nabble.com/v15-3-seems-to-be-crashing-on-MACOS-10-12-1-the-new-MBP-tp5748789p5748796.html
Sent from the 4D Tech mailing list archive at Nabble.com.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: v15.3 seems to be crashing on MACOS 10.12.1 & the new MBP

2016-11-17 Thread Kirk Brooks
Spencer,

On Thu, Nov 17, 2016 at 11:43 AM, Spencer Hinsdale 
wrote:

> release notes indicate a known problem with macos build 16B257 but not
> with build 16B2555
>
> go to about this mac and click on the 10.12.1 and it will reveal build.
> inquiring minds wanna know, which do you have?
>
16B2659
​ - delivered yesterday
​

> if you are a developer, you can get beta 10.12.2 which per release notes
> fixes the 16b257 issue.
>
​I'm not.


-- 
Kirk Brooks
San Francisco, CA
===
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: v15.3 seems to be crashing on MACOS 10.12.1 & the new MBP

2016-11-17 Thread Douglas von Roeder
Kirk:

I was just reading the release notes on 15.3 
and I think you're wise to roll back to 15.2.

For 15.3, they're distinguishing between two different builds of 10.12.1.
They conclude "As a consequence, we have decided to postpone the macOS
Sierra certification until the final version of 10.12.2 has been shipped by
Apple."




--
Douglas von Roeder
949-336-2902

On Thu, Nov 17, 2016 at 11:31 AM, Kirk Brooks  wrote:

> Just unboxed a new MBP. And it's pretty fricking awesome! Just saying.
>
> After about 45 mins I had it setup to the point I was ready to download 4D
> give it a spin. Just in time for the brand new 15.3 update to boot. Sadly
> things are not going well. 4D 15.3 crashes on start up.
>
> I use Little Snitch to monitor IO. I noticed the 4D login screen appears as
> expected while Little Snitch is blocking the network connection. As soon as
> I authorize 4D it crashes. I turned off Little Snitch on the chance that
> was somehow creating the problem. In this case 4D just crashes immediately.
>
> I'll try installing v15.2 later.
>
> Relevant part of the crash log follows:
>
> Process:   4D [619]
> Path:  /Volumes/VOLUME/*/4D.app/Contents/MacOS/4D
> Identifier:com.4d.4d
> Version:   15.3 build 15.205412 (15.0.3)
> Code Type: X86 (Native)
> Parent Process:??? [1]
> Responsible:   4D [619]
> User ID:   501
>
> Date/Time: 2016-11-17 11:22:22.973 -0800
> OS Version:Mac OS X 10.12.1 (16B2659)
> Report Version:12
> Anonymous UUID:67231E46-95B1-C702-37FC-EEF6DF76FDDF
>
>
> Time Awake Since Boot: 100 seconds
>
> System Integrity Protection: disabled
>
> Crashed Thread:0   (id = 1027)  Dispatch queue:
> com.apple.main-thread
>
> Exception Type:EXC_BREAKPOINT (SIGTRAP)
> Exception Codes:   0x0002, 0x
> Exception Note:EXC_CORPSE_NOTIFY
>
> Termination Signal:Trace/BPT trap: 5
> Termination Reason:Namespace SIGNAL, Code 0x5
> Terminating Process:   exc handler [0]
>
> Application Specific Information:
> *** Terminating app due to uncaught exception 'NSInvalidArgumentException',
> reason: '-[WK4D_CarbonWindowFrame contentFill]: unrecognized selector sent
> to instance 0xa110140'
>
> Application Specific Backtrace 1:
> 0   CoreFoundation  0x9476412b __raiseError + 187
> 1   libobjc.A.dylib 0x9ee466e6 objc_exception_throw +
> 273
> 2   CoreFoundation  0x94767fcc -[NSObject(NSObject)
> doesNotRecognizeSelector:] + 172
> 3   CoreFoundation  0x9464b745 ___forwarding___ + 1013
> 4   CoreFoundation  0x9464b32e _CF_forwarding_prep_0 +
> 14
> 5   AppKit  0x927133fc -[NSWindow
> backgroundColor] + 89
> 6   ViewBridge  0x9d5eb920 -[NSRemoteView
> _fontSmoothingColorForWindow:] + 376
> 7   ViewBridge  0x9d6033dc -[NSRemoteView
> _advanceToConfigPhase:] + 1086
> 8   ViewBridge  0x9d603e28 -[NSRemoteView
> advanceToConfigPhaseIfNeeded:] + 826
> 9   ViewBridge  0x9d6044e1 -[NSRemoteView
> advanceToRunPhaseIfNeeded:] + 219
> 10  ViewBridge  0x9d6170aa +[NSRemoteViewController
> requestViewController:withServiceSubclassIdentifier:
> connectionHandler:withBlock:]
> + 626
> 11  ViewBridge  0x9d6174f6 +[NSRemoteViewController
> requestViewController:fromServiceListenerEndpoint:connectionHandler:] + 91
> 12  HIToolbox   0x940527a0 -[IMKInputSession
> presentFunctionRowItemTextInputViewWithEndpoint:completionHandler:] + 1755
> 13  HIToolbox   0x94047d9f __80-[IMKInputSession
> imkxpc_presentFunctionRowItemTextInputViewWithEndpoint:reply:]_
> block_invoke
> + 524
> 14  CoreFoundation  0x9466f7d0
> __CFRUNLOOP_IS_CALLING_OUT_TO_A_BLOCK__ + 16
> 15  CoreFoundation  0x9464ffdc __CFRunLoopDoBlocks +
> 348
> 16  CoreFoundation  0x9464fd2f __CFRunLoopRun + 2751
> 17  CoreFoundation  0x9464f00a CFRunLoopRunSpecific +
> 506
> 18  CoreFoundation  0x9464edfb CFRunLoopRunInMode + 123
> 19  HIToolbox   0x940d
> -[IMKInputSessionXPCInvocation invocationAwaitXPCReply] + 670
> 20  HIToolbox   0x940248cc -[IMKInputSession
> activate] + 3932
> 21  HIToolbox   0x94025520 -[IMKInputSession
> activateAfterServerConnection] + 341
> 22  libobjc.A.dylib 0x9ee40cdc -[NSObject
> performSelector:] + 51
> 23  HIToolbox   0x9401511e -[IMKClient
> fulfillServerDependentWork] + 676
> 24  HIToolbox   0x9401e26c
> __68-[IMKClient(IMKClientConnection_XPC)
> 

Server Backup when running as a Service

2016-11-17 Thread Cheryl Michels
This seems simple so I must be missing something very basic.  We have a 
merged/built server application.  Customer wants to run it as a Service and 
backup the data to a drive other than the one that it is currently installed 
on.  The backups are not getting written.  There is no error.  They simply 
don't write.  If the backup is configured to write to the same drive that 
Server is on, then the backup writes without error.


Cheryl Michels
President & System Architect
che...@dwdev.com
(425) 673-1974
www.dwdev.com
Dataworks Development, Inc.
Providing secure and configurable data management solutions for research and 
clinical labs since 1987.
[Description: FreezerworksLogo]

**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Scrollbars become disabled

2016-11-17 Thread truegold
Hi Chuck,

> If you are changing code to add redraw why not change window type and set max 
> and min sizes to be only a few pixels different

No code changing. Just adding a few refresh buttons at the moment to see if 
they make any difference.

As to changing window type we’ll see after I get some feedback from them.

Appreciate,
John...

>>> 
> Using 4D v15.2 Mac Server (mac and window clients)
> 
> We are having issues where the scrollbars in included forms and lisboxes
> become disabled even though there are plenty of rows beyond the screen
> display area. This has been happening on and off since 4D v12. So it’s not
> new.
> 
> Has anyone else seen this?
> 
> If so, what did you do to fix?
> 
> Of course, when debugging it it never happens.
> 
> Appreciate,
> 
>> 
> 

**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

v15.3 seems to be crashing on MACOS 10.12.1 & the new MBP

2016-11-17 Thread Kirk Brooks
Just unboxed a new MBP. And it's pretty fricking awesome! Just saying.

After about 45 mins I had it setup to the point I was ready to download 4D
give it a spin. Just in time for the brand new 15.3 update to boot. Sadly
things are not going well. 4D 15.3 crashes on start up.

I use Little Snitch to monitor IO. I noticed the 4D login screen appears as
expected while Little Snitch is blocking the network connection. As soon as
I authorize 4D it crashes. I turned off Little Snitch on the chance that
was somehow creating the problem. In this case 4D just crashes immediately.

I'll try installing v15.2 later.

Relevant part of the crash log follows:

Process:   4D [619]
Path:  /Volumes/VOLUME/*/4D.app/Contents/MacOS/4D
Identifier:com.4d.4d
Version:   15.3 build 15.205412 (15.0.3)
Code Type: X86 (Native)
Parent Process:??? [1]
Responsible:   4D [619]
User ID:   501

Date/Time: 2016-11-17 11:22:22.973 -0800
OS Version:Mac OS X 10.12.1 (16B2659)
Report Version:12
Anonymous UUID:67231E46-95B1-C702-37FC-EEF6DF76FDDF


Time Awake Since Boot: 100 seconds

System Integrity Protection: disabled

Crashed Thread:0   (id = 1027)  Dispatch queue:
com.apple.main-thread

Exception Type:EXC_BREAKPOINT (SIGTRAP)
Exception Codes:   0x0002, 0x
Exception Note:EXC_CORPSE_NOTIFY

Termination Signal:Trace/BPT trap: 5
Termination Reason:Namespace SIGNAL, Code 0x5
Terminating Process:   exc handler [0]

Application Specific Information:
*** Terminating app due to uncaught exception 'NSInvalidArgumentException',
reason: '-[WK4D_CarbonWindowFrame contentFill]: unrecognized selector sent
to instance 0xa110140'

Application Specific Backtrace 1:
0   CoreFoundation  0x9476412b __raiseError + 187
1   libobjc.A.dylib 0x9ee466e6 objc_exception_throw +
273
2   CoreFoundation  0x94767fcc -[NSObject(NSObject)
doesNotRecognizeSelector:] + 172
3   CoreFoundation  0x9464b745 ___forwarding___ + 1013
4   CoreFoundation  0x9464b32e _CF_forwarding_prep_0 +
14
5   AppKit  0x927133fc -[NSWindow
backgroundColor] + 89
6   ViewBridge  0x9d5eb920 -[NSRemoteView
_fontSmoothingColorForWindow:] + 376
7   ViewBridge  0x9d6033dc -[NSRemoteView
_advanceToConfigPhase:] + 1086
8   ViewBridge  0x9d603e28 -[NSRemoteView
advanceToConfigPhaseIfNeeded:] + 826
9   ViewBridge  0x9d6044e1 -[NSRemoteView
advanceToRunPhaseIfNeeded:] + 219
10  ViewBridge  0x9d6170aa +[NSRemoteViewController
requestViewController:withServiceSubclassIdentifier:connectionHandler:withBlock:]
+ 626
11  ViewBridge  0x9d6174f6 +[NSRemoteViewController
requestViewController:fromServiceListenerEndpoint:connectionHandler:] + 91
12  HIToolbox   0x940527a0 -[IMKInputSession
presentFunctionRowItemTextInputViewWithEndpoint:completionHandler:] + 1755
13  HIToolbox   0x94047d9f __80-[IMKInputSession
imkxpc_presentFunctionRowItemTextInputViewWithEndpoint:reply:]_block_invoke
+ 524
14  CoreFoundation  0x9466f7d0
__CFRUNLOOP_IS_CALLING_OUT_TO_A_BLOCK__ + 16
15  CoreFoundation  0x9464ffdc __CFRunLoopDoBlocks + 348
16  CoreFoundation  0x9464fd2f __CFRunLoopRun + 2751
17  CoreFoundation  0x9464f00a CFRunLoopRunSpecific +
506
18  CoreFoundation  0x9464edfb CFRunLoopRunInMode + 123
19  HIToolbox   0x940d
-[IMKInputSessionXPCInvocation invocationAwaitXPCReply] + 670
20  HIToolbox   0x940248cc -[IMKInputSession
activate] + 3932
21  HIToolbox   0x94025520 -[IMKInputSession
activateAfterServerConnection] + 341
22  libobjc.A.dylib 0x9ee40cdc -[NSObject
performSelector:] + 51
23  HIToolbox   0x9401511e -[IMKClient
fulfillServerDependentWork] + 676
24  HIToolbox   0x9401e26c
__68-[IMKClient(IMKClientConnection_XPC)
_receiveXPCConnectionEndpoint:]_block_invoke + 42
25  CoreFoundation  0x9466f7d0
__CFRUNLOOP_IS_CALLING_OUT_TO_A_BLOCK__ + 16
26  CoreFoundation  0x9464ffdc __CFRunLoopDoBlocks + 348
27  CoreFoundation  0x9464f6b2 __CFRunLoopRun + 1090
28  CoreFoundation  0x9464f00a CFRunLoopRunSpecific +
506
29  CoreFoundation  0x9464edfb CFRunLoopRunInMode + 123
30  HIToolbox   0x93d525a6
RunCurrentEventLoopInMode + 268
31  HIToolbox   0x93d52392 ReceiveNextEventCommon +
494
32  HIToolbox   0x93ed5e44 

Re: v12+ parsing text

2016-11-17 Thread Charles Miller
On Thu, Nov 17, 2016 at 11:43 AM, Arnaud de Montard  wrote:

> huge text in a text array makes it much easier to manipulate, but, at the
> end, 4D memory is the same. In my example of 6,6Gb file, it was not a
> solution.


Also it might be creation of array. Remember that every time 4D resizes an
array especially bigger, it looks for a block of memory that can hold it
all. In effect copying array over and over

Think of it this way

Array text($Somtext;0)
insert element($Somtext;size of array(Somtext)+1)
$Somtext{size of array(Somtext)}:="bkjbkjbkb" `copy one


insert element($Somtext;size of array(Somtext)+1)
$Somtext{size of array(Somtext)}:="bkjbkjbkb" `copy two

etc each looking for larger chunks of continuos memory

Regards

Chuck


-- 
-
 Chuck Miller Voice: (617) 739-0306 Fax: (617) 232-1064
 Informed Solutions, Inc.
 Brookline, MA 02446 USA Registered 4D Developer
   Providers of 4D, Sybase & SQL Sever connectivity
  http://www.informed-solutions.com
-
This message and any attached documents contain information which may be
confidential, subject to privilege or exempt from disclosure under
applicable law.  These materials are intended only for the use of the
intended recipient. If you are not the intended recipient of this
transmission, you are hereby notified that any distribution, disclosure,
printing, copying, storage, modification or the taking of any action in
reliance upon this transmission is strictly prohibited.  Delivery of this
message to any person other than the intended recipient shall not
compromise or waive such confidentiality, privilege or exemption
from disclosure as to this communication.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Store BLOB's Outside the Data File

2016-11-17 Thread Arnaud de Montard

> Le 15 nov. 2016 à 22:06, Kirk Brooks  a écrit :
> 
> Doug,
> This option is so appealing - storing large data chunks outside of the
> actual data file. I tried it briefly in v13 something as well.  I abandoned
> it for two reasons. First, there's no option to exclude these files from
> the backup. Second I wasn't confident about maintaining the links to the
> external files within 4D if something got moved externally.

third reason:
 [artwork]
 name
 author
 description
 photo (external storage)
LOAD RECORD([artwork])  //photo is loaded too   :-(

Another (bad?) reason is that it took me a while to understand the way 4D 
organizes the folders. 

I prefer doing it myself. 
 [artwork]
 name
 author
 description
 photo_ID
The path is made from photo_ID. 

If I plan to move documents one day "somewhere else" (cloud or something), 
things will be easier I suppose. 

-- 
Arnaud 


**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: v12+ parsing text

2016-11-17 Thread Arnaud de Montard

> Le 17 nov. 2016 à 16:07, Chip Scheide <4d_o...@pghrepository.org> a écrit :
> 
> 
> Thanks.
> 
> the problem Iam having is not from disk to memory
> I read the disk file into a text array, limiting each array element to 
> 1.5g (not that I have really had something that big, it is a hold over 
> from pre v11 where 32k characters was a text var/field limit).

I understand that you keep the whole document in an array, right?
If so, I know that splitting a huge text in a text array makes it much easier 
to manipulate, but, at the end, 4D memory is the same. In my example of 6,6Gb 
file, it was not a solution. 

That said, I read your 1st message too fast (as usual). Seems your document is 
not so huge (billion is not used in french, I always mistake)

For smaller documents, I used in v12 a wrapper for 'document to text':

***
 //FS_documentToText (path_t {;charSet_t {;lineEnd_l) -> txt
C_TEXT($0;$1)
$doc_t:=$1
$charSet_t:="utf-8"
If ($params_l>1)
$charSet_t:=$2
End if
DOCUMENT TO BLOB($doc_t;$data_x)
$0:=Convert to text($data_x;$charSet_t)
***

Another thing I read too fast is about using position/substring/truncating. 
Since v11 this can be avoided with the 2 Position parameters (that changed my 
life):
- start from
- * (at end)

The classical "delimited text to array" becomes quite simple:


And reading a csv file too:
***
$data_t:=FS_documentToText (path_t;"utf-8")
array text($line_at;0)
explode(->$line_at;$data_t;"\r")
array text(field_at;0)
For($i;1;size of array($line_at))
 explode(->field_at;$line_at{$i};",")
end for
***

-- 
Arnaud de Montard 



**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Scrollbars become disabled

2016-11-17 Thread Chuck Miller
If you are changing code to add redraw why not change window type and set max 
and min sizes to be only a few pixels different
Regards
Chuck

 Chuck Miller Voice: (617) 739-0306
 Informed Solutions, Inc. Fax: (617) 232-1064   
mailto:cjmillerinformed-solutions.com 
 Brookline, MA 02446 USA Registered 4D Developer
   Providers of 4D and Sybase connectivity
  http://www.informed-solutions.com  



> On Nov 17, 2016, at 11:16 AM, truegold  wrote:
> 
> Yea, that’s the only thing i can think of is providing various ways of 
> refreshing the list OR refreshing the window.
> 
> Thanks,
> John...

**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: 4GB Data Compresses to 80 MB

2016-11-17 Thread Norbert Pfaff
7.z ist da wunderbar

Ich dachte auch da hat was nicht geklappt. Die 370 Abfallkalender der Stadt 
Mannheim habe 100MB. 7.z mavht daraue 4,3MB.


Grüße/regards
Norbert


Norbert Pfaff
Hammelstalstr. 52
67098 Bad Dürkheim

Fon:06322 9108028
Skype:npfaff
eMail: npf...@mac.com





> Am 17.11.2016 um 14:35 schrieb Arnaud de Montard :
> 
> 
>> Le 17 nov. 2016 à 10:48, Sujit Shah  a écrit :
>> 
>> Maybe not but it sure makes one suspicious as to what is 4D using so much
>> space for.
> 
> It's the counterpart of what makes so easy changing a field type in 4D…
> Very schematically, field values are stored in a kind of fixed length 
> container, 128bytes, and fixed length is full of nothing. 
> 
> The picture under is a very simple data were I stored "01234567"*4 in a uuid 
> field, opened with an hex editor:
> 
> I suppose 1cer stands for "record", or "part 1 of record"
> orange = a block 128bytes (0x80 in hexa)
> yellow = emptiness. 
> (I was trying to understand how uuid are stored  :-/ )
> 
> I have a 4DD compressed from 10Gb to 600Mb with 7z. First time I saw that I 
> was sure the archive was corrupted. 
> 
> -- 
> Arnaud de Montard 
> 
> 
> 
> **
> 4D Internet Users Group (4D iNUG)
> FAQ:  http://lists.4d.com/faqnug.html
> Archive:  http://lists.4d.com/archives.html
> Options: http://lists.4d.com/mailman/options/4d_tech
> Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
> **

**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: encapsulate HTML

2016-11-17 Thread Peter Schumacher
Hi Ferdinando,

Nope, will not work.

Reason: You want to execute a html form. On a web page you need to specify a 
form processor with . An email client can't do this - and 
shouldn't do it for security reasons.

Greetings,

Peter


> Am 16.11.2016 um 15:32 schrieb stardata.info :
> 
> Davi,
> 
> The issue is know how to do for receive the answers included into the mail 
> that return back
> 
> Thanks
> 
> Ferdinando
> 
> 
> Il 16/11/2016 15:27, davidi...@gmail.com ha scritto:
>> 
>> Ferdinando,
>> 
>> I have not done this in an email, but you can try putting an iFrame in your 
>> html email that references a form delivered by your 4D system.
>> 
>> Hope that helps!
>> 
>> David Ringsmuth
>> 
>> Sent from Mail  for Windows 
>> 10
>> 
>> *From: *stardata.info 
>> *Sent: *Wednesday, November 16, 2016 8:24 AM
>> *To: *4d_tech@lists.4d.com 
>> *Subject: *encapsulate HTML
>> 
>> Hi All,
>> 
>> Someone know how is possible to encapsulate one questionary in HTML in email
>> 
>> body, and to receive the answer's and take the answers in 4D?
>> 
>> Thanks
>> 
>> Ferdinando
>> 
>> **
>> 
>> 4D Internet Users Group (4D iNUG)
>> 
>> FAQ:  http://lists.4d.com/faqnug.html
>> 
>> Archive:  http://lists.4d.com/archives.html
>> 
>> Options: http://lists.4d.com/mailman/options/4d_tech
>> 
>> Unsub: mailto:4d_tech-unsubscr...@lists.4d.com
>> 
>> **
>> 
> 
> **
> 4D Internet Users Group (4D iNUG)
> FAQ:  http://lists.4d.com/faqnug.html
> Archive:  http://lists.4d.com/archives.html
> Options: http://lists.4d.com/mailman/options/4d_tech
> Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
> **


**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Scrollbars become disabled

2016-11-17 Thread truegold
Hey Chip,

> redraw   ?

Yea, that’s the only thing i can think of is providing various ways of 
refreshing the list OR refreshing the window.

Thanks,
John...

> Hi Chuck,
> 
>> Can you minimize and bring back. It may also work by clicking into where 
>> scroll bar is
> 
> 
> Unfortunately not. This an old database that started development in late 
> 80’s. It still has those small window with no animated abilities.
> 
> So I will try seeing if reloading the records for the included layouts help.
> 
> Not sure yet on the HList.
> 
> Just weird,
> John...
> 
>> Hi Chuck,
>> 
>>> Try resizing the window manually
>> 
>> Well, that would be easy to try except that almost all there windows are a 
>> fixed size and not resizable.
>> 
>> Thanks,
>> John...
>> 
 Using 4D v15.2 Mac Server (mac and window clients)
 
 We are having issues where the scrollbars in included forms and lisboxes
 become disabled even though there are plenty of rows beyond the screen
 display area. This has been happening on and off since 4D v12. So it’s not
 new.
 
 Has anyone else seen this?
 
 If so, what did you do to fix?
 
 Of course, when debugging it it never happens.
 
 Appreciate,
 
> 

**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: v12+ parsing text

2016-11-17 Thread Chip Scheide
Im working on that  :)

On Thu, 17 Nov 2016 10:11:50 -0500, Chuck Miller wrote:
> OK but I think it si resizing text that is causing problems. Try 
> using stop and start positions and see if it improves
> 
> Chuck
> 

>  Chuck Miller Voice: (617) 739-0306
>  Informed Solutions, Inc. Fax: (617) 232-1064   
> mailto:cjmillerinformed-solutions.com 
>  Brookline, MA 02446 USA Registered 4D Developer
>Providers of 4D and Sybase connectivity
>   http://www.informed-solutions.com  
> 

> 
> 
>> On Nov 17, 2016, at 10:07 AM, Chip Scheide 
>> <4d_o...@pghrepository.org> wrote:
>> 
>> 
>> Thanks.
>> 
>> the problem Iam having is not from disk to memory
>> I read the disk file into a text array, limiting each array element to 
>> 1.5g (not that I have really had something that big, it is a hold over 
>> from pre v11 where 32k characters was a text var/field limit).
>> 
>> so my file reading scheme is:
>> open document
>> repeat
>> receive packet (doc_ref;array element;1,500,000)
>> 
>> if not EOF)
>> add element to array
>> end if
>> until EOF
>> 
>> Then process the text
> 
> **
> 4D Internet Users Group (4D iNUG)
> FAQ:  http://lists.4d.com/faqnug.html
> Archive:  http://lists.4d.com/archives.html
> Options: http://lists.4d.com/mailman/options/4d_tech
> Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
> **
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: v12+ parsing text

2016-11-17 Thread Chuck Miller
OK but I think it si resizing text that is causing problems. Try using stop and 
start positions and see if it improves

Chuck

 Chuck Miller Voice: (617) 739-0306
 Informed Solutions, Inc. Fax: (617) 232-1064   
mailto:cjmillerinformed-solutions.com 
 Brookline, MA 02446 USA Registered 4D Developer
   Providers of 4D and Sybase connectivity
  http://www.informed-solutions.com  



> On Nov 17, 2016, at 10:07 AM, Chip Scheide <4d_o...@pghrepository.org> wrote:
> 
> 
> Thanks.
> 
> the problem Iam having is not from disk to memory
> I read the disk file into a text array, limiting each array element to 
> 1.5g (not that I have really had something that big, it is a hold over 
> from pre v11 where 32k characters was a text var/field limit).
> 
> so my file reading scheme is:
> open document
> repeat
> receive packet (doc_ref;array element;1,500,000)
> 
> if not EOF)
> add element to array
> end if
> until EOF
> 
> Then process the text

**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: v12+ parsing text

2016-11-17 Thread Chip Scheide
Thanks
On Thu, 17 Nov 2016 07:16:54 +0800, Alan Chan wrote:
> I have written replacement of replace string with blog (not 
> neccessary in v15) You could modify it to fit your needs. Please note 
> that this is written for large text block and not for small text 
> block in a tight loop due to its overhead. 
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

RE: encapsulate HTML

2016-11-17 Thread davidinug
Ferdinando,

There will have to be some web server involved, unless you want to have them 
complete an email, and return it.

David Ringsmuth

From: stardata.info
Sent: Wednesday, November 16, 2016 3:12 PM
To: davidi...@gmail.com; 4d_tech@lists.4d.com
Subject: Re: encapsulate HTML

David,
I have received the email.
Tomorrow i do some tests.

I suppose that you use the web server part of 4D for do this, one possible 
problem is that in the my application is one server that are not opened on 
Internet.

Thanks
Ferdinando
Il 16/11/2016 21:09, davidi...@gmail.com ha scritto:
Ferdinando,
 
Please let me know when you have received the email with the link, and tested 
it.
 
Thanks!
 
David Ringsmuth
 
From: stardata.info
Sent: Wednesday, November 16, 2016 1:35 PM
To: davidi...@gmail.com; 4d_tech@lists.4d.com
Subject: Re: encapsulate HTML
 
Many thanks David
 
Il 16/11/2016 20:16, davidi...@gmail.com ha scritto:
Ferdinando,
 
I’m going to set you up an Account record in my customer’s system and send you 
the link.
 
I can also send you the Active4D web scripts that display and read the posted 
result.
 
Is that OK?
 
David
 
Sent from Mail for Windows 10
 
From: stardata.info
Sent: Wednesday, November 16, 2016 11:54 AM
To: davidi...@gmail.com; 4d_tech@lists.4d.com
Subject: Re: encapsulate HTML
 
David,
Thanks for suggestion.
You know a demo that i can see?
Thanks
Ferdinando
 
Il 16/11/2016 18:35, davidi...@gmail.com ha scritto:
Ferdinando,
 
To receive the answers you’ll need 4D to access the submitted form variables. 
4D will receive the posted form using a web server (4D native, Active4D, NTK). 
You’ll include a hidden input value in the form with a UUID as Lee Hinde said. 
This is your key to match to a record to store the form input values.
 
Your “submit” button will post the form to your 4D web server.
 
You’ll have to learn a little HTML, and you’ll learn how to read the results of 
the “post”ed form.
 
This kind of thing is very easy for 4D types that have been working with web 
for a while.
 
Another way:
I just wrote an email html formed in 4D Write, with a link and a UUID that when 
the user clicks on the email link, they go to a form published by 4D, which 
they complete and save. The UUID makes it possible to match the email recipient 
to record in the database. The embedded URL in the 4D Write document, converted 
to HTML, has “#” in it that I replace string to the UUID value.
 
David Ringsmuth
 
 
 
Sent from Mail for Windows 10
 
From: stardata.info
Sent: Wednesday, November 16, 2016 8:32 AM
To: davidi...@gmail.com; 4d_tech@lists.4d.com
Subject: Re: encapsulate HTML
 
Davi,
The issue is know how to do for receive the answers included into the mail that 
return back
Thanks
Ferdinando
 
Il 16/11/2016 15:27, davidi...@gmail.com ha scritto:
Ferdinando,
 
I have not done this in an email, but you can try putting an iFrame in your 
html email that references a form delivered by your 4D system.
 
Hope that helps!
 
David Ringsmuth
 
Sent from Mail for Windows 10
 
From: stardata.info
Sent: Wednesday, November 16, 2016 8:24 AM
To: 4d_tech@lists.4d.com
Subject: encapsulate HTML
 
 
Hi All,
 
Someone know how is possible to encapsulate one questionary in HTML in email
body, and to receive the answer's and take the answers in 4D?
 
Thanks
Ferdinando
 
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**
 
 
 
 
 
 
 


**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: 4GB Data Compresses to 80 MB

2016-11-17 Thread Ben Kershaw
Sujit Shah wrote:

>I have this 4GB Datafile which zips to 80MB. However when I run MSC it
>tells me the data file does not need to be compacted.

>I am wondering if there are potential issues with this data file?

>At the moment it is running fine.

If MSC says it’s fine, I’m sure it’s fine. There is a lot of whitespace in a 
data file, which compression gets rid of. A 2GB text field of all spaces would 
probably compress to a few bytes, but doesn’t have any space available from 
4D’s point of view.

Try compacting anyways and see what the size difference is - it may not be as 
much as you think.

Regards,
Ben Kershaw
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: v12+ parsing text

2016-11-17 Thread Arnaud de Montard

> Le 16 nov. 2016 à 20:12, Chip Scheide <4d_o...@pghrepository.org> a écrit :
> 
> 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 variable length.

Hi Chip, 
you can't use 'document to text' (since v13 only) and I doubt about using 
'document to blob' to "load at once" such a big document. For my own, I use 
load at once when the document is small enough in 4D 32bits versions (small 
means <500Mb). 

Schematically:


$trailing_t:=""
ARRAY TEXT($line_at;0)
$sizePacket_l:=10  //to be tuned
USE CHARACTER SET("UTF-8";0)  //example
$ref_h:=Open document("";"")
if(ok=1)
  repeat
RECEIVE PACKET($ref_h;$packet_t;$sizePacket_l)
$trailing_t:=$trailing_t+$packet_t
Explode(->$line_at;"\r")  //CR delimited text to array
$numberOfLines_l:=Size of array($line_at)
$trailing_t:=$line_at{$numberOfLines_l}  //keep last line aside
For($i_l;1;$numberOfLines_l-1)
  //do something with $line_at{$i_l}
End for
  until(ok=0)
//don't forget last piece here  ;-)
  CLOSE DOCUMENT($ref_h)
end if
USE CHARACTER SET(*;0)


I've used this to import a 6.6 Gbytes text document 2 years ago, really fast 
(of course SSD disk is better). What happens in the "For" is another story. 

Note 1
avoid using a stop char in the reading process, it is what makes it slow. 

Note 2 
if the document only contains "low ascii chars" (one byte=one char), you can:
- remove 'USE CHARACTER SET'
- read blob instead of text in 'RECEIVE PACKET'
- convert each packet with blob to text
Did not test, but I think it's faster. 

-- 
Arnaud de Montard 


**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: v12+ parsing text

2016-11-17 Thread Ortwin Zillgen
> ok - doing some testing and recoding.
> I do not quite understand

we had that discussion lately




Regards
O r t w i n  Z i l l g e n
-
   
 
member of developer-network 

**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: 4GB Data Compresses to 80 MB

2016-11-17 Thread Koen Van Hooreweghe
Hi Sujit,

Compacting is not the same as compressing (aka zipping).
4D datafiles have always had a big compression rate. But so do text files. Just 
tested a small file which is 100kB and was zipped to 3,5kB

Koen

Op 17-nov.-2016, om 10:05 heeft Sujit Shah  het volgende 
geschreven:

> I have this 4GB Datafile which zips to 80MB. However when I run MSC it
> tells me the data file does not need to be compacted.

**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: encapsulate HTML

2016-11-17 Thread stardata.info

Hi,

Using the link, i need to 4D WEB APPLICATION SERVER.

Thanks
Ferdinando

Il 17/11/2016 10:05, 4d_tech-requ...@lists.4d.com ha scritto:

Message: 6
Date: Thu, 17 Nov 2016 09:51:03 +1100
From: Sujit Shah
To: 4D iNug Technical<4d_tech@lists.4d.com>
Subject: Re: encapsulate HTML
Message-ID:

4GB Data Compresses to 80 MB

2016-11-17 Thread Sujit Shah
I have this 4GB Datafile which zips to 80MB. However when I run MSC it
tells me the data file does not need to be compacted.

I am wondering if there are potential issues with this data file?

At the moment it is running fine.



-- 

xxx
"There must be ingenuity as well as intention, strategy as well as
strength. "
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**