Questions tagged [methodaccessexception]

19 questions
10
votes
2 answers

Anonymous types and Get accessors on WP7.1?

I'm trying to write a simple object to Dictionary converter like below: public static class SimplePropertyDictionaryExtensionMethods { public static IDictionary ToSimplePropertyDictionary(this object input) { if (input…
Stuart
  • 66,722
  • 7
  • 114
  • 165
6
votes
2 answers

Unable to call Assembly.GetName() from my Silverlight application

I want to display my application version number within my application, and the simplest way to do this is to use the version number for the assembly. var assembly = System.Reflection.Assembly.GetExecutingAssembly(); var name =…
Kirk Broadhurst
  • 27,836
  • 16
  • 104
  • 169
4
votes
1 answer

Is this C# code legal?

I have A.Test() declared as public virtual and B.Test() declared as private new. I'm calling base.Test() from C that inherits B. This code compiles with Mono 2.10.2 but throws a MethodAccessException: class A { public virtual void Test () {…
Dan Abramov
  • 264,556
  • 84
  • 409
  • 511
3
votes
0 answers

Attempt by method x to access method y failed

I have write a code base on other code. It is a plugin for Dynamic CRM 2011. Anyways, I wanna replace this plugin with existing Plugin. It is almost a mirror of another .dll Plugin. Anyways, In customization of CRM, I have disabled All steps of…
3
votes
1 answer

Cannot create new ConcurrentQueue on Windows 10?

I'm trying to use the HashLib library in a Windows 10 app, but it throws an unhandled exception (System.MethodAccessException): Attempt by method 'HashLib.Hash.TransformStream(System.IO.Stream, Int64)' to access method…
markus
  • 177
  • 1
  • 13
2
votes
1 answer

Accessing to anonymous object in MVVMCross vNext - Portable - by VS2010 WP emulator

I have VS2012 and VS2010 installed. I am using first one to create PCL core of my Mobile app in MVVMCross vNext and using VS2010 to open UI.WP7 on WP7 emulator (due to problems with connecting to WCF by VS2012 WP emulator - it can not connect to my…
1
vote
1 answer

Automapper Configuration Resolving issue, attempt to access method failed

I am trying to map my domain model to viewModels in my MVC MVVM application. Here is the code of my Auto Mapper Configuration public class AutoMapperConfiguration { public static void Configure() { Mapper.Initialize(x => { …
1
vote
2 answers

Mono. Xamarin. Error loading svg images. System.MethodAccessException

I'm developing a mobile application with Xamarin and getting an error when running it. The error occurs very often but not always. I'm testing it on Sumsung Galaxy S6. The code that I am using (located in renderer): new SvgReader(new…
nikelyn
  • 518
  • 3
  • 13
1
vote
0 answers

Paypal .net MethodAccessException

I want to implement Paypal into my WPF-Application and created a TestProject. Everything works fine but when I transfer the written code into my existing project, I get a MethodAccessException at line var accessToken = new…
DirtyNative
  • 2,553
  • 2
  • 33
  • 58
1
vote
0 answers

Xamarin.forms CarouselView ItemsSource error System.MethodAccessException

System.MethodAccessException has been thrown. This exception is always thrown for CarouselView ItemsSource Though the example from https://blog.xamarin.com/flip-through-items-with-xamarin-forms-carouselview/ is working fine. Same implementation in…
S.Gandhi
  • 11
  • 3
1
vote
1 answer

method access exception in wp7 emulator

I am working on WP project i need to get the images from local folder, when I use Directory.GetFiles() method i get 'System.MethodAccessException' but it works fine on a device. Can anybody please explain me the reason? Regards, Sonya
1
vote
2 answers

Cannot access model method inside its controller in Rails

In my Rails app, I have a controller tickets_controller.rb and model ticket.rb. For creating a ticket I have the following form, <%= form_for(@ticket) do |f| %> <% if @ticket.errors.any? %>

<%=…

0
votes
0 answers

System.MethodAccessException when executing plugin (Dynamics 365 online)

So I wrote a plugin on preLeadUpdate that calls dynamics webapi. When running unit tests against f.e the dev-environment from Visual Studio it works fine but when deploying the plugin to the dev-dynamics instance I get the following error when it…
Toby Fieldgroove
  • 243
  • 4
  • 16
0
votes
1 answer

MethodAccessException on Task.CompletedTask property

I am working on a small wpf application and one of the users is getting the following exception: System.MethodAccessException: Attempt by method "xxx.HttpConfirmation.Invoke()" to access method "System.Threading.Tasks.Task.get_CompletedTask()"…
0
votes
0 answers

Accessing a Method from Another Form to create a new event handler and drop down menu item

I am creating a modular note taking system and I need a way to create a new item in a drop down menu on the main form while also creating an event handler for this new item. I have already created a handler for activation on initialisation but I…
1
2