user32's Q&A profile
Visual Studio Team System Can anyone remove the workspace which created by Administrator?
I found that any users who can access the team project have the authority to remove the workspace which created by Administrator. How can I prevent this condition Many thanks! Any user with the "Administer Workspaces" permission can delete any workspace on the system, regardless of who created it. Have you perhaps granted your users this permission inadvertently Thanks, -Doug ...Show All
.NET Development How To Validate User Credentials on Microsoft Operating Systems
I would like to know if there is a good example in C# explain how To Validate User Credentials on Microsoft Operating Systems. I found this in C : http://support.microsoft.com/ id=180548#top I would like to use Win Forms to authentication and authorization user in Application server. How to do it Tks! Client ----> Connect - Application Server ----> Database server ok, but is there a way to use WindowsIdentity without call LogonUser() to get Token Because I know that LogonUser() api has restrictions ( win 2000 for example )... so... Is there another way to do : network authentication in .net // Call LogonUser to obtain a handle to an access token. bool ...Show All
Game Technologies: DirectX, XNA, XACT, etc. Geometry Instancing
Hi, I have to draw a lot of objects for a visualization and use geometry instancing for that the amount of objects I want to draw should be between 1000 and 20000. That works fine as I can construct all objects of a cubes with position, xyz-scale and color. The shader just calculates the color of the side of the cube considering one light source and ambient light. I got two questions of how and if I can even further improve the performance: 1. Is there a even more efficient way to draw these objects if all of them are static in position, size and color Only the camera moves around. 2. The objects are constructed of cubes, but I hope to simplify them more to reduce the amount of cubes to be drawn. Most of the objects look like a c ...Show All
Visual C# Is this code thread safe?
There is an example of code at MSDN ( http://msdn2.microsoft.com/en-us/library/ms228972.aspx ). It shows how to use asynchronous callbacks to handle asynchronous method calls. I've a couple of questions for the thread-guru types among you. First - is this code actually thread safe Given that there can be a multitude of DNS queries kicked off and running concurrently, is it possible for the asynchronous callbacks (ProcessDnsInformation) to preempt each other I'm assuming that the actual "work" is being done using the thread pool and multiple results can potentially happen concurrently. If this is the case, the (ArrayList)hostName.Add(...) calls are probably not safe - i think. Secondly - when you code followi ...Show All
Windows Forms why my custom uitypeeditor does no change my generated property value
i have a class that have some property when i edit them from property grid the uitypeeditor work but when i close the form in design mode and reopen it i see that all of change is lost , i see that changing that class property value from uitypeeditor does not change generated property value i want to see why and what should i do please help i search very long but cannot find the answer ...Show All
Software Development for Windows Vista Sate machine workflow
Hi, I have a simple state machine workflow with three states. I would like to put a timeout on the final state.(ie final state approver didn't approves this within the specified time, the state should go back to previous state). Is there any way to implement this thanks -Abraham Abraham - since each state can have multiple eventdriven activities - the way to implement this is to add an additional eventdriven to your final state - and then have a delay activity as the first activity inside of that eventdriven. ...Show All
SQL Server How not to cache in Lookups to Oracle
Why can you not turn off the caching in a Lookup against Oracle I have an exceedingly complicated SQL statement like this - SELECT OBJECT_ID, OBJECT_CODE FROM OBJECT_TABLE If I turn off the cache for a lookup I get bombarded with this rubbish- Error 8 Validation error. DFT Load STATUS: LKP Get RESULT_NO [128]: An OLE DB error has occurred. Error code: 0x80040E14. An OLE DB record is available. Source: "Microsoft OLE DB Provider for Oracle" Hresult: 0x80040E14 Description: "ORA-00933: SQL command not properly ended ". Update.dtsx 0 0 Error 9 Validation error. DFT Load DAY_STATUS: LKP Get RESULT_NO [128]: OLE DB error occurred while loading column metadata. Check SQLCommand and SqlCommandParam properties. Update.dtsx 0 0 ...Show All
Visual C# Byte Array size.
I'm sending a video frame from a server to a client. Now I know what size Byte array I should declare on the server side in which I'll store the picture and send it, however, I dont know what size array I should declare on the client side. Is there any way of finding out exactly how much data is coming in before i declare the array in which data will be stored It proving impossible to display that picture. One more thing, should i worry about the picture/frame header No Header is not a problem as far as you send complete bytes of image. Try this: Byte [] countbytes = new Byte [ 8]; int noofbytes = s.Read(countbytes, 0, countbytes.Length); long size = BitConverter .ToInt64(countbytes, 0); Byte ...Show All
.NET Development Data reader error
Dear All, I have a multiple number of reading done so for the first one I have actually done the reading and close the the reader. Then upon reading the second one I also have close the datareader. But when I run my third reader is gives me this error "There is already an open DataReader accosicated with this Connection which must be closed first.". I have even check using the method IsClosed for the first and second and both shows that is true. What is the possible error. I dont think so that I must open and close my connection always rite. Thanks for your kind replies Dear Indian Ocean, Yes from my debugging I realise that is where the problem exactly. So do u have ...Show All
Visual C# Converting System.Type to OleDbType
I can`t find class and methods that convert System.Type to any of dbtypes(OleDbType or SQLType). I know for the mapping tables, but I need conversion methods for all data providers(OleDb, SqlClient, ODBC) . It is not difficult to write that by your own, but I can`t belive that it is not alredy written by Microsoft. Why do you need this OleDbDataReader.Item and SqlDataReader.Item return an Object, just cast it to the native type: int count = (int)(dataReader["count"]); ...Show All
Visual Studio 2008 (Pre-release) Image Source property cannot be set from a binding
If I create a binding in code for an Image Source property like so Binding tmpBinding=new Binding("ImagePath"); tmpBinding.Source=ImagePathSource; image.SetBinding(Image.SourceProperty, tmpBinding); The image will not show. ImagePath is a property on ImagePathSource that points to a string containing the path to the image. I think the problem lies in the fact that in code the Path has to be escaped like so " RelativePath\\Image.gif " Within XAML if I create the image like so <Image Source="RelativePath\Image.gif"/> The Image will be displayed. Is there a workaround aside from creating the image in code it works for me < Grid Width = " 200 " Height = " 200 ...Show All
Visual Basic A question about the CheckedListBox.CheckedItemCollection
Hi, I would appreciate it if somebody could give me some insight to my question. What is the best (safest) way of saving a CheckedListBox.CheckedItemCollection outside of the created (and used) CheckListBox, such that, if the user clicks numerous Checkboxes and then clicks a "Cancel" button... the CheckedListBox.CheckedItemCollection will be repopulated with the checks that existed before the user made changes Also, please let me know if I have the wrong idea about how to go about finding a solution to this problem. Thank you! Hi, Thanks for your solution. Are there any classes that I can use instead of the Systems.Collection.Generic.List class supported in .NET Framework 1.1 I am developing on ...Show All
Visual Basic unsigned arithmetic operations in vb.net
Hi all, I would like to know how to perform an unsigned addition in vb.net 2003. Hi, The problem is that, in my application I would like to perform an addition of unsigned long numbers and perform a bitwise right shift operation. In vb.net 2005 it is possible and it has data types like ulong etc... But unfortunately I'm developing the application in vb.net 2003 and it does not recognize the ulong data type(System.UInt64) and is showing that + operator is not overloaded for System.UInt64 type. I would like to know whether there is any way to perform unsigned arithmetic operation in vb.net 2003. ...Show All
Windows Forms Event Handling for a Menustrip
I've create a menustrip with the code for it below. how to i create event handling for each of the items such as add and delete. Public Sub managerToolBar() food = New ToolStripMenuItem( "&Food" ) food.DropDownItems.Add( "&Add" ) MenuStrip1.Items.Add(food) End Sub How would i create a event handle for say if i click on Add to open another form Cheers for any help in advance Private Sub managerToolBar() Dim food As ToolStripMenuItem = New ToolStripMenuItem Dim addToolStripItem As ToolStripMenuItem = New ToolStripMenuItem( "&add" ) AddHandler addToolStripItem.Click, AddressOf Me .addToolStripItem ...Show All
SQL Server Problem in a QUERY with COUNT
CREATE PROCEDURE [dbo] . [GD_SP_HARDWARE_MONITOR_COUNT] -- Add the parameters for the stored procedure here @Direccao nvarchar ( 10 ) AS DECLARE @NrMon int BEGIN SELECT dbo . Monitor . MON_Monitor AS Item , COUNT (*) AS Unidades , dbo . Monitor . MON_CustoUnitario AS Total FROM dbo . HARDWARE INNER JOIN dbo . ADServico_User ON dbo . HARDWARE . UserID = dbo . ADServico_User . UserID INNER JOIN dbo . SERVICO ON dbo . ADServico_User . GrupoServico = dbo . SERVICO . S_GrupoServico INNER JOIN dbo . Monitor ON dbo . HARDWARE . MONITOR_ID = dbo . Monitor . MONITOR_ID WHERE ( dbo . HARDWARE . MONITOR_ID <> 5 ) GROUP BY dbo . Monitor . MON_Mon ...Show All
