Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.clipper.visual-objects > #8209 > unrolled thread

Windows 10 OpenDialog resizing bug...

Started by<jean_ray67@hotmail.com>
First post2015-06-15 10:42 -0400
Last post2015-11-12 20:11 +0100
Articles 15 — 8 participants

Back to article view | Back to comp.lang.clipper.visual-objects


Contents

  Windows 10 OpenDialog resizing bug... <jean_ray67@hotmail.com> - 2015-06-15 10:42 -0400
    Re: Windows 10 OpenDialog resizing bug... "Wolfgang Riedmann" <wriedmann@gmail.com> - 2015-06-15 18:11 +0200
    Re: Windows 10 OpenDialog resizing bug... "Karl-Heinz" <invalid@invalid.invalid> - 2015-06-15 23:17 +0200
    Re: Windows 10 OpenDialog resizing bug... "Karl-Heinz" <invalid@invalid.invalid> - 2015-06-15 23:54 +0200
      Re: Windows 10 OpenDialog resizing bug... "Gerhard Bunzel" <g.bunzel@domonet.de> - 2015-06-16 16:09 +0200
        Re: Windows 10 OpenDialog resizing bug... "Karl-Heinz" <invalid@invalid.invalid> - 2015-06-16 18:33 +0200
          Re: Windows 10 OpenDialog resizing bug... "Jean Raymond" <jean_ray67@hotmail.com> - 2015-08-07 10:59 -0400
            Re: Windows 10 OpenDialog resizing bug... dmitryg2002@mail.ru - 2015-09-23 13:28 -0700
              Re: Windows 10 OpenDialog resizing bug... "Karl-Heinz" <invalid@invalid.invalid> - 2015-09-24 13:10 +0200
              Re: Windows 10 OpenDialog resizing bug... "Jean Raymond" <jean_ray67@hotmail.com> - 2015-09-24 09:23 -0400
    Re: Windows 10 OpenDialog resizing bug... dmitryg2002@mail.ru - 2015-09-24 08:17 -0700
    Re: Windows 10 OpenDialog resizing bug... "Jean Raymond" <jean_ray67@hotmail.com> - 2015-10-14 12:19 -0400
      Re: Windows 10 OpenDialog resizing bug... Karl Faller <mail_withoutthat_@_drei-f_andthat_.de> - 2015-10-14 21:10 +0200
      Re: Windows 10 OpenDialog resizing bug... D.J.W. van Kooten <vankooten@removethis.ic2.com> - 2015-10-30 21:05 +0100
      Re: Windows 10 OpenDialog resizing bug... "Karl-Heinz" <invalid@invalid.invalid> - 2015-11-12 20:11 +0100

#8209 — Windows 10 OpenDialog resizing bug...

From<jean_ray67@hotmail.com>
Date2015-06-15 10:42 -0400
SubjectWindows 10 OpenDialog resizing bug...
Message-ID<mlmo6c$7cp$1@dont-email.me>
Hello all...

I am using CAVO 28 SP3 (2837), and Window 10 Preview build 10130.

In the sample program Vopad, I changed the:
/----------------------------------
METHOD FileOpen() CLASS PadShellWindow
    LOCAL oOD AS OpenDialog

    oOD := OpenDialog{SELF, ".\*.RTF"}

    oOD:SetFilter({"*.RTF", "*.TXT"}, {"Rich Edit Text", "TXT"}, 1)
    oOD:SetStyle(  OFN_ENABLESIZING, TRUE )
    oOD:Show()
    IF !Empty(oOD:FileName)
        SELF:DoOpenFile(oOD:FileName, oOD:ReadOnly)
    ENDIF
/----------------------------------------
to be able to resize the open file dialog, I have added the following:
oOD:SetStyle(  OFN_ENABLESIZING, TRUE )

The problem is that we can only expand the window, and we cannot reduce it
after expansion.

The same problem with ClassMate 209.

The resizing is working well with all previous version of Windows ( XP to 
Win 8.1).

The sample .aef and .exe ( ready to test), can be downloaded at:
http://www.rayonline.com/temp/vopad-2.zip


Questions?
1) Is CAVO 28 SP4b ( I think ) has the same problem on windows 10 ?
2) Do you think it is a Windows 10 bug ?

Waiting for your replies...

Many tanks in advance.

Best regards

Jean Raymond
http://rayonline.com
support@rayonline.com


[toc] | [next] | [standalone]


#8210

From"Wolfgang Riedmann" <wriedmann@gmail.com>
Date2015-06-15 18:11 +0200
Message-ID<cu8bpdFjicfU1@mid.individual.net>
In reply to#8209
Hi Jean,

I'm pretty sure this is a Windows bug.

The OpenDialog class is only a wrapper about a Windows API function -
look at the SDK to see what it does. And if ClassMate has the same
problem, see this as confirmation.

Wolfgang


<jean_ray67@hotmail.com> wrote:

> Hello all...
> 
> I am using CAVO 28 SP3 (2837), and Window 10 Preview build 10130.
> 
> In the sample program Vopad, I changed the:
> /----------------------------------
> METHOD FileOpen() CLASS PadShellWindow
>    LOCAL oOD AS OpenDialog
> 
>    oOD := OpenDialog{SELF, ".\*.RTF"}
> 
>    oOD:SetFilter({"*.RTF", "*.TXT"}, {"Rich Edit Text", "TXT"}, 1)
>    oOD:SetStyle(  OFN_ENABLESIZING, TRUE )
>    oOD:Show()
>    IF !Empty(oOD:FileName)
>        SELF:DoOpenFile(oOD:FileName, oOD:ReadOnly)
>    ENDIF
> /----------------------------------------
> to be able to resize the open file dialog, I have added the following:
> oOD:SetStyle(  OFN_ENABLESIZING, TRUE )
> 
> The problem is that we can only expand the window, and we cannot
> reduce it after expansion.
> 
> The same problem with ClassMate 209.
> 
> The resizing is working well with all previous version of Windows (
> XP to Win 8.1).
> 
> The sample .aef and .exe ( ready to test), can be downloaded at:
> http://www.rayonline.com/temp/vopad-2.zip
> 
> 
> Questions?
> 1) Is CAVO 28 SP4b ( I think ) has the same problem on windows 10 ?
> 2) Do you think it is a Windows 10 bug ?
> 
> Waiting for your replies...
> 
> Many tanks in advance.
> 
> Best regards
> 
> Jean Raymond
> http://rayonline.com
> support@rayonline.com



-- 

[toc] | [prev] | [next] | [standalone]


#8212

From"Karl-Heinz" <invalid@invalid.invalid>
Date2015-06-15 23:17 +0200
Message-ID<cu8tpkFobviU1@mid.individual.net>
In reply to#8209
Hi Jean ,

i confirm the problem.

BTW:  The VO StdDlg Class doesn´t make use of the modern Dialogs introduced 
by Vista. Here is the  description why:

http://www.tmssoftware.com/site/atbdev6.asp

In short:  The buildin hook implementation prevents the new OpenDialog from 
being shown.

Here´s a quick hack that at least shows the new dialog. It´s the same that 
VO uses when you e.g. import a mef.

--------------------- 

FUNCTION ShowNewOpenDialog( oOwner )
    LOCAL lRet := TRUE AS LOGIC
    LOCAL sOFN AS _winOPENFILENAME
    LOCAL pszRes AS PSZ
    LOCAL hDLL, gpfnGetOpenFileName AS PTR


    sOFN := memalloc ( _SIZEOF ( _winOPENFILENAME ) )

    pszRes := MemAlloc(MAX_LEN)
    MemCopyString(pszRes, Space(255 ) , MAX_LEN)

    sOFN.lStructSize    := _SIZEOF ( _WINOPENFILENAME)
    sOFN.hwndOwner  := oOwner:Handle()
    sOFN.lpstrFile  := pszRes
    sOFN.nMaxFile   := MAX_LEN
    sOFN.lpstrFileTitle := NULL_PSZ
    sOFN.nMaxFileTitle := 0
    sOFN.lpstrInitialDir:= String2Psz( "C:\cavo28\bin" )

//    sOFN.lpfnHook       := @__StdFileHook()   <------- THIS line in the 
stdDLg.prg is  the problem !


     hDLL := LoadLibrary(String2Psz( "COMDLG32.DLL"))

     IF hDLL != NULL_PTR

         gpfnGetOpenFileName         := GetProcAddress(hDLL, String2Psz( 
"GetOpenFileNameA"))

         IF gpfnGetOpenFileName != NULL_PTR

            lRet := LOGIC ( _CAST ,  PCALL(gpfnGetOpenFileName, sOFN) )

         ENDIF

         FreeLibrary ( hDLL )

     ENDIF

     MemFree ( sOFN )

    RETURN lRet 

[toc] | [prev] | [next] | [standalone]


#8213

From"Karl-Heinz" <invalid@invalid.invalid>
Date2015-06-15 23:54 +0200
Message-ID<cu8vshFosjcU1@mid.individual.net>
In reply to#8209
Hi Jean ,

------------------------------------------------------------------------------
- second try,  because the first msg left the basket to fast ;-)
-------------------------------------------------------------------------------

i confirm the problem, but IMO the main problem is that the VO StdDlg
sources don´t make use of the modern dialogs introduced
by Vista. Here is a description why:

http://www.tmssoftware.com/site/atbdev6.asp

In short:  The VO - buildin hook implementation prevents such a new dialog
from being shown.

Here´s a quick hack that - at least  - shows such a new dialog.  It´s still
resizable in win 10 and it´s excatly the same that VO uses when you select
"File" -> "Open Project"  within the VO-IDE. IMO It´s time to rewrite the
StdDlg.prg  ;-)

regards
Karl-Heinz
--------------------- 
FUNCTION ShowNewOpenDialog( Owner )
    LOCAL lRet := TRUE AS LOGIC
    LOCAL sOFN AS _winOPENFILENAME
    LOCAL pszRes AS PSZ
    LOCAL hDLL, gpfnGetOpenFileName AS PTR


    sOFN := memalloc ( _SIZEOF ( _winOPENFILENAME ) )

    pszRes := MemAlloc(MAX_LEN)
    MemCopyString(pszRes, Space(255 ) , MAX_LEN)

    sOFN.lStructSize    := _SIZEOF ( _WINOPENFILENAME)
    sOFN.hwndOwner  := oOwner:Handle()
    sOFN.lpstrFile  := pszRes
    sOFN.nMaxFile   := MAX_LEN
    sOFN.lpstrFileTitle := NULL_PSZ
    sOFN.nMaxFileTitle := 0
    sOFN.lpstrInitialDir:= String2Psz( "C:\cavo28\bin" )

//    sOFN.lpfnHook       := @__StdFileHook()   <------- THIS line in the
stdDLg.prg is  the problem !


     hDLL := LoadLibrary(String2Psz( "COMDLG32.DLL"))

     IF hDLL != NULL_PTR

         gpfnGetOpenFileName         := GetProcAddress(hDLL, String2Psz(
"GetOpenFileNameA"))

         IF gpfnGetOpenFileName != NULL_PTR

            lRet := LOGIC ( _CAST ,  PCALL(gpfnGetOpenFileName, sOFN) )

         ENDIF

         FreeLibrary ( hDLL )

     ENDIF

     MemFree ( sOFN )

    RETURN lRet

--------  

[toc] | [prev] | [next] | [standalone]


#8214

From"Gerhard Bunzel" <g.bunzel@domonet.de>
Date2015-06-16 16:09 +0200
Message-ID<mlpant$qaa$1@news.m-online.net>
In reply to#8213
Karl-Heinz,

...thanks for that code.

You can do this also in one line:

// pszRes := MemAlloc(MAX_PATH) // MAX_LEN)
// MemCopyString(pszRes, Space(255), MAX_PATH)
pszRes := StringAlloc(Space(255))


...and don't forget to free that pszRes-memory:

MemFree ( sOFN )
MemFree ( pszRes )


To use that new dialog also for saving files:
gpfnGetOpenFileName := GetProcAddress(hDLL, String2Psz("GetSaveFileNameA"))



Best regard

Gerhard Bunzel


"Karl-Heinz"  schrieb im Newsbeitrag 
news:cu8vshFosjcU1@mid.individual.net...

Hi Jean ,

------------------------------------------------------------------------------
- second try,  because the first msg left the basket to fast ;-)
-------------------------------------------------------------------------------

i confirm the problem, but IMO the main problem is that the VO StdDlg
sources don´t make use of the modern dialogs introduced
by Vista. Here is a description why:

http://www.tmssoftware.com/site/atbdev6.asp

In short:  The VO - buildin hook implementation prevents such a new dialog
from being shown.

Here´s a quick hack that - at least  - shows such a new dialog.  It´s still
resizable in win 10 and it´s excatly the same that VO uses when you select
"File" -> "Open Project"  within the VO-IDE. IMO It´s time to rewrite the
StdDlg.prg  ;-)

regards
Karl-Heinz
--------------------- 
FUNCTION ShowNewOpenDialog( Owner )
    LOCAL lRet := TRUE AS LOGIC
    LOCAL sOFN AS _winOPENFILENAME
    LOCAL pszRes AS PSZ
    LOCAL hDLL, gpfnGetOpenFileName AS PTR


    sOFN := memalloc ( _SIZEOF ( _winOPENFILENAME ) )

    pszRes := MemAlloc(MAX_LEN)
    MemCopyString(pszRes, Space(255 ) , MAX_LEN)

    sOFN.lStructSize    := _SIZEOF ( _WINOPENFILENAME)
    sOFN.hwndOwner  := oOwner:Handle()
    sOFN.lpstrFile  := pszRes
    sOFN.nMaxFile   := MAX_LEN
    sOFN.lpstrFileTitle := NULL_PSZ
    sOFN.nMaxFileTitle := 0
    sOFN.lpstrInitialDir:= String2Psz( "C:\cavo28\bin" )

//    sOFN.lpfnHook       := @__StdFileHook()   <------- THIS line in the
stdDLg.prg is  the problem !


     hDLL := LoadLibrary(String2Psz( "COMDLG32.DLL"))

     IF hDLL != NULL_PTR

         gpfnGetOpenFileName         := GetProcAddress(hDLL, String2Psz(
"GetOpenFileNameA"))

         IF gpfnGetOpenFileName != NULL_PTR

            lRet := LOGIC ( _CAST ,  PCALL(gpfnGetOpenFileName, sOFN) )

         ENDIF

         FreeLibrary ( hDLL )

     ENDIF

     MemFree ( sOFN )

    RETURN lRet

--------  

[toc] | [prev] | [next] | [standalone]


#8216

From"Karl-Heinz" <invalid@invalid.invalid>
Date2015-06-16 18:33 +0200
Message-ID<cub1gbFa0sgU1@mid.individual.net>
In reply to#8214
Hi Gerhard,

yep, it´s just a quick and wild mixture of original SDK-sources and the
additional code needed to run the function. The only goal was to prove that
the dialog exists ;-) . Because SP4 is the last 2.8 fix/enhancement the
easiest way to access the "new" FileOpen and FileSave dialogs should be to
adapt the delphi code.

regards
Karl-Heinz

[toc] | [prev] | [next] | [standalone]


#8327

From"Jean Raymond" <jean_ray67@hotmail.com>
Date2015-08-07 10:59 -0400
Message-ID<mq2h0s$pmu$1@dont-email.me>
In reply to#8216
Hello Karl-Heinz

Windows 10 is here, and even with yesterday
[Cumulative Update for Windows 10 for x64-based Systems (KB3081424)],
the problems is still there.
I have made a work around that fits Windows 10 borders.
It is called [Demo-New-OpenFile-Dialog].
It is made with ClassMate 2.09, but with the AEF included, can be easily 
convert to pure CAVO code.
It can be found on my site at:
http://www.rayonline.com/cavosamples.html

Thank a lot you, Wolfgang and Gerhard for your inputs

By the way my new version of cmVodbx32 is using this work around and seems 
to work well from
XP (with old style) and from Vista to Win10 (with new style)

Best regards

Jean Raymond
http://www.rayonline.com/cmvodbx32.html

/---------------------------------------------------------------------------------

"Karl-Heinz"  wrote in message news:cub1gbFa0sgU1@mid.individual.net...

Hi Gerhard,

yep, it´s just a quick and wild mixture of original SDK-sources and the
additional code needed to run the function. The only goal was to prove that
the dialog exists ;-) . Because SP4 is the last 2.8 fix/enhancement the
easiest way to access the "new" FileOpen and FileSave dialogs should be to
adapt the delphi code.

regards
Karl-Heinz 

[toc] | [prev] | [next] | [standalone]


#8427

Fromdmitryg2002@mail.ru
Date2015-09-23 13:28 -0700
Message-ID<dfa7fd59-eda9-421b-a9f2-a954f54ea46d@googlegroups.com>
In reply to#8327
Hello Jean!
Could you shed some light on the work-around you've made?
I'm not familiar with CAVO, and deal with VC++ application, which has the same file dialog resizing problem on Win10.
Best regards,
Dmitry.

[toc] | [prev] | [next] | [standalone]


#8428

From"Karl-Heinz" <invalid@invalid.invalid>
Date2015-09-24 13:10 +0200
Message-ID<d6i453Ft4ahU1@mid.individual.net>
In reply to#8427
Hi Dmitry,

>> Could you shed some light on the work-around you've made?
>> I'm not familiar with CAVO, and deal with VC++ application, which has the
>> same file dialog resizing problem on Win10.

in short:

the resizing problem occurs each time a Hookproc is assigned to the
OPENFILENAME   member  lpfnHook. Inside the CAVO class library the HookProc
assignment is hardcoded ! So check what your VC++ class library offers to
control a HookProc assignment.


regards
Karl-Heinz 

[toc] | [prev] | [next] | [standalone]


#8429

From"Jean Raymond" <jean_ray67@hotmail.com>
Date2015-09-24 09:23 -0400
Message-ID<mu0tck$7q6$1@dont-email.me>
In reply to#8427
Dmitry

Go to my sample page:
http://www.rayonline.com/cavosamples.html

There is working demo, including source code, in ClassMate V209.
ClassMate is very similar to Win32 C code.
The DEMO is ---> [Demo-New-OpenFile-Dialog]

If you don't have CAVO, then you can use my [Fab AutoDoc Personal sample] in 
the same page.
It includes a BIN folder with the EXE to be able read the source codes 
(.AEF).

In short I call the OpenFileDialog with
SELF:gpfnGetOpenFileName         := GetProcAddress(SELF:hDLL, String2Psz( 
"GetOpenFileNameA"))
( see show method)

And if I want a template I create MODELESS dialog window without header, 
with a timer at 1 milisecond,
which follows the Windows OpenFileDialog in moving and resizing

I know it is not very elegant, but I'm using it my latest cmVodb32 DBF 
Manager
http://www.rayonline.com/cmvodbx32.html

Try my DBF manager at:
http://www.rayonline.com/download.html
As far I know it works pretty well...

Best regards
Jean Raymond

/------------------------------------------------------------------------------------------------------------------

wrote in message 
news:dfa7fd59-eda9-421b-a9f2-a954f54ea46d@googlegroups.com...

Hello Jean!
Could you shed some light on the work-around you've made?
I'm not familiar with CAVO, and deal with VC++ application, which has the 
same file dialog resizing problem on Win10.
Best regards,
Dmitry. 

[toc] | [prev] | [next] | [standalone]


#8430

Fromdmitryg2002@mail.ru
Date2015-09-24 08:17 -0700
Message-ID<e3e041cb-c598-4b49-8103-cb072a127424@googlegroups.com>
In reply to#8209
Thank you Karl-Heinz and Jean!

[toc] | [prev] | [next] | [standalone]


#8518

From"Jean Raymond" <jean_ray67@hotmail.com>
Date2015-10-14 12:19 -0400
Message-ID<mvlv6d$u4n$1@dont-email.me>
In reply to#8209
Hello all...
MS has finally fixed the problem on there build 10565 (Insider Preview)

Since it seems that MS won't publish a service pack 1, REF:
https://www.infopackets.com/news/9638/no-service-packs-windows-10-support-ends-2025

but only via Windows Updates

I don't know when this fix will be available for all...

Does anybody has a clue when this build 10565 will be available ????

Jean Raymond
http://www.rayonline.com


/---------------------------------------------------------------------
wrote in message news:mlmo6c$7cp$1@dont-email.me...

Hello all...

I am using CAVO 28 SP3 (2837), and Window 10 Preview build 10130.

In the sample program Vopad, I changed the:
/----------------------------------
METHOD FileOpen() CLASS PadShellWindow
    LOCAL oOD AS OpenDialog

    oOD := OpenDialog{SELF, ".\*.RTF"}

    oOD:SetFilter({"*.RTF", "*.TXT"}, {"Rich Edit Text", "TXT"}, 1)
    oOD:SetStyle(  OFN_ENABLESIZING, TRUE )
    oOD:Show()
    IF !Empty(oOD:FileName)
        SELF:DoOpenFile(oOD:FileName, oOD:ReadOnly)
    ENDIF
/----------------------------------------
to be able to resize the open file dialog, I have added the following:
oOD:SetStyle(  OFN_ENABLESIZING, TRUE )

The problem is that we can only expand the window, and we cannot reduce it
after expansion.

The same problem with ClassMate 209.

The resizing is working well with all previous version of Windows ( XP to
Win 8.1).

The sample .aef and .exe ( ready to test), can be downloaded at:
http://www.rayonline.com/temp/vopad-2.zip


Questions?
1) Is CAVO 28 SP4b ( I think ) has the same problem on windows 10 ?
2) Do you think it is a Windows 10 bug ?

Waiting for your replies...

Many tanks in advance.

Best regards

Jean Raymond
http://rayonline.com
support@rayonline.com

[toc] | [prev] | [next] | [standalone]


#8520

FromKarl Faller <mail_withoutthat_@_drei-f_andthat_.de>
Date2015-10-14 21:10 +0200
Message-ID<u3at1b1fkrhrvekrvl9a2a7726a1u5ao9a@4ax.com>
In reply to#8518
Jean,
>Does anybody has a clue when this build 10565 will be available ????
my (VM)-machine is just downloading...

Karl

[toc] | [prev] | [next] | [standalone]


#8591

FromD.J.W. van Kooten <vankooten@removethis.ic2.com>
Date2015-10-30 21:05 +0100
Message-ID<jlh73b5u4oovo745e15ak1a6dl7m97th5k@4ax.com>
In reply to#8518
On Wed, 14 Oct 2015 12:19:20 -0400, "Jean Raymond"
<jean_ray67@hotmail.com> wrote:

>I don't know when this fix will be available for all...
>
>Does anybody has a clue when this build 10565 will be available ????
>
Hello Jean,

Windowscentral.com writes:

"We're expecting all the new changes to be part of the Windows 10
Threshold 2 update, which should arrive sometime in November."

So anything between 2 and 32 from now I'd say. But it seems the date
will be early November next week).

A lot of changes I saw. At first glance, only one interesting change
in the category "better late than never": the Explorer bar has a
colour so you could actually find where it starts.

Dick

[toc] | [prev] | [next] | [standalone]


#8661

From"Karl-Heinz" <invalid@invalid.invalid>
Date2015-11-12 20:11 +0100
Message-ID<dak6o9Fs9l5U1@mid.individual.net>
In reply to#8518
Hi Jean,

>
>MS has finally fixed the problem on there build 10565 (Insider Preview)
>

today i received the offical "10.0.10586" update . Surprise, Surprise: the 
OpenDialog resizing works again. Anyway, it´s still an option to avoid the 
VO buildin Hook assignment as discussed earlier.

regards
Karl-Heinz

[toc] | [prev] | [standalone]


Back to top | Article view | comp.lang.clipper.visual-objects


csiph-web