pb中创建文件的函数是那个,是不是要用到api函数 请问如何声明,如何使用!!谢谢

执着过客 2003-10-20 12:02:15
谁有pb的api函数全集,能不能给我一份 zhjianling@sina.com
...全文
63 9 打赏 收藏 转发到动态 举报
写回复
用AI写文章
9 条回复
切换为时间正序
请发表友善的回复…
发表回复
执着过客 2003-10-20
  • 打赏
  • 举报
回复
对,兔子说的对,要用一个blobmid函数
klbt 2003-10-20
  • 打赏
  • 举报
回复
取出后,分段写入,每32765字节写一次。
执着过客 2003-10-20
  • 打赏
  • 举报
回复
但是如何将一个在数据库中大于32k的blob读入该文件呢
  • 打赏
  • 举报
回复
用API:
FUNCTION ulong CreateFile(ref string lpFileName,ulong dwDesiredAccess,ulong dwShareMode,ref SECURITY_ATTRIBUTES lpSecurityAttributes,ulong dwCreationDisposition,ulong dwFlagsAndAttributes,ulong hTemplateFile) LIBRARY "kernel32.dll" ALIAS FOR "CreateFileA"
netxzs 2003-10-20
  • 打赏
  • 举报
回复
value = GetFileSaveName("保存文件", docname, named, "TXT", "Text Files (*.TXT),*.TXT," + "Excel Files (*.xls),*.xls," + "DBase Files (*.dbf),*.dbf" )

IF value = 1 THEN
if right(docname,3) = "txt" then
tab_1.tabpage_1.dw_1.SaveAs(docname, text!, FALSE)
end if
if right(docname,3) = "xls" then
tab_1.tabpage_1.dw_1.SaveAs(docname, Excel!, FALSE)
end if
if right(docname,3) = "dbf" then
tab_1.tabpage_1.dw_1.SaveAs(docname, dBASE2!, FALSE)
end if
end if
jdsnhan 2003-10-20
  • 打赏
  • 举报
回复
up
具体api函数集,可去pdriver或编程俱乐部上看看,那里有。
cuiyingfeng 2003-10-20
  • 打赏
  • 举报
回复
FileOpen ( filename {, filemode {, fileaccess {, filelock {, writemode
{ creator, filetype }}}}} )

File not found If PowerBuilder doesn't find the file, it creates a new file, giving it the specified name, if the fileaccess argument is set to Write!.

我也帮你找一下,重复劳动,呵呵!
klbt 2003-10-20
  • 打赏
  • 举报
回复
PB本身有着方面的函数, 创建文本文件的例子:

GetFileSaveName("保存文件", path, file, "*.txt", "文本文件(*.txt), *.txt")
file_number = FileOpen(path, LineMode!, write!, Shared!, replace!)
佣工7001 2003-10-20
  • 打赏
  • 举报
回复
pb本身就可以搞定
FileOpen ( filename {, filemode {, fileaccess {, filelock {, writemode
{ creator, filetype }}}}} )
File not found If PowerBuilder does not find the file, it creates a new file, giving it the specified name, if the fileaccess argument is set to Write!.

609

社区成员

发帖
与我相关
我的任务
社区描述
PowerBuilder DataWindow
社区管理员
  • DataWindow社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧