Re: Write Pro view mode

2019-10-28 Thread Keisuke Miyako via 4D_Tech
this feature was introduced in 17 R5:

WP SET VIEW PROPERTIES( wpDoc | ( * ; "zoneWrite") ; prefWritePro)
WP Get view properties( wpDoc | ( * ; "zoneWrite")) -> prefWritePro

see also:

http://forums.4d.fr/Post/FR/18150033/1/18150034
http://forums.4d.fr/Post/FR/18134916/1/18134917
http://forums.4d.fr/NewPost/FR/16557278/18222051
http://forums.4d.com/Post/FR/21803748/1/21803749

> 2019/10/29 11:12、Mitchell Shiller via 4D_Tech <4d_tech@lists.4d.com>のメール:
> Is there a way to procedurally change the view mode of a 4D Write Pro area. 
> I’m using 4D 17R6.




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

Write Pro view mode

2019-10-28 Thread Mitchell Shiller via 4D_Tech
Hi,

Is there a way to procedurally change the view mode of a 4D Write Pro area. I’m 
using 4D 17R6.
I have a widget on a page which is displayed in Page mode.
I want to be able to procedurally hide or show the toolbars. 

Thanks

Mitch

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

Re: MySQL connection from 4D

2019-10-28 Thread Jeffrey Kain via 4D_Tech
Are you sure it's version 3? According to Wikipedia that version dates back to 
the 1990s... :)

Jeff



> On Oct 28, 2019, at 11:40 AM, Nigel Greenlee via 4D_Tech 
> <4d_tech@lists.4d.com> wrote:
> 
> Hi
> 
> Does anyone know if 4D is able to connect to a MySQL server running version 
> 3x? 

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

Re: SV: OPEN DATA FILE gets endless loop

2019-10-28 Thread Chip Scheide via 4D_Tech
Carl,
Are you aware that once you point a 4D Database to a datafile - it 
remembers that data file?
So...
Open database
 -> where is my data file
Point database to data file
-> OK I'm happy!
startup completes.

You never have to do this again, unless you want to change data files.

Chip

On Mon, 28 Oct 2019 21:29:17 +0100, wangel--- via 4D_Tech wrote:
> Thanks for your response Jeremy. You have made it clear to me that 
> OPEN DATA FILE first closes the database and then reopen it with the 
> wanted datafile and then repeat that unless something stops it. I 
> tried with $dataPath:="" which obviously was not a particularly 
> brilliant idea. 
> I think I shall incorporate a Default.4DD file and try it from there.
> Regards
> Carl
> 
>> 
>> From: Jeremy Roussak 
>> To: 4D iNug Technical <4d_tech@lists.4d.com>
>> Cc: wan...@online.no
>> Subject: Re: OPEN DATA FILE gets endless loop
>> Message-ID: <8ef1b76a-1b3a-42d5-9bfb-aad0bd0fc...@mac.com>
>> Content-Type: text/plain;charset=utf-8
> 
>> Carl,
> 
>> I hesitate to suggest something quite so obvious, but it seems to me 
>> that each time you enter the On Startup method, you
> 
>> 1. Set $dataPath to a path
>> 2. Test $dataPath is “”, which of course it isn’t 3. Open a data 
>> file 4. Set $dataPath to “” (effectively pointless) 5. Re-enter On 
>> startup when the new data file opens 6. Go to step 1; hence your loop
> 
>> From the OPEN DATA FILE documentation:
> 
>> If the access path sets a valid data file, 4D quits the database in 
>> progress and re-opens it with the specified data file. In 
>> single-user mode, the Semaphore 
>>  >and the On 
>> Startup database method 
>>  
>> are successively called.
>> Warning: Since this command causes the application to quit before 
>> re-opening with the specified data file, it must be used with 
>> precaution in the On Startup database method 
>> <>file:///4Dv17/4D/17/On-Startup->database-method.301-3730029.en.html> 
>> or in a method called by this database method, so as to avoid 
>> generating an infinite loop. 
> 
>> Jeremy
> **
> 
> **
> 4D Internet Users Group (4D iNUG)
> Archive:  http://lists.4d.com/archives.html
> Options: https://lists.4d.com/mailman/options/4d_tech
> Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
> **
We have done so much, with so little, for so long;
We are now qualified to anything with nothing 
  - unknown
**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

SV: OPEN DATA FILE gets endless loop

2019-10-28 Thread wangel--- via 4D_Tech
Thanks for your response Jeremy. You have made it clear to me that OPEN DATA 
FILE first closes the database and then reopen it with the wanted datafile and 
then repeat that unless something stops it. I tried with $dataPath:="" which 
obviously was not a particularly brilliant idea. 
I think I shall incorporate a Default.4DD file and try it from there.
Regards
Carl

>
>From: Jeremy Roussak 
>To: 4D iNug Technical <4d_tech@lists.4d.com>
>Cc: wan...@online.no
>Subject: Re: OPEN DATA FILE gets endless loop
>Message-ID: <8ef1b76a-1b3a-42d5-9bfb-aad0bd0fc...@mac.com>
>Content-Type: text/plain;  charset=utf-8

>Carl,

>I hesitate to suggest something quite so obvious, but it seems to me that each 
>time you enter the On Startup method, you

>1. Set $dataPath to a path
>2. Test $dataPath is “”, which of course it isn’t 3. Open a data file 4. Set 
>$dataPath to “” (effectively pointless) 5. Re-enter On startup when the new 
>data file opens 6. Go to step 1; hence your loop

>From the OPEN DATA FILE documentation:

>If the access path sets a valid data file, 4D quits the database in progress 
>and re-opens it with the specified data file. In single-user mode, the 
>Semaphore  >and the On 
>Startup database method 
> are 
>successively called.
>Warning: Since this command causes the application to quit before re-opening 
>with the specified data file, it must be used with precaution in the On 
>Startup database method 
><>file:///4Dv17/4D/17/On-Startup->database-method.301-3730029.en.html> or in a 
>method called by this database method, so as to avoid generating an infinite 
>loop. 

>Jeremy
**

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

Re: MySQL connection from 4D

2019-10-28 Thread Tom Benedict via 4D_Tech
The fact that it doesn’t require that you set up an ODBC Source on each machine 
you want to use it on is easily worth the price. Just pass it a connection 
string and you’re on your way.

Tom Benedict

> On Oct 28, 2019, at 12:49, Jim Labos - infobase via 4D_Tech 
> <4d_tech@lists.4d.com> wrote:
> 
> My suggestion is to try the demo of Pluggers myConnect plugin to try and
> connect. It will at least help you find the correct syntax or protocol to
> connect.
> 
> We have been using it for years with no problem. It's one of those plugins
> that is worth every penny.
> 
> For the price it may be worth buying and stop puling your hairs out. Also
> Rob is very helpful when needed. Whenever we had a problem it was always our
> syntax etc.
> 
> Worth giving it a try if only to verify if something else isn't the problem.
> 
> Jim
> 
**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: MySQL connection from 4D

2019-10-28 Thread Jim Labos - infobase via 4D_Tech
My suggestion is to try the demo of Pluggers myConnect plugin to try and
connect. It will at least help you find the correct syntax or protocol to
connect.

We have been using it for years with no problem. It's one of those plugins
that is worth every penny.

For the price it may be worth buying and stop puling your hairs out. Also
Rob is very helpful when needed. Whenever we had a problem it was always our
syntax etc.

Worth giving it a try if only to verify if something else isn't the problem.

Jim



-
Jim Labos - infobase
--
Sent from: http://4d.1045681.n5.nabble.com/4D-Tech-f1376241.html
**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Cache flushing did not complete... best practice

2019-10-28 Thread Jeffrey Kain via 4D_Tech
Or use a mirror. Highly recommended if the database is important...

> On Oct 28, 2019, at 12:59 PM, JPR via 4D_Tech <4d_tech@lists.4d.com> wrote:
> 
> The only 100% accurate way is to restart from the Backup file (made by 4D) 
> and  integrate the current log file(s). This is the only way to be sure of 
> the data integrity.

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

RE: Cache flushing did not complete... best practice

2019-10-28 Thread JPR via 4D_Tech
[JPR]
Hi Justin,

Tim's explanation is the good one. When 4D starts flushing the cache, it writes 
a flag into the .4DD file, and clears it when the flush is complete. 

Here are some answers:

> Are you sure the marker is stored in the data file?
Yes, I do.

> If I restore a backup from Time Machine that I know was good and verify the 
> records in the MSC, the verify fails saying the last database flush did not 
> complete.
When you do a backup with any other program than 4D, including Time Machine, 
you backup what is on disk, but not the cache itself. This is why only 4D 
Backup can be trusted.

> I would think that the marker is stored someplace else. 
No, it's not.

> If I run a repair on the datafile 4D crashes. I have tried to run the repair 
> several times and it crashes at the same spot every time.
Then you probably have a damaged sector on your disk, or at least a damaged 4D 
block that 4D cannot read and process.

> I ran a repair on the structure and it failed reporting that the flush did 
> not complete.
Yes, because the flag is not in the structure file.

> Finally I ran a repair on the datafile using record headers and it looks like 
> I am back in. Just waiting on reindexing to finish.
This is one of the 2 safe solutions. Almost. But not 100% reliable. You may 
have lost some record(s) and the data integrity is not guaranteed. For 
instance, you may lose Client record, but still have Invoices for this Client. 
This is the last solution when everything else has failed.

The only 100% accurate way is to restart from the Backup file (made by 4D) and  
integrate the current log file(s). This is the only way to be sure of the data 
integrity.

My very best,

JPR

PS: Data Analyzer can show you where is the Cache Flushing Flag, but doesn't 
allow you to clear it, for it is the worst thing to do...


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

Re: MySQL connection from 4D

2019-10-28 Thread Tom Benedict via 4D_Tech
One other bit of info is that the mySQL database I’m connecting to is version 
8.0.17. Sorry I don’t have any experience with version 3.x.

Tom Benedict

> On Oct 28, 2019, at 09:11, Tom Benedict via 4D_Tech <4d_tech@lists.4d.com> 
> wrote:
> 
> The only thing I can add is to make sure your ODBC Driver, ODBC Data Source 
> Administrator and 4D all match with respect to 32bit or 64 bit. 
> 
> I am connecting to a mySQL DB using 4D Native (SQL LOGIN) via mySQL ODBC 8.0 
> Unicode Driver and 4D v17R4. All 64 bit.
> 
> HTH,
> 
> Tom Benedict
> 
>> On Oct 28, 2019, at 09:00, Nigel Greenlee via 4D_Tech <4d_tech@lists.4d.com> 
>> wrote:
>> 
>> Jeff
>> 
>> Indeed i did look at that(-its overkill for what i need) but it does say on 
>> there it works for Mysql V4 and up-hence why i am wondering of 4D in itself 
>> won’t connect to and older version.
>> 
>> Thanks
>> 
>> Nigel
>> 
>>> On 28 Oct 2019, at 15:54, Jeffrey Kain via 4D_Tech <4d_tech@lists.4d.com> 
>>> wrote:
>>> 
>>> If you don't get anywhere with SQL LOGIN (which should work, given the 
>>> right driver settings), Pluggers Software sells the MyConnect plug-in which 
>>> works perfectly and is very fast/reliable.
>>> 
>>> https://www.pluggers.nl/product/myconnect-plugin/
>>> 
>>> We've been using it for many years performing crucial functions interfacing 
>>> 4D with our web stack that run 24x7x365.
>>> 
 On Oct 28, 2019, at 11:40 AM, Nigel Greenlee via 4D_Tech 
 <4d_tech@lists.4d.com> wrote:
 
 Should I be doing something else other that SQL 
 LOGIN(ODBC:xx.xx.xx.xx;username;password) for a MySQL server?
>>> 
>>> **
>>> 4D Internet Users Group (4D iNUG)
>>> Archive:  http://lists.4d.com/archives.html
>>> Options: https://lists.4d.com/mailman/options/4d_tech
>>> Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
>>> **
>> 
>> **
>> 4D Internet Users Group (4D iNUG)
>> Archive:  http://lists.4d.com/archives.html
>> Options: https://lists.4d.com/mailman/options/4d_tech
>> Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
>> **
> 
> **
> 4D Internet Users Group (4D iNUG)
> Archive:  http://lists.4d.com/archives.html
> Options: https://lists.4d.com/mailman/options/4d_tech
> Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
> **

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

Re: MySQL connection from 4D

2019-10-28 Thread Tom Benedict via 4D_Tech
The only thing I can add is to make sure your ODBC Driver, ODBC Data Source 
Administrator and 4D all match with respect to 32bit or 64 bit. 

I am connecting to a mySQL DB using 4D Native (SQL LOGIN) via mySQL ODBC 8.0 
Unicode Driver and 4D v17R4. All 64 bit.

HTH,

Tom Benedict

> On Oct 28, 2019, at 09:00, Nigel Greenlee via 4D_Tech <4d_tech@lists.4d.com> 
> wrote:
> 
> Jeff
> 
> Indeed i did look at that(-its overkill for what i need) but it does say on 
> there it works for Mysql V4 and up-hence why i am wondering of 4D in itself 
> won’t connect to and older version.
> 
> Thanks
> 
> Nigel
> 
>> On 28 Oct 2019, at 15:54, Jeffrey Kain via 4D_Tech <4d_tech@lists.4d.com> 
>> wrote:
>> 
>> If you don't get anywhere with SQL LOGIN (which should work, given the right 
>> driver settings), Pluggers Software sells the MyConnect plug-in which works 
>> perfectly and is very fast/reliable.
>> 
>> https://www.pluggers.nl/product/myconnect-plugin/
>> 
>> We've been using it for many years performing crucial functions interfacing 
>> 4D with our web stack that run 24x7x365.
>> 
>>> On Oct 28, 2019, at 11:40 AM, Nigel Greenlee via 4D_Tech 
>>> <4d_tech@lists.4d.com> wrote:
>>> 
>>> Should I be doing something else other that SQL 
>>> LOGIN(ODBC:xx.xx.xx.xx;username;password) for a MySQL server?
>> 
>> **
>> 4D Internet Users Group (4D iNUG)
>> Archive:  http://lists.4d.com/archives.html
>> Options: https://lists.4d.com/mailman/options/4d_tech
>> Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
>> **
> 
> **
> 4D Internet Users Group (4D iNUG)
> Archive:  http://lists.4d.com/archives.html
> Options: https://lists.4d.com/mailman/options/4d_tech
> Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
> **

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

Re: MySQL connection from 4D

2019-10-28 Thread Nigel Greenlee via 4D_Tech
Jeff

Indeed i did look at that(-its overkill for what i need) but it does say on 
there it works for Mysql V4 and up-hence why i am wondering of 4D in itself 
won’t connect to and older version.

Thanks

Nigel

> On 28 Oct 2019, at 15:54, Jeffrey Kain via 4D_Tech <4d_tech@lists.4d.com> 
> wrote:
> 
> If you don't get anywhere with SQL LOGIN (which should work, given the right 
> driver settings), Pluggers Software sells the MyConnect plug-in which works 
> perfectly and is very fast/reliable.
> 
> https://www.pluggers.nl/product/myconnect-plugin/
> 
> We've been using it for many years performing crucial functions interfacing 
> 4D with our web stack that run 24x7x365.
> 
>> On Oct 28, 2019, at 11:40 AM, Nigel Greenlee via 4D_Tech 
>> <4d_tech@lists.4d.com> wrote:
>> 
>> Should I be doing something else other that SQL 
>> LOGIN(ODBC:xx.xx.xx.xx;username;password) for a MySQL server?
> 
> **
> 4D Internet Users Group (4D iNUG)
> Archive:  http://lists.4d.com/archives.html
> Options: https://lists.4d.com/mailman/options/4d_tech
> Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
> **

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

Re: MySQL connection from 4D

2019-10-28 Thread Jeffrey Kain via 4D_Tech
If you don't get anywhere with SQL LOGIN (which should work, given the right 
driver settings), Pluggers Software sells the MyConnect plug-in which works 
perfectly and is very fast/reliable.

https://www.pluggers.nl/product/myconnect-plugin/

We've been using it for many years performing crucial functions interfacing 4D 
with our web stack that run 24x7x365.

> On Oct 28, 2019, at 11:40 AM, Nigel Greenlee via 4D_Tech 
> <4d_tech@lists.4d.com> wrote:
> 
> Should I be doing something else other that SQL 
> LOGIN(ODBC:xx.xx.xx.xx;username;password) for a MySQL server?

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

MySQL connection from 4D

2019-10-28 Thread Nigel Greenlee via 4D_Tech
Hi


I am pretty sure other people are connecting to MySQL from 4D so i am hoping 
someone can advise me on where my problems may lie.

Pre-amble:—

I want to connect to the database of an Asterisk Telephone server. We have 
established that the database is accessible on the network and using 
‘sequel-pro’ i can connect from my Mac(Seqel-pro bypasses ODBC manager so its 
not that helpful in diagnosing my problem).

I have also been able to setup and test an ODBC connection using the ODBC 
manager on WIndows, as i was not having much luck getting a connection from 4D 
to the MySQL database on my mac i switched my efforts to there.


After some flapping around I established that the my-sql connector we had did 
not match the my-sql server which is running 3.5x. Later drivers on the pc 
would not connect but the 3.5 driver does connect to the MySQL database From 
Windows(as you know the odbc administrator on PC

The problem in a nutshel:—


However when i try to get my 4D app to to perform a login i get a stack 
overflow problem from 4D V17.(recursive errors eventually returning control to 
me!).

Does anyone know if 4D is able to connect to a MySQL server running version 3x? 

Should I be doing something else other that SQL 
LOGIN(ODBC:xx.xx.xx.xx;username;password) for a MySQL server?

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