ivanchain's Q&A profile
.NET Development How to read the record data (byte array) while writing a Metafile (WMF/EMF) and edit it
Hi! Need your ideas urgently! I have a metafile which I wish to convert to PDF on the fly. The idea is to create a metafile template with placeholder text, which will be parsed and replaced by user information at runtime before generating the PDF. When editing the metafile, I have progressed to the following steps: 1. Called the Graphics.EnumerateMetaFile() method, which calls the callback method (lets call it ‘Play’) 2. Called the callback method and obtain the record data public bool Play( EmfPlusRecordType recordType, int flags, int datasize, IntPtr data, PlayRecordCallback callback) { byte [] dataArray = null ; if (data != IntPtr .Zero) { dataArray = ne ...Show All
Visual Studio 2008 (Pre-release) Window not attached to rest of the xaml, scale/anchor elements in window
Hi, i have a window that i want to resize and some elements are anchored and some elements that scale according to the window. I have made a test project in expression Blend that works fine, but when i added the xaml code to my c# project i doesnt work anymore. this is probably because of the way i load the xaml code. I got a frame that contains the top, bottom and a center dockpanel. In the Center dockpanel i load a other xaml source into it. None of the xaml sources got a codebehind files, i got 1 class for all the xaml sources. This class inherage for Window and i add the xaml elements to that window, i think this might be the problem. Or can the problem be that i load a namespace into the window that already got namespace I must have n ...Show All
Visual Studio Team System Default database collation options
When using the Project creation wizard, in the Build and Deploy dialog, there is a dropdown to specify the Default Deployment collation. There are three options : Change source db collation Change target db collation Use existing collations I would like to know which collations are used when appling each of the above options. Please could somebody explain what these options mean. What does it mean to change the source collation What does it mean to use existing collations, since surely the target db will have the same collation as the project What is being referred to by "Source" and "Target" Jean-Pierre - What version of Team Edition for Database Professionals are you using In the released pr ...Show All
Software Development for Windows Vista The referenced component 'Outlook' could not be found.
Hi, I am trying to run the Human Workflow sample "Simple Human workflow" I am getting the following Build error for namespace "Microsoft.Office.Interop.Outlook". The type or namespace name "Interop" does not exist in the namespace "Microsoft.Office". I have added a reference for Microsoft Outlook 11.0 Object Library from COM tab. But it is adding with a yellow mark to the reference list. Can anybody please suggest me in working with this sample and how to give reference of Outlook. Thank you in advance. ...Show All
SQL Server customize template.ini to upgrade from msde to express edition?
I need to create the script to upgrade the current named instance of sql 2000 desktop engine to sql server 2005 express edition. I am having difficulty preparing the template.ini and would appreciate help. [Options] INSTANCENAME=MY_INSTANCE SQLBROWSERACCOUNT=NT AUTHORITY\NETWORK SERVICE SECURITYMODE=SQL SAPWD=music UPGRADE=SQL_Engine SQLBROWSERAUTOSTART=1 RSCANINSTALLDEFAULT=0 RSCONFIGURATION=FilesOnly RSSQLLOCAL=0 I get an error that this file is invalid..Any clues I am trying to upgrade existing instance of msde 2k to sql express 2005 and uses sql authentication http://www.microsoft.com/sql/editions/express/upgrade.mspx http://www.microsoft.com/technet/prodtechnol/sql/2005/msde2sqlexpress.ms ...Show All
Visual Studio Express Editions WinFX-WPF Screensaver
I am a beginner at C#, and want to make a screensaver in WPF. Has anyone got any tips on how to code a screensaver that would work on multiple screen resolutions (scaling, but keeping aspect ratio) Or does anyone know where I can get sample code for this Hi mrmckeb, Have a look at http://www.netfx3.com/ this is the home of the whole .Net3.0 (formaly WinFX). Hope this helps Scott ...Show All
Windows Forms can't retrievethe connectionstring from the app.config file
Hey can please somebody help me!!! i added the following code to the app.config file <connectionstrings> <add name="connectionstring" connectionstring ="valid connection string" /> <connectionstring /> in visual studio 2005 i use the following code i'm using c# using (SqlConnection con = new SqlConnection( configurationManager.connectionstrings(connectionstring)); but i'm getting a error which actually i don't really understand Hi, VS allows declare a property for a connection string into the app.config file. Only assign a name for the property and choose (Connection string) value from the combobox at the column Type. Later in your code ...Show All
Software Development for Windows Vista Winhelp on Windows Vista
Hi, Does anyone know if the user downloadable winhelp engine be available for the Vista Launch date It is posted on MSDN that winhelp is being deprecated. This is talked about here http://msdn.microsoft.com/library/default.asp url=/library/en-us/dnlong/html/AppComp.asp In the compatibility risks section. I have seen it recommended that ISVs move to html based help. ...Show All
Visual Basic save file on another have the same name :"overwrite"
hi : how can i save file overwrite on the another have the same name thanks but actualy i use this code to save image files and open it again Declare Auto Function BitBlt Lib "GDI32.DLL" ( _ ByVal hdcDest As IntPtr, _ ByVal nXDest As Integer, _ ByVal nYDest As Integer, _ ByVal nWidth As Integer, _ ByVal nHeight As Integer, _ ByVal hdcSrc As IntPtr, _ ByVal nXSrc As Integer, _ ByVal nYSrc As Integer, _ ByVal dwRop As Int32) As Boolean ' use this to save Public Sub save_Pic(ByVal zPanel As Panel, ByVal FilePath As String) ' Create graphics objects to work with Dim gfx1 As Graphics = zPanel.CreateGraphics Dim gfx2 As Graphics = Nothing ' Try Dim cu ...Show All
.NET Development How to get versions of services/programs running on another system?
Hi, I want to get the versions of the services/programs running on another system. Does any body have any idea as to how it can be done.I thought of using SNMP.However I am not sure of how to use it thanks in advance, nhd Nope. WMi components are installed from Add and remove programs. After that, it's all about queries. The query I sent will run without any additional configuration after the WMI is installed. I haven't double checked on the version part though. Are you trying to find the file version of the service running ...Show All
Visual Studio Express Editions Uncle! Renaming Selected Files in a FileListBox...
I've combed through help and these forums but have not yet found a workable answer... I've built a little widget that will rename all the files in a FileListBox (this was converted from its original version in VB6); The function I'd like to add is to be able to rename selected files, as opposed to "all" or certain filetypes, or extensions ... can anyone point the way on this Thanks. Really rather simple The following code has a listbox and a button, the listbox is set to multi select and the following code will iterate through the selected items doing a rename. Obviously you change modify it to allow the extensions, folders to be set through the use of other controls setting variable. Option Compare Text Public C ...Show All
.NET Development Create a Shell Extension Handler thumbnail extractor with .net?
Hi, My application creates nice graphics see http:// www.mavericksplan.com/mavericks and it saves a custom document type. I'd like to show the contet of the document in Explorer when the user switch to Thumbnail view. To implement this feature I understand I need to create a Shell Extension Handler Thumbnail Extractor that extract the image from my file type to feed Explorer thumbnail vew, which is not easy at all for me. I look on the web and I found 1 C++ example and none in C#. Does anybody have a sample code to create a Shell Extension Handler thumbnail extractor with .net in C# Thank you Andrea Unfortunately unmanaged C++ is really the only way to go here. Writing in-proce ...Show All
.NET Development Decimal - trig and power support for System.Decimal?
I want to ask when support for System.Decimal might be expanded Specifically, it'd be nice if the power function and trig functions of System.Math would natively support System.Decimal (a big change from not at all). This has been done in some commercial and non-commercial libraries, so it is do-able. I really need the extra Accuracy and Precision afforded, but cannot sacrifice the power and trig functions. IEEE 754 revision one link to check out would be http://www2.hursley.ibm.com/decimal/ I'm sorry, I don't think we'll ever agree on this. Adding support for complex numbers would be quite defendable too. If not more, there's (arg ...Show All
SQL Server Merge Replication-Apply BCP files
How can i apply a BCP files generate by Distributor in the Suscribers. I don’t know wich parameters BCP.EXE need. Thanks I need to manually apply because there is few information, and i've configured suscription with the option to no send the schema tables. I've configured the replication via internet (is slow for a very large tables) But now i need to send data to the suscribers. Thanks ...Show All
SQL Server export to excel
I'm experiencing an issue where when I export my report to excel every number in my report exports as something other than a number. Every number excel field (cell) has a green arrow in the upper left corner which will allow me to manually convert to a number but this is a major hassle. I've tried converting the fields in the report using cdbl and cdec but to no avail. Anyone have a suggestion on how to fix this Thanks The FormatNumber function always returns a String. See this doc page for reference: http://msdn2.microsoft.com/en-us/library/xfta99yt.aspx If you want to add number formatting and retain the original numeric data type, you should define the formatting in RDL. Open the properties window for the ...Show All
