Marcin Belczewski's Q&A profile
Visual J# Problem with C++/CLI and J# interaction bug
I'm having a problem with C++/CLI and J#. I am writing a class library in C++/CLI and want to use it from J#. I narrowed down my code and wrote a repro: a.cpp: #using <mscorlib.dll> #include <stdio.h> using namespace System; namespace AA { public ref class A { public : unsigned long Print() { printf( "Hello\n" ); return 0; } }; } b.jsl: import System.*; import AA.*; public class Test { public static void main( String [] args) { A a = new A(); a.Print(); } } To compile do: cl /clr /O2 /MD /c a.cpp link /dll /out:a.dll a.obj mt -outputresource:a.dll;#2 -manifest a.dll.manifest vjc /out:b.exe b.jsl /reference:a.dl ...Show All
Windows Forms The located assembly's manifest definition does not match the assembly reference.
When I try to run a "click once" application I get: System.IO.FileLoadException: Could not load file or assembly 'Scientia.Allocator, Version=1.0.2041.18670, Culture=neutral, PublicKeyToken=b8e96a1701695563' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040) File name: 'Scientia.Allocator, Version=1.0.2041.18670, Culture=neutral, PublicKeyToken=b8e96a1701695563' None of my assemblies are in the gac. Help!! (I would have hoped that as the same the "click once" deployment was built this sort of thing would have been checked for.) ...Show All
Visual Basic Visual Basic and graphics - for the novice/beginner
Hi there I have no training in programming, but would like to start writing my own little programmes. In my work (civil engineer), I am increasingly frustrated by the lack of simple, time saving programmes to make my life easier, and hence the urge to write my own programmes. Of course, the start will be no more than programmes for one-off formulas, but having said that, I would like to (in many year's time) be able to write more complicated programmes. And of course what I have in mind involves graphics, specifically being able to draw (for instance) pipelines (with coordinates) and then be able to generate a longitudinal section from th ...Show All
Windows Forms Node Dragging. Please Help!! SO NOBODY KNOWS IF IT IS POSSIBLE?
Hello, Is it possible, while dragging a node in a treeview, instead of highlighting a drop node, but to display the insert line between the nodes (just like in your favourites menu in explorer) where the node will be inserted Please let me know. Thank you. If you owner draw your nodes you could put the line along the top or bottom edge of the node you are over, depending on the Y position of the mouse within the node. ...Show All
Windows Forms Databind the selected row in a DataGridView
Hi All, I wonder if it's possible to databind the selected row of a datagridview to a business object. (like it's possible with a dropdownlist) I use a datagridview to let the user select the right product to purchase. Now I put the selected row on the SelectionChanged Event in my object, but I don't like this to much... Any suggestions Thanks, Simon Did you remeber to change the Selection mode to FullRowSelect Try this if not we will continune from there since i just did this in work today Itzik Katzav ...Show All
.NET Development Is it true usernametoken can't be used in webservice tht is invoked by web client?
This is my Web service Client. The filename is MathService.apsx. I use web client to invoke my web service.The coding is below: Public Class Math Inherits System.Web.UI.Page Dim obj As New LoginForm Public Token As UsernameToken = Nothing Private Sub cmdAdd_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles cmdAdd.Click Dim aa As String Dim bb As String aa = "hcti" bb = "ching123" Dim proxy As New SimpleMathWse Token = New UsernameToken(aa, bb, PasswordOption.SendPlainText) proxy.RequestSoapContext.Security.Tokens.Add(Token) Dim iOp1 As Integer Dim iOp2 As Integer Dim iResult As Integer iOp1 = ...Show All
Windows Forms Schemas for .application and .manifest files?
Are there physical XML schema files for the deployment and manifest XML files generated by VS. NET I can't seem to find them on the file system. I did however find a few schemas as an embedded resources in System.Deployment. Are these the schemas for the ClickOnce deployment files manifest.2.0.0.13-pre.adaptive.xsd manifest.2.0.0.13-pre.adaptive_elements.xsd manifest.2.0.0.13-pre.xsd They lo ...Show All
Visual Basic Form Design Goes Blank when switching between code and design?
Hi, I am running the release version of VS 2005 Professional. I have noticed a really annoying problem. I am developing a SDI application using a tab control to provide access to multiple pages that allow the user to input data. There are 5 tab pages and they have approximately 30 or 40 controls on each (labels and textboxes mostly and usually a single ListView, 3 command buttons and 3 or 4 drop downs). I often switch back and forth between the code window and the design window and most times I do this the design window goes white and the cursor is not busy but there is a delay of about 15 or 20 seconds before the design win ...Show All
Visual Studio Reverse Engineering – Auto Display Class Associations
When you reverse engineer a project, i.e. show the class diagram, the inheritance tree is presented but class associations are not. It appears that you have to right click on the member variable or property within a class and indicate that you would like to show the association. Is there any way to have all associations shown automatically Wow this is awesome, just what I was looking for. Thanks very much. ...Show All
Visual FoxPro COM server problem
I have a VFP6 project that when compiled worked great as a DLL lookup on an included table. As I no longer have access to VFP6 and the table needed updating, I tried to test out VFP9 with this project. It builds to the DLL with no errors but when I tried to register it, I got the dreaded message" DllRegisterServer in ....failed. Return code was: 0x80004005". I used Dependency Walker to profile this dll and got the following results: GetProcAddress(0x7C800000 [KERNEL32.DLL], "FlsAlloc") called from "MSVCR71.DLL" at address 0x7C341950 and returned NULL. Error: The specified procedure could not be found (127 ...Show All
Smart Device Development GPS sample and Windows Mobile 2005
hi, i found the GPS example on the SDK for Pocket pc for C#. i have no problem deploying it in my pocket pc - MDA PRO. but when i select menu item 'Start gps' it only says 'StartingUp' and does nothing else. my PocketPC is already paired with the GPS receiver. will really appreciate if anyone can help me with this. will also appreciate if anyone can point to some other sample example to connect to bluetooth gps receivers. regards, rnv Have you gone into the GPS Settings applet, and set up the COM port that your Bluetooth GPS is connected to ...Show All
SQL Server SQL Server 2005 Express CPU usage too high??
I have a website with about 130,000 page views per day, I'm using a P4 2.8G/1GB RAM dedicated server for database. When I upgraded my database to SQL Server 2005 Express, I noticed the CPU usage goes too high, sometimes the CPU usage goes to 100%. My database table only has about 25K records. My questions is how to optimize my database Is there any tips to do that start by getting a trace profile to see which statements are taking up the most time in terms of Duration, CPU and Reads. Then look at the plan. ...Show All
Visual Studio Express Editions Help a Beginner
I cannot understand why the following code does not show label1.text until the copy has comleted. It then shows label1.tex t= "All Copied" I am expecting "Please wait" until the copy is complete. Any help appreciated Private Sub Button1_Click( ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Dim pathtobackup As String Dim datenow As String Label1.Visible = True datenow = (Format(Now, "dddd, d MMM yyyy" )) 'Backup MyDocuments Folder then MyFavourites Label1.Text = "Please Wait" pathtobackup = "D:\b ...Show All
Visual Studio Team System IDE Attempted to read or write protected memory
I am seeing these errors frequently with VS 2005 RC1. I do not recognize any pattern that causes the errors, but I am going to guess that it is somehow related to aborted a debugging session on a webtest because that is what I was just now doing when I got the errors. --------------------------- Microsoft Visual Studio --------------------------- Attempted to read or write protected memory. This is often an indication that other memory is corrupt. --------------------------- OK --------------------------- followed by: --------------------------- Microsoft Visual Studio --------------------------- Unspecified error -------------- ...Show All
.NET Development Where is the asp.net forum?
i have not found it. jledgard wrote: Check out this thread: http://forums.microsoft.com/forums/ShowPost.aspx PostID=391 for the answer and corresponding discussion. The short version is that they still live on the http://www.asp.net/Forums/ site. I am very sad by this answer. Some we want a ASP.NET Forum within Microsoft Forums, please. Javier Luna http://guydotnetxmlwebservices.blogspot.com/ ...Show All
