我按.NET的帮助文件做了个数据同步复制的例子,运行在后却出现错误: ( 积分: 300 )

  • 主题发起人 主题发起人 flysand
  • 开始时间 开始时间
F

flysand

Unregistered / Unconfirmed
GUEST, unregistred user!
我按.NET的帮助文件做了个数据同步复制的例子,运行在后却出现错误:
Initializing SQL Server Reconciler failed.[,,,,]
是怎么回事啊?
开发环境是winxp 安装了VS.NET2003,SQLserver2000,SQLserver CE SP3
IIS的虚拟目录zf是允许匿名访问,
SQLserver2000代理也运行了.sa的密码是"123"

程序如下:
Private Sub MenuItem4_Click_1(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MenuItem4.Click
Try
If (System.IO.File.Exists("/Program Files/fc.sdf") = False) then
System.IO.File.Delete("/Program Files/fc.sdf")
End If
Dim connStr As String = "Data Source = /Program Files/fc.sdf"
Dim engine As New System.Data.SqlServerCe.SqlCeEngine(connStr)
engine.CreateDatabase()
engine.Dispose()
Dim repl As System.Data.SqlServerCe.SqlCeReplication = Nothing
repl = New System.Data.SqlServerCe.SqlCeReplication
repl.InternetUrl = "http://AMD1G/zf/sscesa20.dll"
repl.Publisher = "AMD1G"
repl.PublisherDatabase = "fc"
repl.PublisherLogin = "sa"
repl.PublisherPassword = "123"
repl.Publication = "fc"
repl.Subscriber = "sa"
repl.SubscriberConnectionString = "Provider=Microsoft.SQLSERVER.OLEDB.CE.2.0;Data Source=/Program Files/fc.sdf"
repl.Synchronize()
Catch ee As System.Data.SqlServerCe.SqlCeException
MessageBox.Show(ee.Message)
Finally
repl.Dispose()
End Try
End Sub
 
我按.NET的帮助文件做了个数据同步复制的例子,运行在后却出现错误:
Initializing SQL Server Reconciler failed.[,,,,]
是怎么回事啊?
开发环境是winxp 安装了VS.NET2003,SQLserver2000,SQLserver CE SP3
IIS的虚拟目录zf是允许匿名访问,
SQLserver2000代理也运行了.sa的密码是"123"

程序如下:
Private Sub MenuItem4_Click_1(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MenuItem4.Click
Try
If (System.IO.File.Exists("/Program Files/fc.sdf") = False) then
System.IO.File.Delete("/Program Files/fc.sdf")
End If
Dim connStr As String = "Data Source = /Program Files/fc.sdf"
Dim engine As New System.Data.SqlServerCe.SqlCeEngine(connStr)
engine.CreateDatabase()
engine.Dispose()
Dim repl As System.Data.SqlServerCe.SqlCeReplication = Nothing
repl = New System.Data.SqlServerCe.SqlCeReplication
repl.InternetUrl = "http://AMD1G/zf/sscesa20.dll"
repl.Publisher = "AMD1G"
repl.PublisherDatabase = "fc"
repl.PublisherLogin = "sa"
repl.PublisherPassword = "123"
repl.Publication = "fc"
repl.Subscriber = "sa"
repl.SubscriberConnectionString = "Provider=Microsoft.SQLSERVER.OLEDB.CE.2.0;Data Source=/Program Files/fc.sdf"
repl.Synchronize()
Catch ee As System.Data.SqlServerCe.SqlCeException
MessageBox.Show(ee.Message)
Finally
repl.Dispose()
End Try
End Sub
 
后退
顶部