Opening a document from Studio 8 in Windows

Scotte Meredith spomacguy at gmail.com
Mon Jun 20 13:14:30 EDT 2016


Thanks for that, Phil.

I had been looking in the PDF and completely missed the data types.

Turns out, I was calling it correctly, but I found a reference to Call DLL crashing in Studio 8.0. Replaced with Studio 8.01 and all now seems to work.

 
> On Jun 18, 2016, at 10:31 AM, Phil (OmnisList) <phil at pgpotter.co.uk> wrote:
> 
> Hi Scotte,
> 
> just F1 on the register dll command... and all should be revealed...
> 
> ie: Handle = 32 bit int, 16 gives current user desktop:
> 
> Register DLL ('shfolder.dll','SHGetFolderPathW','NJJJJC') Returns ErrCode
> Call DLL ('shfolder.dll','SHGetFolderPathW',Handle,16,'#NULL#',0,lvPath) Returns ErrCode
> 
> ie lcProgram = 'Excel' will run Excel...
> 
> Register DLL ('Shell32.dll','ShellExecuteW','JJCCCCJ') Returns lbStatus
> Call DLL ('Shell32.dll','ShellExecuteW',0,"#NULL#",lcProgram,lcParams,"#NULL#",1) Returns lbStatus
> 
> regards
> Phil Potter
> Based in Chester in the UK.
> 
> On 17/06/2016 19:08, Scotte Meredith wrote:
>> I’m new to using Register DLL & Call DLL.
>> 
>> Where do I find documentation on what all the parameters like the ‘JJCCCCJ’ come from and how I know which to use?
>> 
>> I’m using Studio 8 (64 bit) on Windows 8 and getting crashes when calling either shell32 or Kernel32 to open an external document or get a short pathname. It worked prior to Studio 8. I have put in a test for isunicode() and am using ShellExecuteW instead of ShellExecuteA as in 32 bit.
>> 
>> 
>> Scotte Meredith
>> SpoMacGuy at gmail.com
>> 
>> 
>> _____________________________________________________________
>> Manage your list subscriptions at http://lists.omnis-dev.com
> _____________________________________________________________
> Manage your list subscriptions at http://lists.omnis-dev.com


Scotte Meredith
SpoMacGuy at gmail.com





More information about the omnisdev-en mailing list