Paul Tew's Q&A profile
.NET Development how to convert string to char array
hi all ! how can we convert character array to a string and also vice versa Hi , Instead of posting very basic questions like this , u better refer any book(C# programing - wrox is good one).Even if you google for this u'll get the code. Hope , u got me. Anyways code for ur requirement: --------------------------------------------------------- String str = "hello" ; //String to char array char [] szArr = str.ToCharArray(); //Char Array to string String str2 = new String (szArr); -------------------------------------------------------- Thanx & Regards, Ch.T.Gopi Kumar. ...Show All
Visual Studio Team System Version Control on documents
Is there "version control" available for the documents that published to the project portal The versioning of the portal docs is not setup by default. To version the documents you have to modify the Document Library(s) that you want to have the documents versioned in. You set it up as follows: Access the portal home page Click on the document library that you want to version Once in the library click the last link on the left side in the Quick Launch "Modify columns and settings" Once in the Modify settings page, look for the link "Change General settings" it should be near the top. Click that link to enter the default settings page and look for the option to V ...Show All
Visual C++ Problem of ActiveX
When I am trying to call an ActiveX's method in my MFC application, it displays a dialog on the top of my application properly. But before it ends, the OS displays a dialog, which says "Another application is running, switch to ...". If I try to switch to others, everything is OK, my application continues to run. Could you tell me how I can avoid displaying the annoying dialog Why Thanks in advance. Depens on the IMessageFilter that is used. If the application waits forever than such a dialog will not appear. Afaik the defualt settings in an MFC application is 3 seconds after no response. Maybe VB disables its main window automagically. ...Show All
Software Development for Windows Vista Unidentifed program wants access
I am testing the installation and running of a vb6 program. The program installs okay. The program is signed with a test certificate created using makecert/cert2spc/signcode. It requires administrative access when it is run and this is stipulated in it's manifest. I have put the Root Agency into the Trusted Root Authorities Store and put the publisher/signer into the Trusted Publishers Store. I have 2 problems. 1. When the program is run it displays the "unidentified program wants access" dialog with "unidentified publisher". Shouldn't this be an elevation dialog with the publisher's details shown 2. When the program is run "as administrator" the same unidentified program displays ...Show All
SQL Server Multiple Notification instances with a single database
I am attempting to create multiple Notifications instances, however, without the additional databases. I want to be able to have multiple instances use the same single NSMain and Application database. I've been successful at creating a single NSMain database for multiple instances by adding the following line in the InstanceConfig.xml: <NotificationServicesInstance xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://www.microsoft.com/MicrosoftNotificationServices/ConfigurationFileSchema"> <Database> <DatabaseName>HRMS_NotificationsNSMain</DatabaseName> <SchemaName>%NSMAINSchemaName%</SchemaName> </Database ...Show All
Game Technologies: DirectX, XNA, XACT, etc. JIT register allocation and bounds checking
A few questions for Shawn or one of his buddies: 1/ Does the register allocator used in the XBox JITter use all of the available scalar floating point registers If not, how many can it deal with 2/ Does the XBox VM ever skip array bounds checking, and if so under what conditions 3/ Presumably there are no bounds checks when using unsafe code and pointers 4/ Are the method inlining limitations of the CF VM mentioned here still applicable to the XBox VM - especially the one about not inlining any method with floating point arguments or return values (yikes, that would be all floating point setters and getters!) Andy. Ryan, I'm sorry that you feel so upset that I said I found your pos ...Show All
SQL Server Running sp_blocker_pss80 under SQL2005 and SQL 2000 shows many spids have non zero waittype under 2005
I was trying to test sp_blocker_pss80 (and SHERLOCK) on an SQL 2005 system and noticed that it gave much more output than on an SQL 2000 system . This was because the waittypes of many spids were not zero while under SQL 2000 the same ones were zero. Why is that For instance here is the subset of the query which is part of the sp_blocker_pss80 run on an sql2005 and sql2000 respectively select spid, status, blocked, open_tran, waittype, waittime, cmd, lastwaittype from master..sysprocesses SQL 2005 spid status blocked open_tran waittype waittime cmd lastwaittype ------ ------------------------------ ------- --------- -------- -------------------- ---------------- -------------------------------- 1 background ...Show All
Visual Basic How to get hold of the linenumber of the line where an error occurred
Hi. I have tried ( in vain ), when executing the VB executable, to find out how to show the line number of the error that occurs. I can access the line number when I'm in the VB IDE environment, but not when I run the executable. Below is the code I use to access the line number ( I also tried lo_stacktrace.ToString(), but again the line number did not show when I ran the executable ) This leads me to the question: Is it at all possible to access the line number when the executable is run Private Function CodeRef( ByVal po_ModInfo As t_ModInfo _ , ByVal po_ex As Exception _ , ByVal pb_ReturnSource As Boolean _ , ByVal pl_FrameNo As Long _ ) As String Dim lo_stackframe As Stac ...Show All
Visual Basic DateTimePicker & Person's Age
I want to show someone's age on a label (how many years and months he's old) based on what birth date he picks. how can i do that you get the date they entered you get the current date (DateTime.Now) subtract the values via the TimeSpan.... Dim diff as TimeSpan = DateTime.Now - UserInputDate Dim theDate as new DateTime(diff.Ticks) MessageBox.Show(theDate.ToString("dd MMM yyyy")) does this work for you ...Show All
Gadgets addImageObject image shifts when you change its size
In the following example, the image shifts down and right - as if it's being scaled from the bottom right corner. I used an image 1024x768 pixels in size. gadget.html element: <g:background id="bodyBackground" src="blank.png" style="width:100%; height:100%;" /> code to add the image: bodyImage = bodyBackground.addImageObject("test.jpg", 0, 0); The image is now situated at 0,0. But, if you then change the width/height: bodyImage.width=300; bodyImage.height=300; The image is now situated at around 400, 400 - not 0, 0 as it should be. EDIT: How to work around this problem: The problem The image is offset by half the difference between the original image width/height and the scaled image width/height. So we need to get the or ...Show All
Visual Studio Team System MS Project and TFS questions
Here are some more issues that my client has encountered while using MS Project with TFS. Are there any work arounds 1. TFS seems unable to deal with special characters such as brackets ' [' e.g. Smith, John [ABC Company]. When synchronizing Project after making changes on TFS, it doesn seem to be ok with special characters like commas and parentheses ',' and '(' e.g. Smith, John (JohnSmith) 2. When changes are made to Remaining Work and completed work, how does MS Project interpret those updates It seems that the finish dates are dependent on the values entered in TFS. There is no easy way to 'approve' the changes before the update is done ( like with PWA). Thanks, Kathir. We have been able to get the download from Micr ...Show All
SQL Server CONNECTING TO ACCESS DATA via SQL Server Managemnt Studio
HI All, forgive me but I am new to SQL Server. My question is in 2 parts. THe first - Could anyone point me to a tutorial or give me a quick pointer I want to View my Access 2003 datatables through Server MAngement Studio. I cannot however work this out or find articles on it. Is it possible Are there any wlakthroughs The second Part - Eventually I want to create an SQL database, which is comprised of tables which use (point to) MS ACCESS as there datasource. An unchangeable existing piece of software uses Access as the UI, so I want to leave my data in access, and just set up some pointers from the SQL database tables to read in data from these access tables as when required. Is that a clear question Am I making any sense PLe ...Show All
Game Technologies: DirectX, XNA, XACT, etc. Matrix.Shadow is gone
Looks like Matrix.Shadow was removed. It was useful in assisting with simple shadow creation. Is there an alternative in XNA or do I need to do the math myself Why not write a simple utility function Build your matrix like this: P = normalize(Plane); L = Light; d = dot(P, L) P.a * L.x + d P.a * L.y P.a * L.z P.a * L.w P.b * L.x P.b * L.y + d P.b * L.z P.b * L.w P.c * L.x P.c * L.y P.c * L.z + d P.c * L.w P.d * L.x P.d * L.y P.d * L.z P.d * L.w + d If the light's w-component is 0, the ray from the origin to the light represents a directional light. If it is 1, the light is a point light. ...Show All
Software Development for Windows Vista MS .NET SDK *.img download - install problems
Running XP2 I burned 6.0.6000.0.0.WindowsSDK_Vista_rtm.DVD.Rel.img as an .iso onto a DVD but under XP2. All I can see is one file ReadMe.T which says This disc contains a "UDF" file system and requires an operating system that supports the ISO-13346 "UDF" file system specification. I tryed ISOBuster, MagicISO, Nero Backup, DeepBurner and other tools to get a DVD created but to no avail. I also tryed coversion from *.img to a *.iso format file to no avail. This identical problem happend to other SDK users in the last (October) release. Same problem set but for this current release. I have some suggestions to the MS SDK release team. [1] Release an *.iso image not a *.img file (recent tools will work wit ...Show All
Visual C++ Erase background of a particular region
My problem is that I have handled the OnEraseBackground method to avoid flicker in my animation. But now I want to be able to erase the background of a particular region so that it is refreshed. How do I do that Rahul The generic solution is to do your erasing and painting into an in-memory bitmap, then BitBlt the bitmap to the screen in the OnPaint method... ...Show All
