Qiuwei's Q&A profile
Visual Studio Express Editions Filtering words from read out ASX file in a listbox
Hello all, My problem is this: I read out an asx file (a playlist file) into a listbox. Now my problem is the whole asx file is being read out there and I only want the file names to be seen there, my code is this so far: string file = fileListBox1.SelectedItem.ToString(); StreamReader re = File.OpenText(file); string input = null; while ((input = re.ReadLine()) != null) { listBox1.Items.Add(input); } It works fine, but the output of that listbox is: <asx version="3"> <Entry> <ref href = "C:\filename.mp3" </Entry> </asx> Each of these lines is a seperate selectable thing in the listbox, but I want it to show like this: filename.mp3 So that you can s ...Show All
SQL Server SQL Server 2005 - Log Shipping - Missing sp_change_primary_role and sp_change_secondary_role
I have installed SQL Server 2005 and setup a cluster and log shipping. I decided to perform a planned failover and realized that there are no sp_change_primary_role and sp_change_secondary_role stored procedures. I checked on both the SQL Server 2005 installations and could not find them. My question is : "Is it safe to get these stored procedures from a SQL Server 2000 database and run them on the SQL Server 2005 database " "Has anyone come across such missing stored procedures in SQL Server 2005 and know the reason why it is so (so that I can avoid it in the future if it due to a faulty installation) " Cheers NEVILLE GEORGE In SQL 2005 BOL, there is a topic on changing r ...Show All
Visual Studio Render .rdlc to PDF without Report Viewer control
Hi, I'm rendering an rdlc directly to a PDF without using the Report Viewer control. I'm using code similar to that already posted on this forum for printing without the Report Viewer. Essentially I'm after an example whereby I can configure the datasource information programatically based on however many datasets I have in my report. So in the code below, I need to modify LoadSalesData() so that rather than use an xml file, look to see what datasets are in my .rdlc, populate them and then add them to my report. private void Run() { LocalReport report = new LocalReport(); report.ReportPath = "Report.rdlc"; report.DataSources.Add(new ReportDataSource("Sales", LoadSalesData())); private DataTable L ...Show All
SQL Server Merge Join vs. Lookup vs. Custom Script - which is fastest?
Very often we have 50'000+ rows which you need to pull values from different source (e.g. CityNames from citycode in Excel file). Currently we are using Lookup - but the questions is which of those 3 options is best in performance wise TheViewMaster wrote: Very often we have 50'000+ rows which you need to pull values from different source (e.g. CityNames from citycode in Excel file). Currently we are using Lookup - but the questions is which of those 3 options is best in performance wise Only you can answer that question. test and measure test and measure, test and emasure. -Jamie ...Show All
SQL Server Lookup Transformation
Is there a way to ignore the unmatched rows using Lookup without creating another destination (Error Transformation for red connector) shafiqm wrote: Is there a way to ignore the unmatched rows using Lookup without creating another destination (Error Transformation for red connector) Yes, Just use 'Ignore failure' in the error output...the unmatched rows will go into the green output having null in the looup columns ...Show All
Visual Basic container controls indices
Coming back to coding after a long time off... And using the Shelley Cashman VB.Net book ... I've got some radio buttons called radAnswer in a control called grpAnswer. The commented code (one line) is supposed to do what the Select does do. But the grpAnswer.Controls indexing isn't what it should be. I thought the tab index property of the radio buttons might do it, but no. How do I set each radAnswer to it's proper place in the controls array TIA For shrIndex = 0 To 3 'grpAnswer.Controls(shrIndex).Text = gstrQuestions(shrQuestion, shrIndex) Select Case shrIndex Case 0 radAnswer1.Text = gstrQuestions(shrQuestion, shrIndex) Case 1 radAnswer2.Text = gstrQuestions(shrQuestion, shrIndex) Case ...Show All
Smart Device Development Windows Mobile 5.0 Developer Resource Kit
Windows Mobile 5.0 Developer Resource Kit is available for Order. Please see http://msdn.microsoft.com/mobility/windowsmobile/howto/resourcekit/default.aspx What's inside the kit Tools and Technologies Visual Studio 2005 Professional Edition (90-day trial)* Windows Mobile 5.0 SDKs for Pocket PC and Smartphone ActiveSync 4.1 .NET Compact Framework 2.0 Localized emulator images and other useful developer tools SQL Server 2005 Mobile Edition Developer Resources Links to technical whitepapers and webcasts WeFly247-50 sample applications Hands-on labs and videos Partnering opportunities Hi, I have just download it. Do I need full install it if I has have Visua ...Show All
Visual C# How do I limit ticks is a checkListBox to one at a time?
Hi, I am trying to use a checkListBox to select one of three options. I only want any one option at a time. I have found the following 2 instructions, which, I would have thought, would have done what I want, but I can still check all three boxes. this .checkedListBox1.CheckOnClick = true ; this .checkedListBox1.SelectionMode = System.Windows.Forms. SelectionMode .One; Incidentally, I tried this .checkedListBox1.CheckOnClick = true ; this .checkedListBox1.SelectionMode = System.Windows.Forms. SelectionMode .None; and this did whatI expected, I could not check any of the boxes. So, any one know what I am doing wrong Many thanks for being there John. You can iterate ...Show All
SQL Server Handling errors returned by SSRS
We are displaying the report in our reporting application but we do not want to display errors from SSRS to the user. We want to handle the errors and display a user friendly message. How can that be done . We are making URL access to the report server. Thanks. Hi, I have my report viewer control and reporterror event to handel all the exception.Do we need to call the reporterror event in my code or automatically it will be called when error occurs Thanks, Ranjan ...Show All
Visual Studio Team System CodePlex and Source Control Issue
Hi, I have had no problems with the VS2005 plugin integration, have been able to add, check-out, check-in, etc, until today. I accessed another solution from a local (LAN) VSS database, which I have since closed. And now when I connect to CodePlex project, I can see the project including loading the Source Control Explorer, but right clicking on ANY folder or file pops up a context menu saying "No commands available", and the entire SCE toolbar is also disabled. How do I re-enable the menu items I'm assuming the Source Control plug-in is pointing to the local VSS database instead of the TFS plugin. How do I change that Bit of extra info... the files I'm working on are CodeSmith template files and are th ...Show All
Visual Studio Team System Special character woes
I have a custom task that returns a string with some special characters in it (i.e. * and ;) as Output. If I just print out the output in a Message task after returning from my custom task it prints just great. For example: D:\MSBuild Examples\Chapter02\MSBuild1\MSBuild1\**\AssemblyInfo.cs;D:\MSBuild Examples\Chapter02\MSBuild1\MSBuild1\SubProject\ClassLibrary\**\AssemblyInfo.cs However if I turn around ant try to use that same output string (as returned from the task) as an Include in a CreateItem task like so: < CreateItem Include = " $(MyOutputString) " > < Output ItemName = " myItem " TaskParameter = " Include " /> </ CreateItem > and then print out the created item in a message like so: ...Show All
Game Technologies: DirectX, XNA, XACT, etc. Visual C# Express gotcha
I am used to full blown Visual Studio 2005 but I decided that I'd play with Visual C# Express so I could better get a feel for that IDE since this is the environment for XNA Express. Just so you all know, when you create a project in C# Express it doesn't get saved to disk until you explicitly tell it to save or close the project. Amazingly even if you compile and run the new project it still won't be saved to disk. The upshot of this is that if the IDE crashes or gets terminated unexpectedly there doesn't seem to be any way to recover the project or the files you were editing. Twice I ended up losing the entire project I was working on because of this. I searched the entire disk to try and find my files and couldn't. The workarou ...Show All
SQL Server I couldn't find TRIM function
Hi, I found rtrim and ltrim functions, but I didn't find trim, so should I use rtrim(ltrim(' a ' )) Am I right cheers, Alessandro Camargo ...Show All
Windows Forms progress bar not working
Hi I have a button on a form...From the buttons click event loads another form that displays SQL data. This form takes a while to load. I would like to add a progress bar to the buttons click event to signal progress on the current form while the SQL form is loading. I have dragged the progress bar onto my form. but it doesnt display any progress bars while the form is loading I am using vb express and sql express. Please help:( Thanks you would have to develop the progress bar on how to behave. here is a simple examle of a progress bar in action. http://www.codeproject.com/vb/net/NeverEndingBar.asp ...Show All
Visual Studio 2008 (Pre-release) Inprocess Chanel
Does anyone know if there is a sample of using WCF to create an inprocess class. I am not sure as to whether i would need to create a custom channel, transport etc. The reason for needing this is we would like to be able to use a service in our code that initially is inprocess and therefore has no overhead of the WCF stack\layers. But in future be able to scale the class out to a full distrubuted architecture. My thought on this was to have a custom chanel\transport to achieve this. Does anyone know if this is possible or am i barking up the wrong tree on this one and need to create a layer\service infront of WCF to acheieve this DotNetDave wrote: we would like to be able to use a service in ...Show All
