Jeph's Q&A profile
.NET Development Newbie (?) questions about C# from an intermediate-level programmer...
I'm reading (and re-reading) the book, Programming C# (4th edition) by O'Reilly. It's a really great book but I have a bunch of questions even after re-reading several parts of it. Here are my questions: 1. Static constructors are only guaranteed to start running before the first instance of your object is instantiated,so is it possible an object can be instantiated before the static constructor is finished running 2. Are constructors (static and non-static) and finalizers automatically thread-safe 3. Do objects with finalizers get garbage collected twice The book says objects with finalizers are put in a special queue when created but I'm confused because it seems like they get collected twice... (eg. first collection calls F ...Show All
Visual Studio Team System Team Build: Building solutions with code from multiple TFS projects?
Hi, We have an odd (and simple to answer I hope) question about using Team Build/MSBuild in our current environment. I have done the usual searches through MSDN and BLOGs without turning up anything that hints to a solution. We have recently migrated over the TFS and I have finally got around to implementing a build server but we have a few problems due to the way we structure our projects that stop us moving to Team Build for our nightly and CI builds. At the root of TFS source control we have a project for our common components (assemblies, web parts etc.) and then we have individual projects for each line of business app. This means the solutions we use end up with look a bit like the following… $/BusinessApp1/trunk/src/Soution1.sln Ins ...Show All
Visual Studio 2008 (Pre-release) Selecting .NET Framework 3.0 as prerequisite breaks Publish. Bug?
I have the following installed in my XP/SP2: .NET Framework 3.0 RC1 .NET Framework 3.0 SDK RC1 VS Extensions Orcas CTP I created a Windows Application and published it successfully. However, after I selected .NET Framework 3.0 in the Prerequisite dialog (it's not selected by default) I can't publish it anymore due to the following errors: C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Microsoft.Common.targets(3295,9): error MSB3141: No 'PublicKey' or 'Hash' attribute specified for file 'NETFX30\Dotnetfx3.exe' in item '.NET Framework 3.0'. C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Microsoft.Common.targets : warning MSB3164: No 'HomeSite' attribute has been provided for '.NET Framework 3.0', so the package will ...Show All
.NET Development Config File
Hi, I was wondering whats the best/easiest way to deal with a config file for your windows app (using C#). Basicly I'd like the user to save some values for when the run the app again. Any ideas/tutorials would be greatly appreciated. Thanks Use the built-in Settings functionality as described here Using Settings in C#. ...Show All
SQL Server please help before I kill myself over this problem...
have a report that takes 1 parameter on a report server. Trying to call the report using the reportviewer control All I want to do is set the report parameter in code. Dim rp = New Microsoft.Reporting.WinForms.ReportParameter rp.Name = "InvoiceNumber" rp.Values.Add( "0618050" ) Me .ReportViewer1.ServerReport.SetParameters(rp) Me .ReportViewer1.ShowParameterPrompts = False ReportViewer1.RefreshReport() This always fails. I can't figure out how to add the report parameter to the control. PLEASE save me. here is what I get in vb.net Dim salesOrderNumber As ReportParameter = New ReportParameter() salesOrderNumber.Name = "Inv ...Show All
SQL Server query large database
Hi, I have a very large table to query, it has 11 million rows because it is a detail one. When I try to query against the table it took approximate 9 minutes. Is there a way to make it more faster I've already use partition scheme and indexes but seems 9 minutes is the fast result. Thanks in advance. best regards, Hi, Sorry not to mention more deeper, I've applied the filter year(trx_date) = '2006' since the result should return by year. And 11 million rows that I mentioned before means all transaction in year 2006. I've applied index on trx_date field with noncluster option. Thanks in advance, best regards, ...Show All
Visual Basic Tips on Window Attributes (size, location, etc.)
So I have a program for my job that allows the user to open any number of individual windows that each display a customizable amount of data, type of data, etc. But that part's unimportant, the important thing is, unlimited windows are openable. The window attributes themselves are stored in a list of open windows. What I'd like to implement is the ability to choose some preset layouts. I know how I can programmatically create new windows, but my issue is arranging them. What do y'all suggest as the best way to do this, handling different screen resolutions and stuff like that A percentage of the user's screen width perhaps And do y'all have any methods to suggest using besides the normal setCoord, setWidth and setHeight ...Show All
Visual Studio Team System Enhancing LinksControl
Is it possible to enhance the LinksControl I would just love to be able to add State and Reason as columns to the LinksControl. Is this possible Dan is right, links control cannot be extended to show extra columns. In V1, a custom control can be built to show such columns. For next version, we do have capability to customize control to show additional columns. ...Show All
Visual Studio MSB3011 AL.exe
I was not sure where to post this but thought I would try here. What should I do to fix the following build error: C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Microsoft.Common.targets(1950,9): error MSB3011: "C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\AL.exe" was not found. Either 1) Install the .NET Framework SDK, which will install AL.exe. Or 2) Pass the correct location of AL.exe into the "ToolPath" parameter of the AL task. I installed .NET 2 and am not sure why this one project is in need of AL.exe - can I remove the dependency from the project Thank you, Brian I am also getting a similar error Error 8 "e:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\AL.e ...Show All
Visual Studio Express Editions How to add files from subdirectory? - How to save all items from listview?
Hello.I have a LISTVIEW in my app.I add .mp3 file in it with a FolderBrowserDialog.How I can add files from sub folders (for example: MyMusic -> Music 2006 -> May. How I can save all items from a listview in a textfile I'm not sure what you're problem might be with "SubFolder", I'm sure you can figure it out. To step through the items in the ListView, use code like this: For Each item As ListViewItem In ListView1.Items Next ...Show All
SQL Server Unload tape after backup maintenance plan
I have used google and searched these forums but haven't found an answer. Here is my problem: I have MS SQL 2005 DB I need to backup to tape daily. I want the tape to eject (or unload) when it is complete. I know how to do it with a manual backup (simply check off the option), but there aren't any options I can see with a Maintenance Plan backup. I would rather not do a manual backup EVERY DAY. I really don't understand why MS makes this so complicated...why would the option be in another area when you use a maintenance plan Thanks for replys!!! In order to have that level of control over the backup task, you need to take control of the T-SQL yourself. The best way to do that is to create a new TSQL ...Show All
Microsoft ISV Community Center Forums Select with macro based on criteria
Hi, I am a newbie trying to self teach VB. I am pretty useless so please be gentle. I am trying to write a macro to allow me to select text in MS Word based upon its case. I want to select all the text in the document that is in all caps. Is this possible Also, is it possible to exclude 34 specific two letter strings of text The reason for this that specific "class codes" need to appear in in caps. Can anyone help As i said, i am pretty useless at this stage, so sample code would be awsome. Josha Write a line in you document for example Hello this is MYSELF writing this and then run this little piece of code Sub test() For Each wrd In ThisDocument.Words teststr = ...Show All
SQL Server Thats the code i used
hi, i want to know how to do that: table: costtypes fields : typecode values: amount, vat, duty, table bills: fields: billid, costtype, amount value bi1 amount 1000 bi1 vat 10 bi2 amount 200 i need to create a view that will display amount, vat, duty as fields. note that these are values in the table. so that i will have billid amount vat duty bi1 ...Show All
Visual Studio Express Editions How do I delete or remove projects and files from visual C++ express Edition
How do I delete or remove projects and files from visual C++ express Edition This is how you Remove project files: C:\Documents and Settings\User Name\My Documents\Visual Studio 2005\Projects Delete the Folders there that you dont need and then just open your Visual Studio and Click on the Deleted names. and it will ask you to Remove the Reference say yes And you Finde registry at: [HKEY_CURRENT_USER\Software\Microsoft\VCExpress\8.0\FileMRUList] ...Show All
Windows Live Developer Forums Wrap Text
Can anyone tell me (newb) how to wrap the text round a pic in a pushpin popup At the moment the text comes after the pic and takes up alot of space Heres my current pushpin text: var veSouthwell = new VELatLong(53.077269761289195, -0.9560036659240723); var veSouthwellDetails = "<img src='../images/minsterextweb.jpg'><br>With its imposing Norman Minster, literary and historical connections and its famous Bramley Apple, Southwell is a place you will want to return to again and again."; var veSouthwellPin = new VEPushpin('Southwell', veSouthwell, '../images/icontowntour.gif', 'Southwell', veSouthwellDetails); vemap.AddPushpin(veSouthwellPin); Thanks Thanks John for your t ...Show All
