GetFileOpenName("Test", sPath, sFile, ".txt", "All Files (*.*),*.*", "c:\",
4)
<Philip Salgannik> wrote in message
news:41112132.3c0...@sybase.com...
Good luck,
Terry [TeamSybase] and Sequel the techno-kitten
Sequel's Sandbox: http://www.techno-kitten.com
Home of PBL Peeper, a free PowerBuilder Developer's Toolkit.
Version 2.2.06 now available at the Sandbox
See the PB Troubleshooting Guide at the Sandbox
^ ^
o o
=*=
What's the API call?
--
Paul Horan[TeamSybase]
type OPENFILENAME from structure
long lstructsize
long hwndowner
long hinstance
long lpstrfilter
long lpstrcustomfilter
long nMaxCustomFilter
long nFilterIndex
long lpstrFile
long nMaxFile
long lpstrFileTitle
long nMaxFileTitle
long lpstrInitialDir
long lpstrTitle
long Flags
integer nFileOffset
integer nFileExtension
long lpstrDefExt
long lCustData
long lpfnHook
long lpTemplateName
end type
The value you pass for aFlag is 2 ^ ( index - 1 )
^^^^^
Since the index for OFN_EXPLORER is 2, you need to pass 2, not 4, because you're
supposed to pass 2 ^ ( 2 - 1 ) = 2 ^ 1 = 2.
On 4 Aug 2004 11:13:21 -0700,
in sybase.public.powerbuilder.general
<Philip Salgannik> wrote in message
news:411151d8.412...@sybase.com...
> > If you can supply the PowerScript to populate the
> You should be seeing the one called ExplDial, but most
> likely seeing something like Pb9dial
>
"Bruce Armstrong [TeamSybase]" <NOCANSPAM_br...@teamsybase.com>
wrote in message news:41115c00$1@forums-1-dub...
pbm_thisusuallydoesnothelp:-))
Philip Salgannik
"Bruce Armstrong [TeamSybase]" <NOCANSPAM_br...@teamsybase.com>
wrote in message news:41115c00$1@forums-1-dub...
pbm_thisusuallydoesnothelp:-))
Philip Salgannik
"Ken Balakrishnan" <kNOe...@cps92.com> wrote in message
news:41115e0d$1@forums-1-dub...
On 4 Aug 2004 14:15:04 -0700, Philip Salgannik wrote:
>> If you can supply the PowerScript to populate the
On 4 Aug 2004 16:42:58 -0700, "Philip Salgannik"
<philema...@comcast.net> wrote:
Bruce Armstrong [TeamSybase]
http://www.teamsybase.com
Vote for PocketBuilder in the Mobile Village awards
http://www.mobilevillage.com/awards.htm
Vote for PocketBuilder in the Pocket PC Magazine awards
http://www.pocketpcmag.com/awards/category_2004.asp?catid=46
Two 3rd party books on developing with PowerBuilder
http://www.pb9books.com?source=newsgroups
Need code sample? Check out CodeXchange:
http://www.codexchange.sybase.com
Preach the gospel at all times. If necessary, use words. - Francis of Assisi
http://www.needhim.org
---------------------------------------------------------------------
DISCLAIMER:
This newsgroup message is only intended for the recipient. Given that it
is a posting to a public newsgroup, that means if you can read this
message then you are the recipient. This message may contain information
that is confidential and protected from disclosure. And then again,
it may not.
Given that TeamSybase members are not employees of Sybase, the contents
of this message do not necessarily represent the views or policies of
Sybase. Given that TeamSybase is a diverse group of users of Sybase
products, the contents of this message do not necessarily represent the
views of a significant number of the members of TeamSybase. Given that the
author has mutliple personalities and hears voices in his head, the contents
of this message do not necessarily represent his own views.
pbm_thisusuallydoesnothelp:-))
Philip Salgannik
"Bruce Armstrong [TeamSybase]" <NOCANSPAM_br...@teamsybase.com>
wrote in message news:gp03h0lo93kcnkcjf...@4ax.com...
Here's the explorer dialog I get, and the code I'm using to get it.
On 4 Aug 2004 21:28:07 -0700, "Philip Salgannik"
pbm_thisusuallydoesnothelp:-))
Philip Salgannik
"Bruce Armstrong [TeamSybase]" <NOCANSPAM_br...@teamsybase.com>
wrote in message news:2bf3h01jc6u5n4cif...@4ax.com...
pbm_thisusuallydoesnothelp:-))
Philip Salgannik
"Bruce Armstrong [TeamSybase]" <NOCANSPAM_br...@teamsybase.com>
wrote in message news:69f3h09m35mediocf...@4ax.com...
"Philip Salgannik" <philema...@comcast.net> wrote in message
news:41117517$1@forums-1-dub...
pbm_thisusuallydoesnothelp:-))
Philip Salgannik
"Ken Balakrishnan" <kNOe...@cps92.com> wrote in message
news:41123485$1@forums-2-dub...
Perhaps you're insisting that it have the places bar? If so, you
might try my PBNI implementation:
http://powerbuilder.codexchange.sybase.com/files/documents/67/802/pbnicommondialog.zip
On 5 Aug 2004 05:59:25 -0700, "Philip Salgannik"
<philema...@comcast.net> wrote:
Bruce Armstrong [TeamSybase]
Good luck,
Terry [TeamSybase] and Sequel the techno-kitten
On 4 Aug 2004 16:45:48 -0700, Terry Voth <seq...@techno-kitten.com>
wrote:
And I have no problem doing it thru API without the hook
callback...
Looks like the problem is that PBVM is either setting
OFN_ENABLE_HOOK (and NOT OFN_EX_NOPLACESBAR) OR was compiled
with header file from old SDK where the OPENFILENAME struct
definition is missing this piece:
typedef struct tagOFN {
DWORD lStructSize; // important!
•••
// as you've always known and loved it
#if (_WIN32_WINNT >= 0x0500)
void* pvReserved;
DWORD dwReserved;
DWORD FlagsEx;
#endif // (_WIN32_WINNT >= 0x0500)
} OPENFILENAME, *LPOPENFILENAME;
Windows 2000 keys on the size of the OPENFILENAME struct AND
whether the dialog uses a hook procedure (whether
OFN_ENABLE_HOOK flag is set) to determine which dialog to
use. If OPENFILENAME has the old size, Windows 2000 uses
OFN_ENABLEHOOK to determine which dialog to use. If the
OPENFILENAME uses a hook procedure (or OFN_ENABLETEMPLATE is
set), Windows 2000 displays the old-style dialog; otherwise,
it displays the new one ...
On 5 Aug 2004 15:28:00 -0700,
in sybase.public.powerbuilder.general
>> =*.
pbm_thisusuallydoesnothelp:-))
Philip Salgannik
"Bruce Armstrong [TeamSybase]" <NOCANSPAM_br...@teamsybase.com>
wrote in message news:4112b9be$1@forums-1-dub...
On 5 Aug 2004 16:57:35 -0700, "Philip Salgannik"
<philema...@comcast.net> wrote:
Bruce Armstrong [TeamSybase]
http://www.microsoft.com/msj/0198/c0198.aspx
By this article's standards, your example is in Explorer style, but it
also has the places bar, as this other article describes and
illustrates:
http://www.microsoft.com/msj/0899/logo/logo.aspx
PB doesn't claim to control the places bar, that I can find. So,
sounds like you'll have to go non-native. Sounds like there's a
solution available on CodeXchange.
Then again, if you think you've got a bug, the Support section of the
Sybase web site is the place to report it.
Good luck,
Terry [TeamSybase] and Sequel the techno-kitten
On 5 Aug 2004 18:57:03 -0700, "Philip Salgannik"
<philema...@comcast.net> wrote:
>Here is the picture of an Explorer style dialog:
>
>
>
>pbm_thisusuallydoesnothelp:-))
>Philip Salgannik
>
>"Bruce Armstrong [TeamSybase]" <NOCANSPAM_br...@teamsybase.com>
>wrote in message news:u9d4h0ln37aat03qd...@4ax.com...
Sequel's Sandbox: http://www.techno-kitten.com
Home of PBL Peeper, a free PowerBuilder Developer's Toolkit.
Version 2.2.06 now available at the Sandbox
See the PB Troubleshooting Guide at the Sandbox
^ ^
o o
=*=
"Terry Voth" <seq...@techno-kitten.com> wrote in message
news:gep5h0hfs7ccngr4a...@4ax.com...
> PB doesn't claim to control the places bar, that I can find.
That's exactly my point - that implies that it does not set
OFN_EX_NOPLACESBAR flag, that in turn means that if the PBVM9 was compiled
with the proper header file for common controls AND does not set the
OFN_ENABLE_HOOK we should be getting a true new Explorer style dialog - with
places bar.
pbm_thisusuallydoesnothelp:-))
Philip Salgannik
Of course, if you still think it's a bug...
Good luck,
Terry [TeamSybase] and Sequel the techno-kitten
On 5 Aug 2004 19:38:14 -0700, "Philip Salgannik"
<philema...@comcast.net> wrote:
Sequel's Sandbox: http://www.techno-kitten.com
#if (_WIN32_WINNT >= 0x0500)
void * pvReserved;
DWORD dwReserved;
DWORD FlagsEx;
#endif // (_WIN32_WINNT >= 0x0500)
The flag you're expecting them to support is only supported on W2K and
WinXP. What you are suggesting would have rendered PowerBuilder (or
at least that function) inoperable on anything other than W2K and
WinXP. PB9 officially supports NT, and is used without official
support on a number of older OSes.
On 5 Aug 2004 19:38:14 -0700, "Philip Salgannik"
<philema...@comcast.net> wrote:
Bruce Armstrong [TeamSybase]
pbm_thisusuallydoesnothelp:-))
Philip Salgannik
"Bruce Armstrong [TeamSybase]" <NOCANSPAM_br...@teamsybase.com>
wrote in message news:qav5h010sbcc7j4la...@4ax.com...
"Bruce Armstrong [TeamSybase]" <NOCANSPAM_br...@teamsybase.com>
wrote in message news:qav5h010sbcc7j4la...@4ax.com...
http://www.cplusplus.com/doc/tutorial/tut5-5.html
Which means that if it's done on Win2K or WinXP and the _WIN32_WINNT
is set to 500 or higher, the PowerBuilder VM will get compiled to use
the larger version of the structure. What will happen at runtime is
that PowerBuilder will pass that larger structure, and then older
operating systems that do not have that version of the common controls
will choke on the call.
The other option, the one it appears Sybase went with, is to not set
the flag so that the structure that is used is the one that is
supported on all of the OSes they support.
On 6 Aug 2004 05:44:36 -0700, "Philip Salgannik"
> The other option, the one it appears Sybase went with, is to not set
> the flag so that the structure that is used is the one that is
> supported on all of the OSes they support.
Which brings us full circle to my previous post - why are they using
OFN_ENABLE_HOOK ?
Using a direct API call I get the places bar passing in the OLD size of the
structure without any problems...
So if they did not use the OFN_ENABLE_HOOK you would get proper behavior in
all PB9 supported OSes...