Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  1. ern297

    code not administrate

    Hi, I've the next problem. I need to use a function from one old library in a member function of a administrate class. When I try to use #include "myFunctions.h" I recive a lot of errors as 'IServiceProvider': ambiguous symbol. I'm lost. Can Anybody help me? Thanks.
  2. ern297

    Problems with the dataset

    You have myDataColumn.DataType = Type.GetType("System.In32"); and you need "System.Int32". I hope this help.
  3. ern297

    Hi, I have the next function in an

    Hi, I have the next function in an old dll. myType function(unsigned long *var1, unsigned long var2, wchar_t *var3); I want to export this function to C#, and I try the next [DllImport("myLib.dll", EntryPoint="function")] public static extern myType myNewFunction(ref uint...
  4. ern297

    New type of data.

    The sentence byte(8) var2; isn't correct in C#. Do you know how can I get this array with dimension 8? (if it's possible, without use the constructor). Thanks.
  5. ern297

    New type of data.

    Ok, I understand all that theory, but I have the next in C++ /******/ typedef struct { int var1; byte var2[8]; char *pVar3; } myStruct; void myFunction(myStruct var1, int var 2, etc...) /******/ How can I define this structure in C#?. I use [DllImport(...)] for import the function...
  6. ern297

    Reading Cell data from a windows.form Datagrid

    Have you tried this? yourDG[yourDG.CurrentRowIndex,"ColumnName"].ToString() I hope this help you, (-: Ernesto .
  7. ern297

    New type of data.

    I think that this is the correct way, but I don't understand very well the MSDN examples. I only want to do something as typedef MY_INT int; Could you help me with any example? Thanks, Ernesto.
  8. ern297

    New type of data.

    How can I define a new type of data? Sorry if the ask is a bit silly but I came of C++ and I don't know which is the equivalent of 'typedef'.
  9. ern297

    Namespace Question

    I forgot that you must have a reference to this library
  10. ern297

    Namespace Question

    Lets say you declare "Using Modules.AdsManager.File" in your code, it means that you should have "yourLibrary.dll" available at the same directory as you build it, where the library must have namespace "Modules.AdsManager.File" I hope that this can help you.
  11. ern297

    dll problems

    Thanks for everything, but finally I have obtained it! This is the 'winner code': [DllImport("myLib.dll", EntryPoint="theFunction")] public static extern TYPE_ENUM myFunction( [MarshalAs(UnmanagedType.U4)]ref uint var1, [MarshalAs(UnmanagedType.U4)]uint var2...
  12. ern297

    dll problems

    I've rewrite my DLL to: [DllImport("myDll.dll", EntryPoint="theFunction")] public static extern type_enum myFunction( [MarshalAs(UnmanagedType.U8)]ref ulong var1, [MarshalAs(UnmanagedType.U8)]ulong var2, [MarshalAs(UnmanagedType.LPWStr)]ref char var3); I don't pass any...
  13. ern297

    dll problems

    I am trying to reuse in C# one function written in Visual C++ 6.0 that is in a DLL. Function has the following head: type_enum name_function( unsigned long *var1, unsigned long var2, wchar_t *var3); I am trying to use the following thing, but it does not work...

Part and Inventory Search

Back
Top