locked
"Can't find PInvoke DLL 'sqlceme35.dll", Cannot find a solution that works RRS feed

  • Question

  • Hi , 
    I'm using VS2008 , compact framework 3,5 and i'm trying to deploy an app to my windows mobile 6.0
    I have also installed Compact 3.5 to my mobile device (main memory) and I used the deployment tools that VS provides.
    Meaning by that , I have created a project for smart devices etc...
    In the emulator everyhting is working find(professional emulator 6)
    I ran the app and when it comes to select from the sdf file then I'm getting the message.
    I googled a lot.
    Found the below link

    http://blogs.msdn.com/sqlservercompact/archive/2007/10/26/can-t-find-p-invoke-dll-sqlcemenn-dll.aspx


    I tried solution 2 but I don't understand what's to be done.
    It says Fix the auto-deployment issues (Don’t ask me how L )
    What does this mean ???

    Also I did the below but nothing
    Remove
    and add the reference to System.Data.SqlServerCe.  This is because, VS
    IDE stores assembly identity in the project file.  Since we have
    changed the assembly version in SQL CE v3.5 SP1, removing and adding
    updates the solution to host the right assembly version



    and finally
    Manually copy and install the SQL CE Cabs (all the 3 cabs).  They are located under:
    %VisualStudioInstallRoot%\SmartDevices\SDK\SQL Server\Mobile\v3.0\<platform>\<processor>

    OR

    %ProgramFiles%\Microsoft SQL Server Compact Edition\<version>\Devices\<platform>\<processor>


    Where am I suppose to install them and how ????

    How will I overcome this ??

    Any help will be appreciated.

    thank you





    • Edited by Jason.Smith Friday, June 26, 2009 5:46 PM fixing double encoding in title
    Thursday, June 18, 2009 5:57 PM

Answers

  • Hi,

    The cab files that you would most likely use are located here on my machine (Default Location) :-

    C:\Program Files\Microsoft SQL Server Compact Edition\v3.5\Devices\wce500\armv4i

    If you have located the SQL Cab files you can copy them to your device and then tap on each one to install them.

    The sqlceme35.dll is a native DLL that gets installed by these cab files into the \Program Files\Microsoft SQL Server Compact Edition\v3.5 directory of the device.

    Once the cab files have been installed then you should no longer get this exception.

    Hope this helps.

    Paul Diston
    http://www.smartmobiledevice.co.uk/
    • Marked as answer by zakkar Friday, June 19, 2009 6:22 AM
    Thursday, June 18, 2009 6:06 PM

All replies

  • Hi,

    The cab files that you would most likely use are located here on my machine (Default Location) :-

    C:\Program Files\Microsoft SQL Server Compact Edition\v3.5\Devices\wce500\armv4i

    If you have located the SQL Cab files you can copy them to your device and then tap on each one to install them.

    The sqlceme35.dll is a native DLL that gets installed by these cab files into the \Program Files\Microsoft SQL Server Compact Edition\v3.5 directory of the device.

    Once the cab files have been installed then you should no longer get this exception.

    Hope this helps.

    Paul Diston
    http://www.smartmobiledevice.co.uk/
    • Marked as answer by zakkar Friday, June 19, 2009 6:22 AM
    Thursday, June 18, 2009 6:06 PM
  • Never mind.
    Found it.
    I have located the cabs and installed them

    thank you
    Thursday, June 18, 2009 6:21 PM
  • Thank you very much Paul. After posting my question I did a more thorough search and found the cabs.
    Although I have installed the cabs from the below path
     C:\Program Files\Microsoft SQL Server Compact Edition\v3.5\Devices\wce400\armv4i
    it worked !!!

    Thank you again Paul

    I have one more question for you.

    Is there any fix for the cabinet file VS 2008 is creating ?
    Why Visual Studio 2008 does not include them while builder the cab ???
    Am I missing something ?

    Thank you
    Friday, June 19, 2009 6:27 AM
  • Hi,

    If you are deploying to a WM6 device I would have thought you should have used the WCE500 version of the CAB files. WCE400 versions are for PPC2003.

    If you make use of SQL Sever Compact Edition in your application then the best way to deploy this is via the CAB files specificly for the SQL CE. You could include the managed DLLs into your own CAB file however I am not too sure whether this would include the native DLLs as well.

    Thanks

    Paul Diston
    http://www.smartmobiledevice.co.uk/
    Friday, June 19, 2009 6:59 AM
  • Hi,
    Ok Paul. I'll give it a try
    thank you very much
    Monday, June 22, 2009 6:16 AM
  • I receive the same error when I run my WM6 application in the Visual Studio Simulator.

    What should I do? Where I should copy the cab files??

    Any idea is appreciated..



    TIA,
    /Maria
    Friday, February 26, 2010 5:11 PM
  • I managed to fix the problem by installing SQL Server 3.5 SP2
    Wednesday, December 8, 2010 11:47 AM
  • A pesar que he recorrido mil foros, la respuesta correcta no está.

    LA RESPUESTA ESTA AQUI:

    ms-help://MS.SSC.v35/MS.SSC.v35.ES/sscprog/html/f3127502-44d2-4cc8-9189-40900b26e8fe.htm

    EN  LA SECCION Agregar SQL Server Compact 3.5 al proyecto y Configurar SQL Server Compact para la implementación privada

    LUEGO DE ÉSTO TE FUNCIONA TODO A MIL........

    Sunday, March 18, 2012 11:32 AM