关于存储声音文件的问题

liliangliang1981 2004-11-06 11:52:42
我想请问一下,如何把一个声音文件保存到sqlserver数据中。谢谢!
...全文
95 5 打赏 收藏 转发到动态 举报
写回复
用AI写文章
5 条回复
切换为时间正序
请发表友善的回复…
发表回复
ktcserver 2004-11-11
  • 打赏
  • 举报
回复
SaveToStream
liliangliang1981 2004-11-11
  • 打赏
  • 举报
回复
字符串的可以这样写,我知道,可存声音的怎么写啊?你可不可以直接给我写一个存声音的程序?求你了!
liliangliang1981 2004-11-11
  • 打赏
  • 举报
回复
问题已经解决了!谢谢各位!
我不懂电脑 2004-11-08
  • 打赏
  • 举报
回复
使用Blob字段呀
The following example uses a blob stream to write a string to the end of the Notes field in the Tasks table.

void __fastcall TForm1::AppendNoteClick(TObject *Sender)

{
TStream *pStream;

Tasks->Edit();
if (Tasks->State == dsEdit)
{
pStream = Tasks->CreateBlobStream(Tasks->FieldByName("Notes"), bmReadWrite);
try
{
AnsiString S = "This line will be added to the end";
pStream->Seek(0, 2); // Seek 0 bytes from the stream's end point
pStream->Write(S.c_str(), S.Length());
Tasks->Post();
}
__finally
{
delete pStream;
}

}
}
thp 2004-11-08
  • 打赏
  • 举报
回复

1,178

社区成员

发帖
与我相关
我的任务
社区描述
C++ Builder 数据库及相关技术
社区管理员
  • 数据库及相关技术社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

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