Trying to compile a C#-program using NI-Vision

Hello,
i have zip-file from a colleague which contains a C#-program that uses NI-Vision 8.5.
The project used to work and i have to make changes to the code but currently i am just trying to compile the old code.
System: Windows XP
Installed Software:
- Microsoft Visual C#2008 Express Edition
- Ni Vision Development Module 8.5
- IC Capture 2.0 (SW from the Camera)
- IC Imaging Control 3.0 (SW from the Camera)
When trying to compile the project it says 30 errors with:
"Type or Namespace "NationalInstruments" not found"
When checking the Verweise (see screenshot) then there is one line marked:
NationalInstruments.AxCWIMAQControlsLib.Interop
So i think this is the only thing that is missing that i can compile the program.
But how can i add it?
When i check the available Verweise then there are a lot of NationInstruments-things but all with other names.
What do i have to do?
Thanks for all help
Attachments:
Eins.jpg ‏11 KB
zwei.jpg ‏25 KB
drei.jpg ‏45 KB

Hi Aurelie,
thank you for the tips.
I am sure that it is nit DotNet 4 because it is compiled with C#2008 (which cannot use 4.0).
The namespace NationInstrument is found but not the marked Reference.
Meanwhile i deleted the missing reference and added another. Now i can compile without errors.
The program is still not running but i think this is because the camera-driver is missing...
But i still dont know how my collegue inserted this now missing reference.
TM

Similar Messages

  • Error in compiling boost example program using sun studio 12

    I am trying to compile the below example program from boost using sun studio 12 C++ compiler.
    #include <boost/interprocess/shared_memory_object.hpp>
    #include <boost/interprocess/mapped_region.hpp>
    #include <cstring>
    #include <cstdlib>
    #include <string>
    int main(int argc, char *argv[])
    using namespace boost::interprocess;
    if(argc == 1)
    {  //Parent process
    //Remove shared memory on construction and destruction
    struct shm_remove
    shm_remove() { shared_memory_object::remove("MySharedMemory"); }
    ~shm_remove(){ shared_memory_object::remove("MySharedMemory"); }
    } remover;
    //Create a shared memory object.
    shared_memory_object shm (create_only, "MySharedMemory", read_write);
    //Set size
    shm.truncate(1000);
    //Map the whole shared memory in this process
    mapped_region region(shm, read_write);
    //Write all the memory to 1
    std::memset(region.get_address(), 1, region.get_size());
    //Launch child process
    std::string s(argv[0]); s += " child ";
    if(0 != std::system(s.c_str()))
    return 1;
    else
    //Open already created shared memory object.
    shared_memory_object shm (open_only, "MySharedMemory", read_only);
    //Map the whole shared memory in this process
    mapped_region region(shm, read_only);
    //Check that memory was initialized to 1
    char mem = static_cast<char>(region.get_address());
    for(std::size_t i = 0; i < region.get_size(); ++i)
    if(*mem++ != 1)
    return 1; //Error checking memory
    return 0;
    Using the below command :
    CC -c 1.cpp -I/home/syogacha/satish/boost_1_43_0 -library=stlport4
    "/home/syogacha/satish/boost_1_43_0/boost/interprocess/shared_memory_object.hpp", line 284: Error: The function "shm_open" must have a prototype.
    "/home/syogacha/satish/boost_1_43_0/boost/interprocess/shared_memory_object.hpp", line 307: Error: The function "shm_unlink" must have a prototype.
    "/home/syogacha/satish/boost_1_43_0/boost/interprocess/mapped_region.hpp", line 549: Error: Formal argument 1 of type char* in call to shmdt(char*) is being passed void*.
    3 Error(s) detected.
    I even tried to include sys/mman.h but got the same compilation errors.
    Do we need to take care of few other specific things while using boost headers.
    Thanks in advance ...

    Hope this helps....
    #include <sys/mman.h>
    #include <boost/interprocess/shared_memory_object.hpp>
    #include <boost/interprocess/mapped_region.hpp>
    #include <cstring>
    #include <cstdlib>
    #include <string>
    #include <iostream>
    #include <iterator>
    int main(int argc, char *argv[])
    {      //main
            using namespace boost::interprocess;
            if(argc == 1)
            {  //Parent process
                    //Remove shared memory on construction and destruction
                    struct shm_remove
                            shm_remove() { shared_memory_object::remove("MySharedMemory"); }
                            ~shm_remove(){ shared_memory_object::remove("MySharedMemory"); }
                    } remover;
                    //Create a shared memory object.
                    shared_memory_object shm (create_only, "MySharedMemory", read_write);
                    //Set size
                    shm.truncate(1000);
                    //Map the whole shared memory in this process
                    mapped_region region(shm, read_write);
                    //Write all the memory to 1
                   std::memset(region.get_address(), 1, region.get_size());
                    //Launch child process
                    std::string s(argv[0]); s += " child ";
                    if(0 != std::system(s.c_str()))
                    return 1;
            else
                    //Open already created shared memory object.
                    shared_memory_object shm (open_only, "MySharedMemory", read_only);
                    //Map the whole shared memory in this process
                    mapped_region region(shm, read_only);
                    //Check that memory was initialized to 1
                    char *mem = static_cast<char*>(region.get_address());
                    for(std::size_t i = 0; i < region.get_size(); ++i)
                    if(*mem++ != 1)
                    return 1;   //Error checking memory
            return 0;
    }

  • Trying to compile a GUI program with ActionEvent and Color/Graphics

    Hey, I am trying to compile a program that where I press a button it designs/displays a picture. I have the first part that shows the button, but I can''t get the second part of it. Any suggestions on what to do? Here is the part of the code that I am unsure about, the idea is to get that to design a picture:
    private class ButtonHandler implements ActionListener
              public void actionPerformed( ActionEvent event )
         }

    Heres the code in order to give a better idea of what I am trying to do:
    import java.awt.FlowLayout;
    import java.awt.Color;
    import java.awt.Graphics;
    import java.awt.event.ActionListener;
    import java.awt.event.ActionEvent;
    import javax.swing.JLabel;
    import javax.swing.JPanel;
    import javax.swing.JFrame;
    import javax.swing.JButton;
    public class Game extends JFrame
         private JLabel greeting; // greets user and gives initial instructions
         private JButton startGame; // start game button
         private JButton highScore; // displays high scores
         private JButton exitGame; // exits game
         // adds buttons to JFrame
         public Game()
              super( "Game" );
              setLayout( new FlowLayout() ); // set frame layout
              greeting = new JLabel( "Make selection..." );
              add( greeting );           
              startGame = new JButton( "Start Playing" );
              add( startGame );
              highScore = new JButton( "View High Scores" );
              add( highScore );
              exitGame = new JButton( "Exit Game" );
              add( exitGame );
              ButtonHandler handler = new ButtonHandler();
              startGame.addActionListener( handler );
         private class ButtonHandler implements ActionListener
              public void actionPerformed( ActionEvent event )
              public void paintComponent( Graphics g )
    super.paintComponent( g );
    g.setColor( Color.RED );
    g.fillOval( 10, 10, 200, 200 );
    }

  • Trying to compile program using Swing.

    I am trying to compile a SWING program (i.e. JFrame, JButton etc). Program does not have main method.
    Obviously when I compile, I get
    Exception in thread "main" java.lang.NoSuchMethodError: main.
    Isnt it allowable to have a Swing pgm without a main method ???
    Am I missing something obvious? Do I need to move a Swing jar file somewhere? Using J2SDK1.4.0 on WindowsME. Java is installed OK, because I can compile and execute other basic programs..

    No, all Java programs, just like C/C++ require a main() method entry point.
    Typically, in a Swing program, all you need to this is this (at the very minimum)
    public static void main(String[] args) {
    JFrame myAppFrame = new JFrame();
    myAppFrame.show();
    Usually you don't create a generic JFrame but instead extend your own class from a JFrame and put all of the initialization (JMenuBars, JPanels, windowlisteners, etc) in its constructor.

  • "No rule to make target" when compiling a C++ program under Winelib

    I'm trying to compile a C++ program for Windows using Winelib, and it keeps exiting without doing anything with this message:
    make: *** No rule to make target `windows.so', needed by `all'.  Stop.
    I don't think there's anything anywhere in the code or the makefile about "windows.so"... What is this about?

    You're going to have to provide way more information - what does your project look like? Where did you get it? Did you write the makefile yourself?

  • Problem in compiling and running programs in Java3D

    Dear Friends,
    I'm newly installed Java 3D in my c:\ alreadey I'm havind jdk1.3 but java 3D created a new folder namely jdk1.2.2 in c:\. Now I am trying to compile my first program through javac but it couldn't find the libraries. In documentation this is given that don't set any path for java 3d. I've tried to run the demo programs through appletviewer but it couldn't. It is some what happening while I'm clicking the links to run. but it is very sluggish in ie5.
    Pl. give me the needed solution, eigther here or at : [email protected]
    Thanks,
    K.Ranganathan.

    follow the installtion guide for java3d on this site (java.sun.com)
    To summarise it.... Java3D 1.2 is designed for Java1.2.2, however if, when installing it, u install it to the Java1.3 dir it should work fine...... mine does ;-P
    AbU5e,

  • Running external program using java

    hi
    i am trying to run an external program using the runtime.exec() method. my problem is that the external program only runs when i press ctrl-c to exit my program. does anyone know how i can execute the external program while my program is still running without having to quit the program?should i be using threads?
    thanks

    As per the api doc exec will be executed as a seperate process
    Process exec(String command) ------Executes the specified string command in a separate process.
    Can you able to share that code what you have written ?

  • My macbook crashed and I am trying to install my adobe programs again but I can't because he is used earlier by myself. How can I fix this without buying a whole new packet?

    My macbook crashed and I am trying to install my adobe programs again but I can't because he is used earlier by myself. How can I fix this without buying a whole new packet?

    Hannahdb1 what specific Adobe applications are you attempting to reinstall?  Do you receive any specific error messages?  Finally what version of Mac OS are you using?

  • Program using Xalan 1.10 doesn't compile

    Hi all,
    I have to port some server code from Windows to Solaris. Normaly this works fine, but now I have a problem using Xalan 1.10.
    Platfrom: SunOS sun4 5.8 Generic_108528-24 sun4u sparc SUNW,Ultra-80
    Compiler: Sun C++ 5.7 Patch 117830-07 2006/03/15
    By including a Xalan header and compile it with "CC -I/opt/xalan/src -I/opt/xerces/src -library=stlport4 xalan.cpp" I got the errorlist below.
    Without stlport4 it compiles. I have to use this library, because I am using boost and I have had only success building the boost stuff with stlport4.
    Do I have to modify the Xalan header? Has anybody some suggestions?
    Thanks for your help
    Arno
    Here is the example code:
    #include <xalanc/XalanTransformer/XalanTransformer.hpp>
    int main ()
    return 0;
    Here are the error messages from the compiler:
    "/opt/xalan/src/xalanc/Include/XalanVector.hpp", line 102: Error: Too many arguments for template std::reverse_iterator<xalanc_1_10::Type*, std::random_access_iterator_tag, xalanc_1_10::Type>.
    "/opt/xalan/src/xalanc/Include/XalanVector.hpp", line 1101: Where: While specializing "xalanc_1_10::XalanVector<xalanc_1_10::Type, xalanc_1_10::ConstructionTraits>".
    "/opt/xalan/src/xalanc/Include/XalanVector.hpp", line 1101: Where: Specialized in non-template code.
    "/opt/xalan/src/xalanc/Include/XalanVector.hpp", line 106: Error: Too many arguments for template std::reverse_iterator<const xalanc_1_10::Type*, std::random_access_iterator_tag, const xalanc_1_10::Type>.
    "/opt/xalan/src/xalanc/Include/XalanVector.hpp", line 1101: Where: While specializing "xalanc_1_10::XalanVector<xalanc_1_10::Type, xalanc_1_10::ConstructionTraits>".
    "/opt/xalan/src/xalanc/Include/XalanVector.hpp", line 1101: Where: Specialized in non-template code.
    "/opt/xalan/src/xalanc/Include/XalanDeque.hpp", line 186: Error: Too many arguments for template std::reverse_iterator<xalanc_1_10::XalanDequeIterator<xalanc_1_10::XalanDequeIteratorTraits<xalanc_1_10::Value>, xalanc_1_10::XalanDeque<xalanc_1_10::Type, xalanc_1_10::ConstructionTraits>>, std::random_access_iterator_tag, xalanc_1_10::Type>.
    "/opt/xalan/src/xalanc/XPath/XalanQName.hpp", line 73: Where: While specializing "xalanc_1_10::XalanDeque<xalanc_1_10::Type, xalanc_1_10::ConstructionTraits>".
    "/opt/xalan/src/xalanc/XPath/XalanQName.hpp", line 73: Where: Specialized in non-template code.
    "/opt/xalan/src/xalanc/Include/XalanDeque.hpp", line 190: Error: Too many arguments for template std::reverse_iterator<xalanc_1_10::XalanDequeIterator<xalanc_1_10::XalanDequeConstIteratorTraits<xalanc_1_10::Value>, xalanc_1_10::XalanDeque<xalanc_1_10::Type, xalanc_1_10::ConstructionTraits>>, std::random_access_iterator_tag, const xalanc_1_10::Type>.
    "/opt/xalan/src/xalanc/XPath/XalanQName.hpp", line 73: Where: While specializing "xalanc_1_10::XalanDeque<xalanc_1_10::Type, xalanc_1_10::ConstructionTraits>".
    "/opt/xalan/src/xalanc/XPath/XalanQName.hpp", line 73: Where: Specialized in non-template code.
    4 Error(s) detected.

    On Solaris, Posix threads are implemented on top of native threads; the interfaces are different. There are no conflicts between the two libraries or their interfaces. You can mix Posix and native thread usage.
    libCstd and STLport are different implementations of the same interface. The size and layout of the standard types are different. The names of the standard functions are the same, but the definitions of those functions are different.
    Suppose both parts of the program use the standard string class. One part was compiled for use with libCstd, and creates the libCstd version of a string object. If that object gets passed to the part of the program compiled for use with STLport, it will have a different idea of how the class is defined.
    If you link both libCstd and libstdlport to the program, all the standard objects (like cin and cout) and functions (class members and free functions) will have the same names. You wil pick up the version from whichever library is linked first. Calling libCstd function on an STLport object won't work, and neither will the reverse.
    Finally, recall that much of the standard library consists of inline functions. The bodies of those functions are embeded in the .o files of your application code. The application code will therefore depend on a particular layout of standard class objects; the layout is different in the two libraries.
    We have not made a serious effort to compile BOOST using libCstd -- much of BOOST depends on too many missing features. Some suggestions:
    1. You can try experimenting with BOOST configuration macros and see if you can get the code to compile.
    2. You could wirte your own version of the BOOST components you are using, removing dependencies on features that are not in libCstd.
    3. You could ask the 3rd-party library supplies to provide a version compiled with -library=stlport.

  • Compilation of C program in 64 bit mode using  gcc

    How do i compile a C program in 64 bit mode using gcc 2.95.2. I am using Sun Os 5.8.
    Pls give the command

    When i use the follwing script
    cc -w -v -DSOLARIS -DSOLARIS2 -m64 -c $1.c -I./. -I/usr/lib/sparcv9 -I/usr/include -I/usr/include/sys -I/usr1/soft/smshdr -I/oracle9i/precomp/public -I/oracle9i/sqllib/public
    I got the following error .. Pls help
    Reading specs from /opt/sfw/lib/gcc-lib/sparc-sun-solaris2.8/2.95.2/specs
    gcc version 2.95.2 19991024 (release)
    /opt/sfw/lib/gcc-lib/sparc-sun-solaris2.8/2.95.2/cpp -lang-c -v -I./. -I/usr/li
    b/sparcv9 -I/usr/include -I/usr/include/sys -I/usr1/soft/smshdr -I/oracle9i/prec
    omp/public -I/oracle9i/sqllib/public -D__GNUC__=2 -D__GNUC_MINOR__=95 -Dsparc -D
    sun -Dunix -D__svr4__ -D__SVR4 -D__sparc__ -D__sun__ -D__unix__ -D__svr4__ -D__S
    VR4 -D__sparc -D__sun -D__unix -Asystem(unix) -Asystem(svr4) -w -D__arch64__ -Ac
    pu(sparc64) -Amachine(sparc64) -DSOLARIS -DSOLARIS2 XCupCRC.c /var/tmp/cckMTbiU.
    i
    GNU CPP version 2.95.2 19991024 (release) (sparc)
    #include "..." search starts here:
    #include <...> search starts here:
    /usr/lib/sparcv9
    /usr/include
    /usr/include/sys
    /usr1/soft/smshdr
    /oracle9i/precomp/public
    /opt/sfw/include
    /opt/sfw/lib/gcc-lib/sparc-sun-solaris2.8/2.95.2/../../../../sparc-sun-solaris2
    .8/include
    /opt/sfw/lib/gcc-lib/sparc-sun-solaris2.8/2.95.2/include
    /usr/include
    End of search list.
    The following default directories have been omitted from the search path:
    /opt/sfw/lib/gcc-lib/sparc-sun-solaris2.8/2.95.2/../../../../include/g++-3
    End of omitted list.
    /opt/sfw/lib/gcc-lib/sparc-sun-solaris2.8/2.95.2/cc1 /var/tmp/cckMTbiU.i -quiet
    -dumpbase XCupCRC.c -m64 -w -version -o /var/tmp/ccqeBknF.s
    cc1: -m64 is not supported by this configuration
    cc1: -mptr32 not allowed on -m64
    GNU C version 2.95.2 19991024 (release) (sparc-sun-solaris2.8) compiled by GNU C
    version 2.95.2 19991024 (release).
    XCupCRC.c: In function `XCupCRC':
    XCupCRC.c:45: internal error--unrecognizable insn:
    (insn 208 206 210 (set (reg:DI 10 %o2)
    (symbol_ref:DI ("*.LLC0"))) -1 (nil)
    (nil))

  • Compiling programs using jdk1.6.0

    when i compiled program using "system.out.print.in " , it shows an error
    that package system does not exist .

    if you want to print something use
    System.out.printor if you want to make it print on seperate lines
    System.out.println

  • Hello friends , I have started with writing  c code on mac using xcode .....but one of my friend told me to use gcc for coding. He started with terminal And used a text editor to compil the c program on his mac.. So please tell me how to do the same

    Hello friends , I have started with writing  c code on mac using xcode .....but one of my friend told me to use gcc for coding. He started with terminal And used a text editor to compil the c program on his mac.. So please tell me how to do the same and is there any pre stalled text editor on mac if yes then where and if no then which text editor to install and how to install gcc...please help me out thanks in advance !!!

    I have started with writing  c code on mac using xcode .....but one of my friend told me to use gcc for coding.
    Why? If you are developing and writing code on a Mac why would you not use the tools Apple has given you? And Xcode, once you get use to it, is a very nice development environment that will make you life a whole lot easier.
    If you insist on using an editor and the terminal I would recommend  Emacs   but it has a long learning curve so  something like TextWrangler  will work too.
    As for the compiler if you have Xcode installed install the command line tools and you will be able to compile from the terminal.
    good luck

  • Compile and run java programs using batch file

    i am using eclipse to run my java programs.How to compile and run those programs using a batch file?

    a) just write a batch file, and add it to the project. When you want to run it, go to a command window and invoke it. (There is probably also a way to invoke it from Eclipse)
    b) if the project is complicated, take a look at ant. Eclispe knows about ant files.

  • Java.lang.NullPointerException when trying to compile

    Hi everybody!
    I'm trying to compile a file using javax.tools.JavaCompiler but I get a java.lang.NullPointerException when running the program.
    Here is my code:
    public boolean CompExecFile(File filename){
              boolean compRes = false;
              try {
                   System.out.println(filename.getAbsolutePath());
                   JavaCompiler compiler = ToolProvider.getSystemJavaCompiler();
                   StandardJavaFileManager fileManager = compiler.getStandardFileManager(null, null, null); //line where I get the error
                   Iterable<? extends JavaFileObject> compilationUnits2 = fileManager.getJavaFileObjects(filename);
                   compRes = compiler.getTask(null, fileManager, null, null, null, compilationUnits2).call();
                   fileManager.close();
                 if (compRes) {
                     System.out.println ("Compilation was successful");
                 } else {
                     System.out.println ("Compilation failed");
              } catch (IOException e) {
                   // TODO Auto-generated catch block
                   e.printStackTrace();
              return compRes;
         }There error on the line "StandardJavaFileManager fileManager = compiler.getStandardFileManager(null, null, null);":
    Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException+
    I've seen several examples using the parameters "null,null,null" but I don't know if it's good :(
    Many thanks for your help.

    I've found something which could maybe be what I need to do but I'm not sure:
    // Build a new ClassLoader using the given URLs, replace current Classloader
    ClassLoader oldCL = Thread.currentThread().getContextClassLoader();
    ClassLoader newCL = new URLClassLoader(myClasspathURLs, oldCL);
    Thread.currentThread().setContextClassLoader(newCL);
    System.out.println("Successfully replaced ClassLoader");
    Class fooClass = newCL.loadClass(appClass); //which replaces the line "Class<?> tempFileClass = Class.forName("TempFile");" ?!Is that what I need to do?
    EDIT: I've tried that but I still have the same problem:
                      File classFile = new File ("TempFile.class");
                      ClassLoader oldCL = Thread.currentThread().getContextClassLoader();
                      ClassLoader newCL = new URLClassLoader(new URL[] {classFile.toURL()}, oldCL);
                      Thread.currentThread().setContextClassLoader(newCL);
                      System.out.println("Successfully replaced ClassLoader");
                      Class tempFileClass = newCL.loadClass("TempFile");
                      Method main = tempFileClass.getMethod("main", String[].class);
                      main.invoke(null,new String[0]); Edited by: Foobrother on Jul 28, 2008 8:18 AM

  • Unable to run Servlet program using J2EE SDK

    Hello,
    i am a newbie to all this j2ee stuff and servlets even.so the problem that i have maybe a very common one and i hope that most of you may have a fix to it...
    i use J2EE SDK to compile and run Servlet programs.I have a Servlet program with the class name defined as
    public class MyServlet extends HttpServlet ....
    the file is stored as MyServlet.java
    i set the CLASSPATH variable so that the required classes for the compilation of the program can be located.
    the program compiles without any glitches.
    However when i run the program by saying
    java MyServlet
    ( i dont think its any different to run servlet code is it?)
    i get the message
    java.lang.NoClassDefFoundException:MyServlet
    Can someone suggest a remedy?
    thank you
    -NDK

    First, I don't understand what you are trying to do. Running a servlet ?
    Servlets are ran by an application server ! (Apache Tomcat ....).
    Second, is your class in any package ?

Maybe you are looking for

  • Accidentally deleted the Time Machine back up drive!

    After a hard drive faliure, I was trying to get my new hard drive ready to import from an external hard drive through Time Machine. In the process, I deleted my back up drive (the availble room is the same as hard drive's capacity). What I'm confused

  • Dreaded "must be configured to use a valid SSL cert" - 2008 R2

    Hello everybody, I've been browsing through hundreds of topics on the dreaded "The RD Gateway server must be configured to use a valid SSL certificate" error using BPA (Windows Server 2008 R2 Std), but still haven't found a proper solution. Here's th

  • MetaData Jco Connection without MsgSvr

    Hi all! I have again a problem setting up the Jco Connections for the WebDynpro tutorial. Now, I'm able to create a JcoConnection for the application data, but none for the MetaData, because the IDes, I want to connect to, is not installed with a mes

  • Overlapping of 1st & 2nd crowns of THAI characters

    Hi All, Overlapping of 1st & 2nd crowns of Thai characters after importing from .mif to FM8/9. If contents before the problem characters are edited (add/delete spacing of characters), the position of 2nd crown will appear correctly. PDF generated wil

  • Help! Touch tracker stopped working!

    Hello My touch tracker has stopped working on my Blackberry Curve 9300 3G I cant scroll or move round Can you help? Thanks