Bug 43355 - var callcenter = new CoreTelephony.CTCallCenter (); fails to compile
Summary: var callcenter = new CoreTelephony.CTCallCenter (); fails to compile
Status: RESOLVED DUPLICATE of bug 43329
Alias: None
Product: iOS
Classification: Xamarin
Component: Xamarin.iOS.dll ()
Version: XI 9.6 (iOS 9.3)
Hardware: PC Mac OS
: --- normal
Target Milestone: Untriaged
Assignee: Bugzilla
URL:
Depends on:
Blocks:
 
Reported: 2016-08-15 17:13 UTC by James Moore
Modified: 2016-08-16 01:25 UTC (History)
2 users (show)

Tags:
Is this bug a regression?: ---
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.


Please create a new report on Developer Community or GitHub with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
RESOLVED DUPLICATE of bug 43329

Description James Moore 2016-08-15 17:13:22 UTC
Add this to an iOS file:

      var callcenter = new CoreTelephony.CTCallCenter ();

Get this error:

/reference:/Library/Frameworks/Xamarin.iOS.framework/Versions/Current/lib/mono/Xamarin.iOS//mscorlib.dll /warn:4
AppDelegate.cs(44,24): error CS1540: Cannot access protected member `CoreTelephony.CTCallCenter.CTCallCenter(Foundation.NSObjectFlag)' via a qualifier of type `CoreTelephony.CTCallCenter'. The qualifier must be of type `Testing9.AppDelegate' or derived from it
		/Library/Frameworks/Xamarin.iOS.framework/Versions/Current/lib/mono/Xamarin.iOS/Xamarin.iOS.dll (Location of the symbol related to previous error)
AppDelegate.cs(44,24): error CS1729: The type `CoreTelephony.CTCallCenter' does not contain a constructor that takes `0' arguments
		/Library/Frameworks/Xamarin.iOS.framework/Versions/Current/lib/mono/Xamarin.iOS/Xamarin.iOS.dll (Location of the symbol related to previous error)
	Task "Csc" execution -- FAILED
Comment 1 James Moore 2016-08-15 17:13:45 UTC
=== Xamarin Studio Professional ===

Version 6.1 (build 5338)
Installation UUID: 6dc077b1-7f04-4c1c-b481-1dcbb9a8b0a1
Runtime:
	Mono 4.6.0 (mono-4.6.0-branch/e571108) (64-bit)
	GTK+ 2.24.23 (Raleigh theme)

	Package version: 406000138

=== NuGet ===

Version: 3.4.3.0

=== Xamarin.Profiler ===

Not Installed

=== Apple Developer Tools ===

Xcode 7.3.1 (10188.1)
Build 7D1014

=== Xamarin.iOS ===

Version: 9.99.2.40 (Visual Studio Professional)
Hash: 40db5d1
Branch: cycle8
Build date: 2016-08-11 18:59:56-0400

=== Xamarin.Android ===

Version: 6.2.0.33 (Visual Studio Professional)
Android SDK: /Users/james/Library/Developer/Xamarin/android-sdk-mac_x86
	Supported Android versions:
		4.0.3  (API level 15)
		4.1    (API level 16)
		4.2    (API level 17)
		4.3    (API level 18)
		4.4    (API level 19)
		4.4.87 (API level 20)
		5.0    (API level 21)
		5.1    (API level 22)
		6.0    (API level 23)

SDK Tools Version: 25.2.1
SDK Platform Tools Version: 24.0.1
SDK Build Tools Version: 24

Java SDK: /Library/Java/JavaVirtualMachines/jdk1.8.0_77.jdk/Contents/Home
java version "1.8.0_77"
Java(TM) SE Runtime Environment (build 1.8.0_77-b03)
Java HotSpot(TM) 64-Bit Server VM (build 25.77-b03, mixed mode)

Android Designer EPL code available here:
https://github.com/xamarin/AndroidDesigner.EPL

=== Xamarin Android Player ===

Not Installed

=== Xamarin.Mac ===

Version: 2.10.0.57 (Visual Studio Professional)

=== Build Information ===

Release ID: 601005338
Git revision: 860f5d2e358077f913badaf7b14c5532888bf12c
Build date: 2016-08-11 16:20:43-04
Xamarin addins: 8bea879bcb4de08213fff5812fd54323d79889d6
Build lane: monodevelop-lion-cycle8

=== Operating System ===

Mac OS X 10.11.6
Darwin retina.restphone.com 15.6.0 Darwin Kernel Version 15.6.0
    Thu Jun 23 18:25:34 PDT 2016
    root:xnu-3248.60.10~1/RELEASE_X86_64 x86_64
Comment 2 Sebastien Pouliot 2016-08-16 01:25:01 UTC

*** This bug has been marked as a duplicate of bug 43329 ***