help me ?delphi5

hubangjian 2000-08-23 10:14:00
在我的QUERY连接上了DBGRID后,怎样在DBGRID中选定了一条记录后,然后删除它?但用
QUERY.DELETE 老是出错,不在编辑和插入状态,我都做了,还是不行?用另外的方法,
QUERY的SQL方法删除时,怎样在DBGRID中捕捉鼠标当前选定的行,代码如何写?


...全文
113 3 打赏 收藏 转发到动态 举报
写回复
用AI写文章
3 条回复
切换为时间正序
请发表友善的回复…
发表回复
Delfly 2000-09-03
  • 打赏
  • 举报
回复
带order by语句的结果集可以更新,但会数据会更新错位,通过连接TSqlUpdate控件就可以了。
goodman1999 2000-08-23
  • 打赏
  • 举报
回复
Query的结果集能否修改,要看你的SQL语句是否符合一定的规范,有一些SQl的结果是无法修改的如带有ORDER BY子句。Query控件有个RecNo属性可用于捕捉鼠标当前选定的行。
例:
var
aRecNo : integer;
begin
aRecNo := aQuery.RecNo;
aQuery.DisableControls;
aQuery.Close;
...delete record...
aQuery.Open;
aQuery.EnableControls;
if aRecNo <= aQuery.RecordCount then
begin
aQuery.RecNo := aRecNo;
end
else
begin
aQuery.Last;
end;
end;

不知此答是否对路,如有疑问可继续讨论。
kxy 2000-08-23
  • 打赏
  • 举报
回复
Query的RequestLive := True;
一共2个部分,分别下载。 用过BSskin或者VCLskin的哥们 支持的开发语言 Borland Delphi 4/5/6 Borland Delphi 7 Borland Delphi 8 Borland Delphi 2005 Borland Delphi 2006 CodeGear Delphi 2007 支持的操作系统 Windows Vista Wndows 2000/XP/2003 Windows NT4.0 Windows Me Windows 98/98SE Windows 95 版本信息 当前版本:3.0 文件大小:24.9MB 更新日期:2006-12-6 下载次数:22670 软件概述 Skin++ For Delphi目前全面支持Delphi4、Delphi5、Delphi6、Delphi7、Delphi8、Delphi2005、Delphi2006。 迄今为止,Delphi支持4种类型的应用程序: 1、VCL Forms Application – Delphi for Win32 (该类型在Delphi4/5/6/7/2005/2006所有版本包含); 2、VCL Forms Application – Delphi for .Net (该类型在Delphi8/2005/2006中包含); 3、Windows Forms Application – C# Builder (该类型在Delphi2005/2006中包含); 4、Windows Forms Application – Delphi for .Net (该类型在Delphi8/2005/2006中包含)。 Skin++对以上4种Delphi程序类型做了全面的支持。 试用版本描述与运行截图 1.在本安装盘中,包含了Delphi的各个版本(D6,D7,D8,D2005,D2006)Skin++测试例子; 2.关于如何使用Skin++,请参考文档《Skin++ For Delphi [All Edition]使用帮助》; 3.要查询Skin++所有的接口,请参考文档《Skin++接口描述》; 4.本安装盘提供一套试用皮肤PixOS.ssk,正式版用户将获得网站上更多更精美的皮肤。并可获得定期更新; 5.Skin++正式版中提供强大的皮肤设计工具Skin++Builder。 该工具完成皮肤所有的设计工作,并可以全自动导入Windows主题、第三方主题; Skin++Builder使用详情请参考《Skin++Builder Help》; 6.案例说明: 我们以Delphi2006 VCL Win32的测试例子为例,描述其组成。 打开\Delphi 2006\VCL Forms Application - Delphi For Win32\目录中的MDIAPP.exe 该例子是一个MDI类型的程序。主窗口部分演示Skin++在MDI方面处理的各个细节。 如:主菜单条、主弹出菜单、系统菜单、工具条、状态条、MDI客户区、MDI子窗口、MDI子窗口最大化后等各个部分的换肤细节。 Skin++ 3.0 可以对皮肤进行动态的色调设置 这个功能可以使您的程序可以瞬间拥有N套色调的皮肤。 更改色调样例1: 我们分以下几个页面对Delphi的全部控件进行了演示: Buttons、Static、Controls with ScrollBar(带滚动条的控件)、Splitter、TabControls、TrackBar & Progress、Misc Controls、Dialog、DataControls 6.1 Buttons 该部分我们演示了Skin++对Delphi的各种类型的按钮进行的换肤支持, 包括BitBtn按钮、SpeedButton、Tbutton、CheckBox、RadioBox 在该部分,还演示了对按钮进行多风格的换肤效果,“Style 2”按钮和其他按钮不同,呈现了其特有样式。 这种效果一般用在网络电话、多媒体软件、网络聊天等需要同时支持多种按钮风格的地方。 每个按钮具有其固定的5中状态:正常、按下、高量、禁用、默认。在该窗体中演示了每种按钮的5中状态。 并且在Skin++ 3.0 中,支持Focus的效果。通过Tab或方向键可以看到焦点在每个按钮上移动。 6.2 Static 该部分演示了Skin++ 对Label、GroupBox、右键菜单、Panel、FlowPanel、GridPanel等控件的支持。 值得一提的是,Skin++对Label的支持是彻底,并且不像其他的换肤软件需要在窗体
大家用惯了BSskin和VCLskin,但是这个跟专业! 支持的开发语言 Borland Delphi 4/5/6 Borland Delphi 7 Borland Delphi 8 Borland Delphi 2005 Borland Delphi 2006 CodeGear Delphi 2007 支持的操作系统 Windows Vista Wndows 2000/XP/2003 Windows NT4.0 Windows Me Windows 98/98SE Windows 95 版本信息 当前版本:3.0 文件大小:24.9MB 更新日期:2006-12-6 下载次数:22670 软件概述 Skin++ For Delphi目前全面支持Delphi4、Delphi5、Delphi6、Delphi7、Delphi8、Delphi2005、Delphi2006。 迄今为止,Delphi支持4种类型的应用程序: 1、VCL Forms Application – Delphi for Win32 (该类型在Delphi4/5/6/7/2005/2006所有版本包含); 2、VCL Forms Application – Delphi for .Net (该类型在Delphi8/2005/2006中包含); 3、Windows Forms Application – C# Builder (该类型在Delphi2005/2006中包含); 4、Windows Forms Application – Delphi for .Net (该类型在Delphi8/2005/2006中包含)。 Skin++对以上4种Delphi程序类型做了全面的支持。 试用版本描述与运行截图 1.在本安装盘中,包含了Delphi的各个版本(D6,D7,D8,D2005,D2006)Skin++测试例子; 2.关于如何使用Skin++,请参考文档《Skin++ For Delphi [All Edition]使用帮助》; 3.要查询Skin++所有的接口,请参考文档《Skin++接口描述》; 4.本安装盘提供一套试用皮肤PixOS.ssk,正式版用户将获得网站上更多更精美的皮肤。并可获得定期更新; 5.Skin++正式版中提供强大的皮肤设计工具Skin++Builder。 该工具完成皮肤所有的设计工作,并可以全自动导入Windows主题、第三方主题; Skin++Builder使用详情请参考《Skin++Builder Help》; 6.案例说明: 我们以Delphi2006 VCL Win32的测试例子为例,描述其组成。 打开\Delphi 2006\VCL Forms Application - Delphi For Win32\目录中的MDIAPP.exe 该例子是一个MDI类型的程序。主窗口部分演示Skin++在MDI方面处理的各个细节。 如:主菜单条、主弹出菜单、系统菜单、工具条、状态条、MDI客户区、MDI子窗口、MDI子窗口最大化后等各个部分的换肤细节。 Skin++ 3.0 可以对皮肤进行动态的色调设置 这个功能可以使您的程序可以瞬间拥有N套色调的皮肤。 更改色调样例1: 我们分以下几个页面对Delphi的全部控件进行了演示: Buttons、Static、Controls with ScrollBar(带滚动条的控件)、Splitter、TabControls、TrackBar & Progress、Misc Controls、Dialog、DataControls 6.1 Buttons 该部分我们演示了Skin++对Delphi的各种类型的按钮进行的换肤支持, 包括BitBtn按钮、SpeedButton、Tbutton、CheckBox、RadioBox 在该部分,还演示了对按钮进行多风格的换肤效果,“Style 2”按钮和其他按钮不同,呈现了其特有样式。 这种效果一般用在网络电话、多媒体软件、网络聊天等需要同时支持多种按钮风格的地方。 每个按钮具有其固定的5中状态:正常、按下、高量、禁用、默认。在该窗体中演示了每种按钮的5中状态。 并且在Skin++ 3.0 中,支持Focus的效果。通过Tab或方向键可以看到焦点在每个按钮上移动。 6.2 Static 该部分演示了Skin++ 对Label、GroupBox、右键菜单、Panel、FlowPanel、GridPanel等控件的支持。 值得一提的是,Skin++对Label的支持是彻底,并且不像其他的换肤软件需要在窗体上放置一个
Our dOPC Client Toolkit for Delphi is probably one of the most used OPC component collections for Delphi worldwide. In addition, there are a number of good reasons why you should purchase our OPC Framework: dOPC main features: works with Delphi 6, 7, 2005, 2006, 2007, 2009, 2010, XE, XE2, XE3, XE4, XE5, XE6 works with Lazarus (http://www.lazarus.freepascal.org) quick and easy development of OPC DA, XML DA, HDA and AE clients 100% VCL / FCL Library & FireMonkey Framework compatible 100% written in Object Pascal delivered with full source code more than 30 example programs with full source code beside the OPC core components no additional DLL or ActiveX controls needed comprehensive help file, for online versionclick here rapid application deployment Unicode support (RAD Studio 2009 or newer) fast GUI development (no source code required) multiple and remote OPC server connections supported creation of 32 and 64 bit OPC high performance clients no runtime fees, royalty-free runtime distribution no limit on the number of applications developed designed for: Windows 8,7, Vista, XP, 2K, NT, 98, Me creation of OPC XML DA clients for Android, Mac OS (OS X) and iPhone (iOS) (XE5 or higher) OPC Specifications supported by dOPC: OPC Data Access DA 1.x, 2.x and 3.x OPC XML Data Access XML DA 1.x OPC Alarm & Events AE 1.x OPC Historical Data Access HDA 1.x (on request only for registered users) Pascal IDE's supported by dOPC: Embarcadero Delphi and RAD Studio XE2, XE3, XE4, XE5 and XE6 (Windows 32 and 64 bit) Lazarus (ver 1.0.10) with Free Pascal (FPC 2.6.2) or higher (Windows 32 and 64 Bit) Embarcadero Delphi and RAD Studio 2010, XE CodeGear Delphi and RAD Studio 2009 CodeGear Delphi and RAD Studio 2007 (only Delphi Win32) Borland Delphi 6,7, 2005 and 2006 Turbo Delphi 2006 Our powerful dOPC Toolkit allows you to build OPC client applications with just a few mouse clicks. E.g. dOPC includes a GUI component that allows you to bind OPC item values directly to properties of visual components, such as labels or edit boxes. If you want to create high-end OPC client applications in a fast and professional way with the highest performance, then our dOPC Client Toolkit is the right solution for you! We encourage you to download our free trial version, which is fully functional and includes a comprehensive help file and over 30 demo and example programs (with source code).
文件搜索控件 TEasyFileSearch v1.02 by Alexandre GAMBIER Read versions.txt file if you want to see modifications made between each version. Thanks ------ Thanks to : - Udo for his tests on C++ Builder 5 and his ideas for v1.01, v1.02 - J.M. Fontaine for his test on Delphi 7 and his orthography help for v1.01. 1 - DESCRIPTION --------------- TEasyFileSearch is freeware and you use it at your own risk. TEasyFileSearch is completely free also for commercial use. TEasyFileSearch is a component which enable you to search file or folder in directory and subdirectory, using filter mask (*.*, *.exe, ...). You define some search criteria : - look in subfolder , - look for readonly file , - look for hidden file , - look for system file , - look for archile file , - look for directory file, - look for anyfile file . You can filter your research - look for files that is smaller or equal to a size, - look for files that is bigger or equal to a size, - look for file than date is between two date, younger, older or the same than a date, - look for created, modified or opened files. You can exclude files using filter mask, for example you can exclude all files *.exe. TEasyFileSearch don't use recursive function (no stack owerflow error). 2 - LANGUAGE/OS --------------- TEasyFileSearch has been tested only on Delphi 5, 7 and C++ Builder 5. 3 - INSTALLATION ---------------- 1. Extract the TEasyFileSearch.zip 2. Choose Component|Install Component... from the menu 3. Select the Tab 'Into New Package' and fill in: At 'Unit file name': Browse and Select EasyFileSearchReg.pas from the directory where you installed it. At 'Package file name': TEasyFileSearch ( In the directory Projects\Lib ) At 'Description': TEasyFileSearch - looking for files Select Ok 4. You will be asked to confirm building the packag

5,379

社区成员

发帖
与我相关
我的任务
社区描述
Delphi 开发及应用
社区管理员
  • VCL组件开发及应用社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

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