JCollins's Q&A profile
.NET Development unable to load dll using PInvoke
Hi, I am having a problem trying to load a dll. I have an external peice of hardware called the MTC Express. It comes with a API in dll format. Im using PInvoke to try to call function in the dll from my c# application. My code looks like this. [ DllImport ( "C:\\ttxmtc.dll" , EntryPoint = "MTC_GetAPIVersion" )] public static extern bool MTC_GetAPIVersion( char [] buf); public static void Main() { char [] buffer = new char [128]; bool b = MTC_GetAPIVersion(buffer); } When I call GetAPIVersion, I get the error Unable to load DLL 'C:\ttxmtc.dll': A dynamic link library (DLL) initialization routine failed. (Exception from HRESULT: 0x8007045A) I've r ...Show All
Visual C# Hi!! again i have a problem here ,,,,i have hexadecimal saved in file...now i want ....
Hi.. now plz read carefully......i have a hexadecimal text file.such as file.txt saved on disk..... so format of the hexadecimal stored is.....1a 2a 14 01 3d 23 45 12 2c 1c 3a remember there is space between every hexadecimal .. i want to read this file of hexadecimal as follows: i want the when this file is read ,,first it should be stored in array see follows example. array[0] = 1a2a , array[1] = 1401 , array [2] = 3d23 ,array[3] = 4512, array [4] = 2c1c.... very important see that at every array position u have read two hexa decimals...at one array position stored it,,, now these hexa decimal has been read from file and stored in a array,,,, seconldy i want that array should be of integer,,,means the ab ...Show All
SQL Server Copying database using "Copy Database" - still failing after SP2
I am struggling with the "Copy Database Wizard" in SQL Server 2005. I am used to working with DTS to copy data from one server to another, but with the new tools, I am having serious problems (in fact, it's unusable) 1. When copying a database using the "SQL Management Object" method, I always get errors concerning logins. If I select not to copy logins, I get errors "sp_grantdbaccess failed". If I do select to copy logins, the logins can't be created because the machine names are different (one the source machine, the login is called MACHINE1/mylogin, but on the destination machine, such a login cannot be created) 2. For small databases, I ALWAYS get the error "CREATE DATABASE failed. Primary file must be at least 3 MB to accommodat ...Show All
Windows Live Developer Forums Contacts not adding suddenly...
Basily what the title says. i've been using live for a long time now with no issues thus far. however now all of a sudden, its giving me all kinds of issues adding people to my contact list. i add them, yet the "request" isn't going through to them on their side... any idea why this is happening no more then 2 weeks ago i've added multiple contacts with no issues, however anyone i've tried to add within the last week or so hasn't worked. i went back to msn 7.5 untill i fully understand this situation thanks a lot. rob Same problem here. The problem has just manifested itself in the past coupe of weeks. Maybe some weird server problem with not refreshing or something. Im goin to get back to 7.5 be ...Show All
Visual Basic Ping web address
is there a way to ping a web address like using a command prompt. I am developing a small app to ping our local network and to ping our website that is hosted on an outside server to detect where a connection problem is. I can take care of the inhouse ping, but I am not sure of how to approach the website. Davis Learning yes...use the ping class in the system.net.networkinformation namespace: http://msdn2.microsoft.com/en-us/library/a63bsyf0.aspx ...Show All
Game Technologies: DirectX, XNA, XACT, etc. GraphicsStream.InternalDataPointer null?
Good day, We are creating a texture from a bitmap region using an unsafe section in C#, but occasionally the InternalDataPointer for the GraphicsStream's returned from Texture.LockRectangle will be null. Following are the relevant lines: Texture texture = new Texture (device, bitmap.Width, bitmap.Height, 1, Usage .Dynamic, Format .A8R8G8B8, Pool .Default); int pitch; GraphicsStream graphicsStream = texture.LockRectangle(0, LockFlags .None, out pitch); unsafe { byte * to = ( byte *)graphicsStream.InternalDataPointer; ... It is a multi-threaded app, but to our knowledge no other thread acts on these members. What could cause a null InternalDataPointer Thanks in advance... ...Show All
Windows Forms textBox Question
is there a way to allow only ' a-z A-Z 0-9 ][{}()-* ' characters to be typed into a normal textBox the MaskedTextBox wont work in the way that i want it too. Im using VC++ 2005 thanks even better i will send my error report... ------ Build started: Project: test, Configuration: Debug Win32 ------ Compiling... test.cpp c:\documents and settings\dion1\my documents\visual studio 2005\projects\test\test\Form1.h(2955) : error C2018: unknown character '0x40' c:\documents and settings\dion1\my documents\visual studio 2005\projects\test\test\Form1.h(2955) : warning C4129: ']' : unrecognized character escape sequence c:\documents and settings\dion1\my documents\visual studio 2005\projects\test\test\Form1.h(2955) : warning C4129: '[' : unrecog ...Show All
SQL Server sql server lockup after strange error in log, help please.
Can anyone help me solve why my server is locking up. We're running sql server 2005 ent on a 2 cpu dual core server. With 3gig. Once each the last couple weeks, the machine has hung and the only thing I can find that's suspicious is on the sql server log. It's below. After the excerpt is about 50 more different memory errors. As far as I know there's no ssl configured for log in, it mostly uses private lan cards for security between it and the web/application server. 05/31/2006 14:39:48,spid2s,Unknown,MEMORYCLERK_SQLQUERYEXEC (Total) <nl/> VM Reserved = 0 KB <nl/> VM Committed = 0 KB <nl/> AWE Allocated = 0 KB <nl/> SM Reserved = 0 KB <nl/> SM Committe ...Show All
Visual Studio Can the debugger be used to step through a guidance package?
I have a few random questions - any help is appreciated. Note the general sense of frustration. Is it possible to use the debugger to step through a Guidance Package while it creates a solution Is there documentation, other than the chm file (note: this should include a how-to) What is the sequence of how code is executed when a solution is created from a package How does one interpret the below Action < Action Name = " ExportSolutionTemplateRef " Type = " RefCreator " AssetName = " ExportSolutionTemplate " ReferenceType = " Microsoft.Practices.SoftwareFactories.ServiceFactory.References.SolutionPropertiesReference, Microsoft.Practices.SoftwareFactories.ServiceFactory & ...Show All
Visual Studio 2008 (Pre-release) why the image don't render
I study a Master-detail application from the post Master-detail scenario . The ContentControl show the image of the object. The image don't render if i set the imageSource to inexistent image.But when i selectd the item which has a existent image ,it also don't render .... why xaml: <CollectionViewSource Source="{Binding Source={StaticResource planets}}" x:Key="cvs" /> <local:StringToImageSourceConverter x:Key="stringToImageSource" /> <DataTemplate x:Key="detailTemplate"> <Image Source="{Binding XPath=Image, Converter={StaticResource stringToImageSource} }" /> </DataTemplate> ........ ........ <!-- master --> <Lis ...Show All
SharePoint Products and Technologies Custom Site column Column using Feature in MOSS
if any one know how to create custom column using "Feature" feature of MOSS for the "Image" type the following is the code for creating custom site column for "Choice" Type column Feature.xml: < xml version="1.0" encoding="utf-8" > <Feature Id="CA7BD552-10B1-4563-85B9-5ED1D39C073B" Title="myField" Description="asdf" Version="2.0.0.0" Scope="Site" xmlns="http://schemas.microsoft.com/sharepoint/"> <ElementManifests> <ElementManifest Location="testing.xml"/> </ElementManifests> </Feature> and following is testing.xml < xml version="1.0" encoding="utf-8" & ...Show All
Windows Forms Console Output from a Windows Form
I have a windows form program which also includes a command line interface to a few of its features. When command line options are pased to the program the GUI is not displayed, and the command line code is properly excuted. However none of the output to the console appears. I was able to get the console output to be displayed by having Visual Studio 2005 compile my program as a console app instead of a windows app, but this causes a console window to be opened when you run just the GUI portion of the program. Is there anyway I can get the console output to appear without having this console window opened with my program when running the GUI part may be not related directly to your question but look at ...Show All
Visual Studio Express Editions VWD 2005 Express
After installing VWD 2005 Express, I get the following every time I start Word or Excel 2003: Please wait while Windows Visual Web Developer 2005 Express Edition - ENU Then: The feature you are trying to use is on a network resource that is unavailable. Click OK to try again, or enter an alternate path to a folder containing the installation package 'VNSSetup.msi' in the box below. If I point to the file, it tries to install something but it still comes up every time I start Word or Excel. What is it trying to install Any ideas how to get rid of this if this can help to solve the problem : I have the same error, when lanching MS Project the Application event logger says : Type de l'evenement ...Show All
Smart Device Development how to send sms through GSM network sim to bulk mobile no.
Iam new to mobile developement, mytaskis to send sms to my customers in periodic basis, can any help me in this issue. regards, Keshav Send SMS from what Server Device ...Show All
SQL Server Errors with combined use of transactional and merge replication - SQL2005
I am investigating the feasibility of a configuration with 3 databases on SQL2005 DB_A is an OLTP database and serves up transactional publication pub_txn - with updateable subscriptions DB_B is a subscriber database which subscribes to pub_txn DB_B is also a publisher which serves up merge publication pub_merge DB_C is a subscriber database which pulls pub_merge =============================== Updates on DB_A are successfully replicated to DB_B Howvever, when DB_C pulls updates, it doesn't find the update sent to DB_B =============================== Updates on DB_B are successfully replicated to both DB_A and DB_C =============================== Updates on DB_C initially failed with the error Msg 916, L ...Show All
