Chris Calderon's Q&A profile
Visual Basic Hiding the hard disk
how do i hide the hard disks of the pc to prevent user's from accesing them using vb.2005 Hi, I reckon you would have to turn off the START MENU or / and HIDE the "MY COMPUTER" icon. Not sure how you would do it though. Trouble is other programs could still open a FileDialog box. Another thing is you could uncheck "Show Desktop Icons" in the same way as you would if you right-clicked on the desktop for that menu item. Again in code i wouldn't know how, sorry. Regards, S_DS ...Show All
Visual C++ problems with DirectX program
My DirectX program doesn't work. It gives me no errors, but if I run it, it gives me errors. What's wrong with it I do not write my mywin.h and basic.h here, because they are not important and work correctly. Procedures from those header files are Logi, MkWin and ReggWin and TPump, so do not be confused of them, just ignore them. My code is here: main.cpp: #define WIN32_LEAN_AND_MEAN #include <D3d9.h> #include "mywin.h" #include "basic.h" #pragma comment ( lib , "User32.lib" ) #pragma comment ( lib , "d3d9.lib" ) WNDPROC wndProc; HINSTANCE hInstance; HWND _hwnd; HRESULT hr; IDirect3D9 *g_D3D=NULL; ...Show All
SQL Server Problems with date formats
The date fromat in my country (Australia) is DMY. It seems to be quite difficult to prevent the month and day being swapped around. I had a case recently where we generating a list of dates to be presented in the report server UI (User Interface) as a list box for a parameter selection. We fixed the problem in the data set (on the data tab) by using "SET DateFormat DMY" only to find that the month and day were still swapped around in the UI list box. If this was just a presentation issue we could live with it but it turned out that the value read into the parameter was incorrect (the day and month were actually swapped). To fix the problem, we had to chnage the data type to VarChar() in the data set query, using Convert() to force ...Show All
Visual Basic Does killing a parent process have to kill the children?
I'm trying to start a process and have it run independently. I may just be dense, but it appears that it can't be done. When the process that issued the process.start() ends, the child process stops too. I tried this: prc.start() thread.sleep(T) ' 1000 < T < 20000 close() As soon as the sleep time elapses, the process started by the prc.start command stops. So how do I start an independent process that will persist after its parent shuts down ...Show All
.NET Development AD and NTFS permissions programming with VB and .Net
I'm using VB 2005 Express to read Active Directory permissions and NTFS permissions, but I need a bit of help interpreting it to display it in a format like the one used in the Security tab of the AD Users & Computers console. Can anyone recommend some good (and easy) reading to help explain AD and/or NTFS permissions programming using .NET Thanks, Iain ...Show All
Visual Basic Trouble with "ActiveWorkbook.Close SaveChanges:=False"
Hi I am having difficulty with the command "ActiveWorkbook.Close SaveChanges:=False" Running this command on my colleague's pc it works fine. Meaning that it closes the active workbook without saving any changes and without displaying any display alerts. Running the same code on my pc the command does not work and the display alert pops up asking me if I want to save the changes. Does any one know why this happens Thanks for the help! Dim Application As Excel.Application Dim Workbook As Excel.Workbook Dim Worksheet As Excel.Worksheet Application = CreateObject( "Excel.Application" ) Application.Visible = False Application.Disp ...Show All
SQL Server Unable to install SQl Server 2005 SP2 - Unexpected error
I am trying to install SQl Server 2005 SP2 but it was throwing an unexpected error when trying to install "setup support files". O/s: Windows Server 2003 SP1 Product: SQL Server 2005 Standard Edition Log file shows: +++++++++++++++++++ === Verbose logging started: 2/20/2007 16:05:42 Build type: SHIP UNICODE 3.01.4000.2435 Calling process: F:\SQL2005sp2\hotfix.exe === MSI (c) (74:68) [16:05:42:635]: Resetting cached policy values MSI (c) (74:68) [16:05:42:635]: Machine policy value 'Debug' is 0 MSI (c) (74:68) [16:05:42:635]: ******* RunEngine: ******* Product: C:\Program Files\Microsoft SQL Server\90\Setup Bootstrap\Cache\SQLSupport\x86\1033\SqlSupport.msi ******* Action: ******* CommandLine: ********** MSI ...Show All
Internet Explorer Development Internet Exploerer event model
Hi, I am looking for some information about how to catch events of Internet Explorer, for example I want to perform some action when new URL was entered. Best regards Roman. The only events exposed by Internet Explorer are exposed in the DWebBrowserEvents2 interface. http://msdn2.microsoft.com/en-us/library/ms850276.aspx If you are hoping to be notified on a character by character basis (such as when the user is typing, so as to control the autocomplete logic) you won't find any such event. However, IE starts a new navigation when the URL is entered , which triggers BeforeNavigate2 . You can respond to this event by performing some action with the URL (or Headers, PostData, Flags, and so on) or can ...Show All
SQL Server MSSQL Server 2005 Not Reporting Errors to Windows Event Log
Hello All, I just performed a fresh install of MSSQL 2005 Server Developer Edition on my XPSP2 machine along with MSSQL 2005 SP1 and I noticed that errors are not being reported in the Windows Event Viewer. Is there a way to enable/disable logging here I need to view these logs because when the tasks > 'copy database' task fails it submits its error in the Windows Event Log however since I reinstalled MSSQL 2005 these log entries don't appear here. thanks in advance. Interesting... I wonder why events don't show up in the Windows Event Log anymore Especially since MSSQL 2005 specifically says that it will make log entries in the Windows Event Log in the Copy Database task wizard. ...Show All
SQL Server composite stored procedure
Hi, I am trying to write a procedure in SQL which will composite values in a table. I have an increment list, which increments by 0.1, I need to average values so I produce composites for 0-1, 1-2 etc grouping by id. The script below produces a table then a procedure, but I'm stuck on the syntax and get the error Column 'Increment.increment' is invalid in the select list because it is not contained in either an aggregate function or the GROUP BY clause The script will run on the master database. The end result should look like the following: thanks for any help id inc_from inc_to comp_val ---------------------------------------------------- 1a 0 1 4.6 1a 1 2 4 1b 0 1 3.9 1b 1 2 ...Show All
SQL Server Clustered Indexes on Primary keys
All of the 3 books I've read say it is not a good idea to create a clustered index on the primary key but it is created as the default. My question is has this changed in 2005 My understanding is to create the clustered index on columns used first in join clauses and then in where clauses, what is the answer i have a couple of questions on this: 1 - what about an OLAP environment Actually, just a reporting environment - users connect with QA or other front ends. 2 - When would be a time to use a non-unique clustered index ...Show All
Smart Device Development Repeated Prompting at runtime: ENU-String Resource is already installed
When deploying a CSharp program on the Pocket PC 2003 emulator I keep getting prompted with the following message: "Microsoft .NET 1.0 ENU-String Resource is already installed. Re-install " After I click OK, the program runs as expected. This is with Visual Studio 2003 and the Pocket PC 2003 SDK. This started after a fresh install of VS 2003 and after I installed service pack 1 (of VS). This issue does not occur on other development machines. I've seem some articles that say to tell VS to stop deplying it as it is not needed. But, I can't find where to tell it to stop. Any help would be appreciated! Thanks! Hi Peter, why not trying to prevent the VS from installing the .NET CF runtimes ...Show All
Windows Forms Check box in datagrid.
Dear All, I have managed to create a column of check box in my datagrid. Now what I want to do is that upon selection of a number of checkboxes and when the user presses the delete key board button I want to do is to delete that particular rows which was selected. Can some one help me please I know is linking with some datagrid event but I dont know where to start and how Thanks. Hi sukbir, for(int i=0;i<datagridview1.rows.count;i++) { bool checked=(bool)datagridview1[checkedRow,i]; if(checked) //.. Do delete row.... } maybe this can help! ...Show All
Visual Studio Tools for Office Word Interop Hangs When Deployed To Server - Help!
Dear all, I have developed a method in C# which creates an instance of Word, adds a document, then populates the Word doc with some text. It then saves it, closes the doc and quits Word. Now this is the problem: The method works perfectly on the command line and through IE on my development machine (Win XP Pro, Office 2003) but it fails to work on the server (Windows 2000 Advanced Server, Office 2000) when called through IE (it works fine through the command line even on the server!) I can see (using ProcessExplorer) that the instance of Word is being created and is sub-process of svchost.exe and that the actual Word doc is also being created on the hard disk. However, the ...Show All
Visual C# Reading a PC game memory results
Hi! Im trying to lear how to read memory from a PC game that is running on my PC. The game is Football and would like to find a way to save the results in a XML file. Anybody know where i should start Or a good demo thank you That's going to be a pretty hard way to go about getting the game results. They don't get written out somewhere Anyway, this article might give you some tips, but it will only work if you can spawn the game process from within the app that wants to read the memory, and even if you can you'll have to be able to read assembler to figure out where the values you want are stored, and in what form. http://www.codeproject.com/csharp/minememoryreader.asp If it is a DirectX game ...Show All
