Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 861333
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 15, 20262026-05-15T08:57:47+00:00 2026-05-15T08:57:47+00:00

Using SQL ManagementStudio 2008 I created SQL 3.5 Compact DB (TestCompact.sdf) and I have

  • 0

Using SQL ManagementStudio 2008 I created SQL 3.5 Compact DB (TestCompact.sdf) and I have created subscription to existing Publication. Using SQL Management Studio it is working. I have transfered TestCompact.sdf to Windows Mobile 5 emulator device and with QueryAnalyzer for Mobile I could query existing tables in TestCompact.sdf. I don’t know how to start replication synchronization on that mobile device. Do I need to write some C# code or it is possible do it more simple?

EDIT: (Added after reply on my question)
Maybe it will be useful for someone what C# code did the job for me:
(Using SQL Management Studio – Properties on existing subscription for my Compact DB) I read what are values for a replObj properties)

private void btnSync_Click(object sender, EventArgs e)
    {
        SqlCeConnection sqlCeConn = null;
        SqlCeReplication replObj = new SqlCeReplication();
        string connString = @"data source=\My Documents\TestReplicationCompactDB.sdf;Password=bero";
        replObj.InternetUrl = @"http://192.168.99.99/VirtualDirectoryForCompactDBReplication/sqlcesa35.dll";;
        replObj.PublisherDatabase =  "TestReplicationDB";
        replObj.PublisherSecurityMode = SecurityType.NTAuthentication;;
        replObj.Publisher = @"DBTESTSRV\SQL2008";
        replObj.Publication = "TestReplication2";
        replObj.Subscriber = "TestReplication";
        replObj.SubscriberConnectionString = @"data source=\My Documents\TestReplicationCompactDB.sdf;Password=bero";
        replObj.InternetLogin = @"ares\intor";
        replObj.InternetPassword = "intor";
        try
        {
            sqlCeConn = new SqlCeConnection(connString);
            sqlCeConn.Open();
            replObj.Synchronize();
            sqlCeConn.Close();
        }
        catch (Exception ex) { 
            MessageBox.Show(ex.Message);
            if (sqlCeConn != null && sqlCeConn.State == ConnectionState.Open)
                sqlCeConn.Close();
            return;
        }
        string countPublisherChanges = replObj.PublisherChanges.ToString();
        string countSubScriberChanges = replObj.SubscriberChanges.ToString();
        MessageBox.Show(String.Format("Finished with {0} subscriber changes and with {1} publisher changes", countSubScriberChanges, countPublisherChanges));
    } 
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-15T08:57:47+00:00Added an answer on May 15, 2026 at 8:57 am

    You need to write “some” C# code, at the end of the Wizard in SSMS you get some sample code.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Background: I'm using SQL Server Management Studio 2008 and I have a query window
I have a problem when debugging stored procedure using SQL server Management Studio 2008.
Using SQL Server Express 2008 & Management Studio. I have a table & a
I am using SQL server 2008. If I am working on the Management Studio's
using Visual.Web.Developer.2010.Express; using SQL.Server.Management.Studio.2008.R2; N00b here, I have a GridView, but I want to
I'm using Microsoft SQL Server 2008 Management Studio to create a relational schema by
I'm using SQL Server Management Studio 2008 and SQL Server 2008. Currently, I cannot
using Visual.Web.Developer.2010.Express; using SQL.Server.Management.Studio.2008.R2; What I'm ultimately trying to do is update a sql
using Visual.Web.Developer.2010.Express; using SQL.Server.Management.Studio.2008.R2; Kinda new at C# here.. I got the first row
I am using SQL Server 2008 management studio to execute the following SQL statements,

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.