Brian Driscoll's Q&A profile
SQL Server shrinking a file
I am trying to use the command DBCC SHRINKFILE to shrink a database. the command seems to be executing just fine, but the database does not shrink. I don't see any error messages under messages. The .mdf file is currently about 7GB, which of which only about 1 GB is actually being used . I want to shrink the .mdf to about a 2GB. Why does the DBCC shrinkfile command not working Which exact command did you use Jens K. Suessmeyer. --- http://www.sqlserver2005.de --- ...Show All
.NET Development Is it possible to create a RSACryptoServiceProvider from existing private key?
Hi, If I already have a private key and public key used before, is there any chance to create a RSACryptoServiceProvider directly based on them For example like RSACryptoServiceProvider(privatekey, publickey) or just RSACryptoServiceProvider(privatekey) Many Thanks ...Show All
SQL Server accessing result of sp_tables
When I run exec sp_tables it give me a "list" of tables in databases. In fact the result is a table where one of the columns contains the database table names. It is no problem to access it in a client application but I need to access that column and verify existance of a certain table in SQL Server's user stored procedure . So far anything I tried did not work. FETCH pertains to a cursor and I cannot declare a cursor for this command. The only thing I got so far was @@ROWCOUNT but it is of no use for me. Perhaps there is another way to verify if a table exists from inside a stored procedure . I have the same problem in terms of verifying existence of a user stored procedure from inside another user stored procedure but if I g ...Show All
Visual Studio Installation Error.
Can't this company make software that just installs as it should Why am I getting the founding error when installing the trail version of Visual Studio Pro 2005 Error 1406. Could not write value to key \Software\Classes\.xsd\OpenWithList\devenv.exe. Verify that you have sufficient access to that key, or contact your support personnel. All other programs WERE closed and my anti-virus WAS disabled Mike I found a bug in the Visual Studio 2005 Pro install. This directory path 'vs' does not work. I had to change it to 'Visual Stuido 2005 Professional Edition - ENU' after I extracted the install to a directory. I hope someone from Microsoft sees this posting and fixes the install. ...Show All
Visual Studio Team System Schema Compare issue
Have an issue with schema compare. When I do a compare I have objects the tool is saying does not exits in the target but it is exactly that same based on Ultra Edit compare. I let DBPRO update the target and then do a refresh I get the same object back as not in the target schema. Comparing a database as the source and the database project as the target. Has anyone run into this issue What type of objects are giving your problems The database project handles some objects differently and because of this, we can't compare them. Anything that is defined in a pre or post deployment script is not compared when comparing a database to a database project, so those objects will show ...Show All
Visual C# C# tooltips work only when app launched from Visual Studio Debugger
Basically, thats it. I have tool tips set on various controls and the tips work as advertised as long as Im running under the debugger (F5). Running under the IDE without the debugger (ctrl-F5) shows no tooltips. Building release & debug: both show no tooltips. Executed on another machine no tooltips. SPY shows WM_MOUSEHOVER being received by the controls. Do I ship my app with instruction to run it under the debugger : ) Thanks for any better ideas:))! yes, doesn't matter which machine I use to build the project or run the code on. However, a simple test form with a single button works fine in all cases. seems like maybe a general, high-level thing... ...Show All
SQL Server shrink my backup device
does this Delete/Remove DATABASE ***** FROM backupdevice WITH FILE = 1(2,3) can working thanks check this it may help you http://forums.microsoft.com/MSDN/ShowPost.aspx PostID=889290&SiteID=1 ...Show All
.NET Development Reading a XML file...
I have some problems learning how to navegate throught the xml file i have... I need to read all the information at once and i cant do it, because the Structure of my Xml file contain some nested nodes and i dont know how to do that... this is an example of what i have. <Root> <Element Nbr = "1"> <Item ID = "566"> <Color>Blue</Color> <Size>8</Size> <Itemchild> 0...N Elements (Nodes) with more elements and atributes... </itemchild> </Item> </Element> <Element Nbr = "2"> ... </Element> </Root> So i dont know how many Itemchild's would be, thats why i need to loop trought them, at sam ...Show All
Visual Studio Either Crystal Report Problem or Visual Team Problem ( Legend TExt )
I have gone through each and every thread of crystal report XI and VS 2005 and it seems like that no one has the answer of how to change the text of legend, if a report is tied to DATA SETS. Please respond as I have waisted almost a month in resolving this issue. If this is not the Microsoft problem then I ll ask Crystal Report to look into this problem. Any help is appreciated. Thanks Hey, I've run into the same problem myself. I see it's been over two months since your post - have you come up with a solution Thanks, Mark ...Show All
.NET Development Context.User.Identity.Name is null
I have a webservice that has a method that uses Context.User.Identity.Name as the parameter. For some reason it is null. In IIS for directory settings, I have annonymous and integrated windows authentication checked. I have read where I should uncheck annonymous access, but when I do that, I get an exception "The request failed with HTTP status 401: Access Denied". When I call the web service, what credentials are being used In my web.config file of my web service the authorization node has no child nodes. Thanks in advance Yes uncheck anonymous in IIS. Otherwise it will always be anonymous and Identity.Name will be null Then in your proxyclass generated by VS, set the crendentials to the currently logged in user: Dim ...Show All
Windows Forms Suppressing Checkboxes for some nodes in a TreeView
The web version of the TreeNode class has a ShowCheckBox property. The Windows version does not. Is there a workaround to hiding checkboxes for some items in a TreeView I need to suppress showing the checkbox for the root nodes in the tree. Thanks, Paul Whitaker Technically, it is possible by setting the DrawMode to OwnerDrawAll. Practically, it is not; you have to draw the nodes as well as the checkboxes, a large undertaking. As an alternative, consider using the checkbox for the parent node to indicate the state of the child nodes. A tri-state checkbox would be useful for this, check out this project . ...Show All
Software Development for Windows Vista FreeformActivityDesigner and Connectors question...
Hi! I am hosting a FreeformActivityDesigner in my app which works really great. I can drag my custom shapes onto the design surface and drag Connectors between them. But i'm unable to find out how I can delete a Connector on a key press (I know how to actually delete it but I can't figure out how to listen for a key press when the Connector is selected)... I tried to override FreeformActivityDesigner.CreateConnector to supply my own connector class derived from Connector but the Connector class doesn't have any events to listen for key presses... If I override FreeformActivityDesigner.OnKeyDown, my override method is only called if the design surface itself is selected and it's not called if a Connector is selected. How can ...Show All
Visual C++ error LNK2019: unresolved external symbol _main referenced in function __tmainCRTStartup
When I try to compile with VS2005 enabling unicode support I get that error. // standard windows headers #define _WIN32_WINNT 0x0400 #define WIN32_LEAN_AND_MEAN #include <windows.h> #include <tchar.h> #include "strconv.h" extern int utf8_main(int argc, char **argv); //============================================================ // main //============================================================ #ifdef __GNUC__ int main(int argc, char **a_argv) #else // !__GNUC__ int _tmain(int argc, TCHAR **argv) #endif // __GNUC__ { int i, rc; char **utf8_argv; #ifdef __GNUC__ TCHAR **argv; #ifdef UNICODE // MinGW doesn't support wmain() directly, so we have to jump through some hoops extern void __wgetmainar ...Show All
.NET Development How to keep a thread running?
Hi, I have the following issue and the odd part about is that I had it already working however I don't know what I changed that it doesn't anymore. I runtime compile a class, create an instance of it and init it on a different thread. In this init the class subscribes to a couple data dispatchers and should now wait for incoming data. When I first implemented this it kept running after I subscribed to the dispatchers until I aborted the thread. However, now it subscribes and after that exits the thread. Any idea how I can keep it running without putting it in a wait loop Thanks, Tom Hi, thanks for your replies. You are right Peter, however, I don't really know which other info would be helpful What I'd l ...Show All
Windows Forms Wrappers for Windows Shell
Hello, Are there classes in .NET that provide Shell functions I need to make use of Recycle Bin functions. If not, it'd be a nice addition - I'd think it'd be useful to sizeable group of users Windows Forms/.NET. Thanks for the answer and the links. Also wanted to comment that they (.NET wrappers for Shell) would be a useful addition to Windows Forms/BCL. ...Show All
