Showing results 1 to 5 of 5

Thread: WPF with Entity Framework integration

  1. #1

    Default WPF with Entity Framework integration

    Hi,

    is it posible to use code based wpf project (inside xaml only project) with added an reference to dll, what contains entity franework dependency and app config file?

    When I try to use that set in zenon Supervisor I have errors. Do I doing somthing wrong?

  2. #2

    Default Re: WPF with Entity Framework integration

    Quote Originally Posted by Oleksandr View Post
    Hi,

    is it posible to use code based wpf project (inside xaml only project) with added an reference to dll, what contains entity franework dependency and app config file?

    When I try to use that set in zenon Supervisor I have errors. Do I doing somthing wrong?



    Hi all, 

    adding conString to models constructor solve that problem. But appears problem with changing that conStr

  3. #3
    Join Date
    02.02.2012
    Posts
    23

    Default Re: WPF with Entity Framework integration

    Hi Oleksandr,

    you could try to use a config file. But you can not use the app.config file. This file could only be used on the application level. As the WPF control is implemented in form of control and not an application, you may have to consider that.

    What does it mean?

    You have to explicitly tell the control, which config file it should load. Have a look: https://docs.microsoft.com/en-us/dotnet/api/system.configuration.configurationmanager.openmapp edexeconfiguration?redirectedfrom=MSDN&view=netfra mework-4.8#overloads

    Kind regards,
    Martin

  4. #4

    Default Re: WPF with Entity Framework integration

    Quote Originally Posted by martin_f View Post
    Hi Oleksandr,

    you could try to use a config file. But you can not use the app.config file. This file could only be used on the application level. As the WPF control is implemented in form of control and not an application, you may have to consider that.

    What does it mean?

    You have to explicitly tell the control, which config file it should load. Have a look: https://docs.microsoft.com/en-us/dotnet/api/system.configuration.configurationmanager.openmapp edexeconfiguration?redirectedfrom=MSDN&view=netfra mework-4.8#overloads

    Kind regards,
    Martin


    Hi, thx a lot for hint, I will check that

  5. #5
    Join Date
    02.02.2012
    Posts
    23

Similar Threads

  1. Entity Freamwork add-ins integration behavior
    By Oleksandr in forum Add-In Framework
    Replies: 2
    Last Post: 21st January 2022, 11:18
  2. Replies: 2
    Last Post: 18th November 2019, 10:25
  3. .NET Framework version
    By loanvar in forum VSTA
    Replies: 14
    Last Post: 11th June 2018, 07:54
  4. Replies: 1
    Last Post: 15th July 2016, 09:02
  5. WPF Usercontrol & .Net Framework Version
    By stefan.maus in forum VSTA
    Replies: 1
    Last Post: 31st August 2012, 00:41

Posting Rules

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •