On Thu, Sep 6, 2012 at 11:30 AM, Robert Reck <[email protected]> wrote:
> Sebastien,
> Thank for the response. Unfortunately, I'm still fairly new to this stuff and 
> a lot of what you said went right over my head.  I have the following 
> references in my project:
>
> IOSTChart.dll (3rd party charting)

It's likely the above assembly (since the others are shipped with MT
and do not reference monotouch.dll).

Try add "--linkskip=IOSTChart" to the "Additional mtouch arguments" of
your project's options. The linker won't process it (and report the
error). The code still won't exists (and that timer won't work) but it
will likely (if I'm right) solve your build-time issue.

> monotouch
> System
> System.Core
> System.Json
> System.Xml
> System.Xml.Linq
>
> I'm not sure what I need to do to resolve this.  I did try clean all and 
> rebuild all with no change.
> Bob
>
>
>
> On Sep 6, 2012, at 10:19 AM, Sebastien Pouliot 
> <[email protected]<mailto:[email protected]>> wrote:
>
> Hello,
>
> On Thu, Sep 6, 2012 at 10:04 AM, bobreck 
> <[email protected]<mailto:[email protected]>> wrote:
> Folks, I am getting a strange error when building my app for debug
> deployment to my test device. This does not happen when compiling for the
> simulator.
>
> This is because:
> a) the linker (reporting the error) is not used (by default) when
> compiling for the simulator;
> b) the JIT (just in time) does not see missing member references
> (until it has the execute them);
>
> The specific error is: error MT2002: Can not resolve reference:
> System.Void MonoTouch.Foundation.NSTimer::.ctor() I've searched for this and
> found a bunch of similar error MT2002's but nothing has resolved this issue.
>
> MT2002 errors are almost always the same cause. An assembly you're
> using refers to members (of another assembly) that cannot be found.
> The linker is not able to write a valid assembly (since there's no
> member to reference) and tells you which symbol is missing.
>
> I am running the MonoDevelop 3.0.4.5 and MonoTouch 5.4.0 (just downloaded
> this morning).
>
> In 5.4 NSTimer does not have a default constructor (because such an
> instance is invalid, i.e. `init` in ObjC would return `nil`, and would
> cause you weird issue later at runtime).
>
> Please let me know if you need more information to make sense
> of this. Thank you! Bob
>
> You're likely referencing an precompiled assembly that has a reference
> to this default .ctor. If not make sure you have cleaned your solution
> and rebuilt everything.
>
> Sebastien
>
_______________________________________________
MonoTouch mailing list
[email protected]
http://lists.ximian.com/mailman/listinfo/monotouch

Reply via email to