delphi 调用系统图片查看器


本文整理自网络,侵删。

 
uses Windows, ShlObj, ShellAPI;

function GetSpecialPath(CSIDL: word): string;
  var
  s: string;
begin
  SetLength(s, MAX_PATH);
  if not SHGetSpecialFolderPath(0, PChar(s), CSIDL, true) then s:='';
  Result:=PChar(s);
end;

begin
ShellExecute(0,'open','cmd.exe',Pchar('/c rundll32 "'+GetSpecialPath($26)+'\Windows Photo Viewer\PhotoViewer.dll",ImageView_Fullscreen G:\xxxx\ '+ParamStr(1)),nil,SW_HIDE);

//ShellExecute(0,'open','cmd.exe',Pchar('/c rundll32 "'+GetSpecialPath($26)+'\Windows Photo Viewer\PhotoViewer.dll",ImageView_Fullscreen '+ParamStr(1)),nil,SW_HIDE);
end.

相关阅读 >>

Delphi readprocessmemory 输入进程id 输入读取地址

Delphi form的borderstyle属性

Delphi 62 进制的简单实现

Delphi中使用词霸2005的动态库xdictgrb.dll实现屏幕取词

Delphi 使用webbrowser控件获取含框架的网页的完整html代码

Delphi判断一个字符是否为汉字的最佳方法

Delphi 解决idtcpclient和idtcpserver通信中文乱码问题

Delphi ado的事务处理例子

Delphi synedit的安装和基本使用

Delphi 下载者源代码

更多相关阅读请进入《Delphi》频道 >>



打赏

取消

感谢您的支持,我会继续努力的!

扫码支持
扫码打赏,您说多少就多少

打开支付宝扫一扫,即可进行扫码打赏哦

分享从这里开始,精彩与您同在

评论

管理员已关闭评论功能...

    正在狠努力加载,请稍候...