vb.net

OrderBy and OrderByDescending are stable?

I am currently reading Pro LINQ c# 2008, and in page 87 the guy says OrderBy and OrderByDescending are stable. But he says exactly the opposite in page 96. It looks to me as he is referring to exactly the same functions, so I don't get it. Are they stable or not? ...

Split string on multi-char seperator and maintain seperator

Using VB.NET - I have a string: "##RES00012##Some value ##RES00034##Another value" That I want to split using the "##RES" as a seperator to: "##RES00012## Some value " and "##RES00034## Another value" The string.split function doesn't seem to offer an overload to split on multiple characters or array of characters and maintain the se...

MSbuild getting the current configuration from the solution file

In my VB.NET project I have three configurations DEBUG|TEST|RELEASE. Currently when I am building using MSbuild and TeamCity I hard code the configuration, which smells badly!, to TEST <Configuration Condition=" '$(Configuration)' == '' ">Test</Configuration> Now before everyone screams at me not to hardcode this, the reason this wa...

Set Default Location of setup

hi, I need to set a string stored in registry as the default location of a setup file how to do in vb.net (visual studio 2008) Urgent please help me... ...

Build regex to find and replace invalid HTML attributes

Hello, The sad truth about this post is that I have poor regex skills. I recently came across some code in an old project that I seriously want to do something about. Here it is: strDocument = strDocument.Replace("font size=""1""", "font size=0.2") strDocument = strDocument.Replace("font size='1'", "font size=0.2") strDocument = strD...

allowing user to choose their own color for form background

how do i give the user a color chooser for the background of a form or anything else? i would like to be able to give him all colors in vb.net ...

how do i set the background color of my form to what the user picks from colordialog?

how do i set the background color of my form to what the user picks from colordialog? ...

64-Bit VB.NET Allocating > 2GB of RAM (.NET bug?)

I have a 64 bit VB.NET application and want to allocate a buffer > 2GB in size. In the following code both the "new" and the "ReDim" throw an "OverflowException." How can I allocate buffers > 2GB when these functions only accept signed 32 bit values? (Is this possible in C#?) Edit - I am running WinXP 64 with 4GB of RAM. Dim width ...

How do I see the guid while debugging VB code in VS2008?

On my last machine I had created a way to see a GUID variable while debugging by hovering over it. I don't remember what it was (a visualizer?). I have a new 64 bit machine with vs2008 - is there anyway to mouseover a guid value and have it appear? What makes guid's so special that their value doesn't show like most variables? ...

i need the icon to disappear after application is closed

my winforms app puts a little icon in the taskbar next to the clock while it's running. how do i make it disappear when i close the program in vb.net? after the application is closed and i put my mouse over it, it disappears. ...

Queue operations in a WCF service

I am working on a Windows forms application where I would like to queue operations for a windows service to accomplish in the background. I was reviewing using WCF for this purpose and it seems to fit the bill, although I am unsure how to implement a queue for these sort of operations. What I envision on the client side (the forms appl...

What replacements are available for vbscript in an application?

An application I maintain has been around since VB6 days - ported to .Net 1.1, and now being updated/rewritten across to .Net 3.5 The application provides a mechanism to run VBScripts - this was done in a highly integrated way - allowing the program to parse multiple .vbs files and produce a list of all of the subroutines and functions ...

VB.net BinaryWriter Problem

Hi, In c# i could do it like: send.Write((ushort)9); "send" is an instance of BinaryWriter, how can i do it in vb.net ? I've tried it like: send.Write((UShort)9) but i get "UShort is a type and cannot be used as an expression" Thanks! ...

Efficient data conversion using .Net

I am working on an application that will need to read tons of records (close to 500,000) from one table and insert them into another set of tables in the same database. I though about using SSIS package for this but our DBAs don't want to use that. Now, I am thinking of a multi-threaded approach. I am thinking that I can have a few th...

Using Keypress to Add Item to Listbox

Hi, I have a textbox and a listbox and I'd like to have the listbox add an item (based on textbox) when enter is pressed. I am using vb 2008 Please help, I am struggling lol. Thanks! ...

VB.NET WindowForms Problem

Hi everyone. Currently I am having a weird problem which I simply do not understand. I have a simple GUI, with one button & one richeditbox. I have an async socket running, I am receiving some data over the network which I want to print to the gui(richeditbox). The async socket is being started when the user hits the button. So when I r...

Master Detail Databinding Winform with Detail in NEW window

There are a lot of master/detail databinding examples with detail form on the same window than the master, I can't find any example where detail is in a new window. Do you know any example in C# or at least in VB.NET ? ...

Random Number but Don't Repeat

Hi, I would like to generate a random number less than 50, but once that number has been generated I would like it so that it cannot be generated again. Thanks for the help! ...

Migration of Test Scripts into a New Release

Hi, Overview Our company's current system test cycle involves the use of word documents for the UI test scripts and test execution log. For each new release, these documents are copied from the previous release and then modified to reflect the current release version together with new test steps where there are changes in functionalit...

Newbie: should I learn c#, VB.Net or VBA/VB for excel programming?

My background: Mostly C programming. I have some (very recently...last 2 months) acquired JAVA (novice) skills. All my limited experience is based on developing for linux. I would like to do some excel programming for work purposes. My main interest is in starting to create "dashboards" and charts/reporting from excel sheets as I'm sick...