hrd2hndl67's Q&A profile
.NET Development EventLog errors due to events being written whilst I'm reading them
Overview: I get runtime errors using the .NET EventLog class in very simple traversal, due to event entries being written and overwritten while I'm reading the log. How should I as a developer use this class to query a live event log How do you avoid or handle the exceptions which the simple foreach EventLogEntry iterator throws as things change I want to read all the events in a particular log, which are newer than a certain date. Originally I tried this for (int i=eventLog.Entries.Count-1; i>=0; --i) { EventLogEntry entry = eventLog.Entries ; if (entry.TimeWritten < cutoffTime) return; /* record stuff */ } When I got sporadic errors with that, because of event log entries being written and overw ...Show All
Software Development for Windows Vista Endless state workflow, performance problem, Very common problem in real system
We use state WF to handle our order processing. Usually an order has 5 states: (1)Script (2)Approved (3)shipping (4)Closed (5)Canceled The following actions move the state transforming between the above states. Approve (1) a (2); undo approve (2) a (1);Cancel (1),(2) a (5); close (2),(3) a closed; undo close (4) a (3) Let’s have a look at action “undo close”. It exists in a real world system. Because user some time still need undo-close an closed order to ship again. (Maybe because he just regret). My question is: which one is completed state of this workflow (4) Closed or (5) Canceled It seems there are no completed state of this workflow. If so ,when can I delete the persistence state If I set closed-state( ...Show All
Game Technologies: DirectX, XNA, XACT, etc. need help please - newbie
Hai everyone, I want to start 3d game developement.Can you please suggest a site that has a complete tutorial on devloping games using visual c#.It must start from a beginners level an should provide details on shaders and maps. the directx sdk has starter projects in it. Check under <sdk>\Samplers\Managed\Direct3D\Tutorials also http://www.mdxinfo.com/tutorials.php for other great managed directx stuff :) ...Show All
Visual Studio 2008 (Pre-release) calling WCF service from non executable assembly??
Is it possible to call a WCF service from a non-executable assembly, let us say a dll I created a new WCF service, generated the proxy using svcutil.exe. Then created a class library project and added the proxy and config files to the project. Now I'm trying to call the WCF service but after I create an object for my WCF class, visual studio does not show any intellisense and I'm not able to call WCF service. I then created a console application and added the proxy and config files to that project. And I can successfully call the service from there (and visual studio shows intellisense). Please help. Nikhil Did you add the config settings to the confiuration file for the executable using your li ...Show All
Game Technologies: DirectX, XNA, XACT, etc. Sprite is not transparent
Ok I finally got the game to work but I have a new problem...my texture which I made transparent in DirectX, doesn't have the transparent background when I run it. Is this due to my graphics card & me adding that line of code to make the program work Sorry I can't remember the exact line but it's been floating around the forums, I think we all know what it is. I've read that bmp files created in Paint with magenta backgrounds(255r, 255g, 0b) are automatically transparent as magenta is ignored by the renderer. I haven't tested that yet. I've used very simple single color images so far so it has been easy to create the image, then create a mask image by reversing the colors and combining the two with ...Show All
Visual Studio Express Editions How to make a connection to the SQL Server 2005?
Hello guys, I have a question that I want you guys to answer. I have a system that use the SQL Server 2005 Database. What I want to know is how I want to make a connection to the SQL Server 2005. Before this I have been using VB 6.0 but now with VB Express 2005, the connection is differ from the last version so I hope you guys will help me. Remember that when using the Express editions the system can only connect to a local install of SQL Server Express installed as a named Instance ".\SQLEXPRESS" (This is the default install for the SQL Express System). By this I mean that it will only conect to the DB Using the wizards. If you do wish to connect to another database you will first need to make sure that the ...Show All
SQL Server Export problem and formatting in Excel
I have a report that uses a recursive hierarchie to display companies and affiliates. e.g.... Company Affiliate Affilate Affilate Company Affilate Etc... I am using the following expression to indent (left padding) the affiliates: =Convert.ToString(2 + (Level()*10)) & "pt" This formatting does not appear to export to Excel. Is this by design or am I doing something wrong Additionally I can toggle the vilibility of the affiliates however this does not export to excel either. Hi Jason. I'm glad to hear you found an acceptable workaround. The behavior you reported is due to a product issue. Padding is not done correctly with the Excel renderer. We will be fixing this in a f ...Show All
Software Development for Windows Vista Japanese IME does not work properly with MultiUI
My program does not work properly on Windows Vista Japanese. It's using IME functions. You can recreate same problem with MultiUI sample program which is provided by Microsoft. You can see this problem with following instruction: 1. Compile and run MultiUI It's in: http://msdn.microsoft.com/library/default.asp url=/library/en-us/vcsample98/html/vcsmpmultiui.asp 2. MultiUI has 6 input area, turn on Japanese IME on right-middle and left-middle input area. 3. Click left-middle input area, type "ai" and press Space key twice to display candidate window 4. Click right-middle input area, type "ie" and press Space key twice to display candidate window 5. Click left-middle input area, candidate window is displaye ...Show All
Visual Studio Problem when Transform All Templates (Family Tree Walkthrough)
Hi All, I'm Herru and I'm totally a beginner with DSL and VS.NET2005. I had installed SDK Sep 2006, and VS.NET2005 in my computer. I was trying to follow the family tree walkthrough in September 2006 Help. But when I wanted to Transform All Templates after update the Toolbox definition, an error occured. It said: There were validating errors. Continuing to save bla..bla... First I just continued, then I got XML view. But I cannot open the digram anymore. When I Transform All Templates again it showed this error: "Ambigous moniker 'Test.FamilyTree.FamilyHasPeople/.FamilyMember' encountered. It is used for both 'Family' and 'FamilyMember'.". I tried to redo the steps all over again. But still I got the same error. Could an ...Show All
Commerce Server associates Tags To products
Hello Does any one have a suggestion on How to create Tags in commerse server and associate them to a product The Tag need to be multiValue (each producr in a specific category can have more than one tag). The Tag also need to be multilingual Thanks Arik You can create multi value (it's called Multiple Choice) properties for Catalogs. Look into the schema manager by creating a multi value peroperty then associate it to a product definition. You can only have one tag per product. You can also create a property and call it tags which is a comma dilimeted list (just make sure that you spell it correctly in every product) then do a like search. Doing like searches can be a perf hit on SQL. You could enable ...Show All
Visual C# PathGradientBrush and the OutofMemory Exception
I've recently been using the PathGradientBrush at work, and I've found that when it goes to create a new instance it throws an OutOfMemoryException every time. I've tried a clean reboot and it still does it, I've tried making sure barely anything is in memory and it still does it. The worst of it is, I've tried to execute the same code on my home PC and it works fine. Anyone got any ideas as to what might be causing the OutOfMemoryException at work I don't know why the same code should work at home, but I have had a similar problem (OutOfMemoryException) when trying to instantiate a LinearGradientBrush. It only happened when I passed a 'non-gradient' to the constructor. The constructor I used wants ...Show All
SQL Server Problem appending to a raw file
I have subscription records for five different magazine titles that i process by looping each one though a dataflow using a for-each loop. I am using the following instructions to append to the raw file: http://blogs.conchango.com/jamiethomson/archive/2005/12/01/2443.aspx This works fine when I pass four different magazine titles. when i try to run all of the titles(five), i get the following errors: [Raw File Destination [131195]] Warning: The parameter is incorrect. [DTS.Pipeline] Error: component "Raw File Destination" (131195) failed the pre-execute phase and returned error code 0x80070057. Any ideas Thanks. Frank I guess my first avenue of investigation would be to identi ...Show All
Visual Studio Report layout and Chart Properites
I am currently creating a line graph report with the x-axis being the date and the Y axis being the number of visits per page. The chart is showing dates from the time of the website went into production last year until today. The report is generated every day - so it becomes longer and longer. My question is this: Is their any way to make the labels on the x-axis show just every other day In the X-Axis chat properties, I can click on numberic or time-scale values, whoever it defaults into only showing the labels for every 13 days. Is their a way to change this to have it show a label for every other day Please read the "Chart labels" topic of the following whitepaper: http://msdn2.micros ...Show All
SQL Server cannot copy sqlexpress to another pc for vb.net 2.0 project update
Hi. I have done alot of searching around but can't find answer to this specific problem. Here is my connection string in vb.net app config <connectionStrings> <add name="myfile.My.MySettings.ffgscrmConnectionString" connectionString="Data Source=.\SQLEXPRESS;AttachDbFilename=|DataDirectory|\myfile.mdf;Integrated Security=True;Connect Timeout=30;User Instance=True" providerName="System.Data.SqlClient" /> </connectionStrings> The database is locally attached to the vb.net project residing in a data directory in the project. I am testing installation on a virtual pc - with no sql express managment or other sql server databases attached. When I do a vb.net setup project and run this ...Show All
SQL Server External documentation
I know that the BI studio can build a nice flow document that is associated with the package. Is there an easy way to build a series fo documents that can be shared with other users without having them go into Visual Studio Mark E. Johnson The DTS documenter was there for a while: http://www.softrus.org/dts/ And I got a note that SSIS Documenter is coming from these guys as well. ...Show All
