Archived Months
June 2003
July 2003
August 2003
September 2003
October 2003
November 2003
December 2003
January 2004
February 2004
March 2004
April 2004
May 2004
June 2004
July 2004
August 2004
September 2004
October 2004
November 2004
December 2004
January 2005
February 2005
March 2005
April 2005
May 2005
June 2005
July 2005
August 2005
September 2005
October 2005
November 2005
December 2005
January 2006
February 2006
March 2006
April 2006
May 2006
June 2006
July 2006
August 2006
September 2006
October 2006
November 2006
December 2006
January 2007
February 2007
March 2007
April 2007
May 2007
June 2007
July 2007
August 2007
September 2007
October 2007
November 2007
December 2007
January 2008
February 2008


all groups > vb.net > april 2005 > threads for wednesday april 27

Filter by Day: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30

Why use databinding ?
Posted by LB at 4/27/2005 6:06:58 PM
Reading the http://samples.gotdotnet.com/quickstart/winforms/ I'm trying to see the advantage of using "simple data binding". Let's say I have a treeview loaded from a collection. On form load, the treeview is loaded. And I bind my textbox to one on the property txtLength.DataBindings.Add("T...more >>

Free tool to document code
Posted by J L at 4/27/2005 5:23:56 PM
Is there a free tool that will read the VB files and create a report showing a list of methods, their arguments, classes, thier properties/methods, etc? TIA, John...more >>

Newb Question: Displaying comma delimted text in different text bo
Posted by JR at 4/27/2005 4:23:35 PM
I have tried searching boards but have not been able to find an answer. What is the best way to display text from a log.txt file and then display it in three seperate text boxes? I have a log file that is continually going to have 3 temperatures appended to it. I need to read that tempera...more >>

Current PrintDocument Coordinates
Posted by hclarius at 4/27/2005 4:21:33 PM
Is there any way programmatically to get the values of the PrintDocument's current position (x and y)? Thanks...more >>

SQL insert
Posted by Michael Persaud at 4/27/2005 4:14:59 PM
Hello, I am trying to insert into a SQL2000 dbase some records i am havinf some difficulty with the code below: Dim Reports If CboReportsTo.Text.ToString > "" Then Reports = CboReportsTo.Text.ToString Else Reports = "" End If Dim str As String = "insert into Jobtitle(JobTi...more >>

Correct Usage of Collections?
Posted by Tim T. at 4/27/2005 3:46:06 PM
I'm currently working on a report to forecast production for finished goods. The user can select one or more items to forecast. In addition, they may select one or more warehouses to view breakdowns for as well as one or more customers. Now, the report iterates through the selected items ...more >>

Setting the MDI Parent when it isn't 'Me'?
Posted by Mitchell Vincent at 4/27/2005 3:25:15 PM
I have a module that creates an instance of a window but needs to set the MDIParent property to the 'main' window, appropriately named MainWindow. When I do this : Dim MyCustWindow As New CustomerWindow MyCustWindow.MdiParent = MainWindow It doesn't work. The only M...more >>

XML search case insensitive?
Posted by Cesar Ronchese at 4/27/2005 3:24:06 PM
Hi all. I have some codes using the System.XML objects to find my configurations (object.SelectNode -or- object.SelectNodes). The problem is I need suply the XPath string with case sensitive. Its possible I change the behaviour to case insensitive? Early thx Cesar ...more >>



randomize 2 different numbers in same subroutine?
Posted by Rich at 4/27/2005 3:24:04 PM
Here is what I am trying for randomizing 2 numbers in the same subroutine so that they are not equal to each other: Dim j As Integer, k As Integer j = New System.Random().Next(0, 10) k = New System.Random().Next(0, 10) But j and k are always equal to each other. So I through in Randomize( ...more >>

convert RGB color to System.Drawing.Color?
Posted by Rich at 4/27/2005 3:18:03 PM
I need to change my form's backcolor back to the design color after it changes to another system.Drawing.Color. In the backcolor design, the value is in RGB me.BackColor = ...RGB(255, 255, 192) This doesn't work. How can I change the RGB values to System.Drawing.Color? Thanks ...more >>

en_ejecucion_en_forma_dinamica?
Posted by GZG at 4/27/2005 3:03:34 PM
Por ejemplo Dim FRM As String = "fUno" 'y poder yo decir lo siguiente FRM.Show 'se asume que hay un formulario con el nombre fUno en mi proyecto 'mi necesidad es crear un objecto formulario a partir de un string...more >>

VB Project consumes Win 98 System Resources
Posted by Tim C Reed at 4/27/2005 2:59:55 PM
Howdy, I have a new VB.NET Timesheet project that runs fine under XP, but crashes and burns under 98 due to a lack of System Resources. For example, I lose 68% of the System Resources by just opening the project, even without any code! (P3 550 w/192MB.) My program is a bit hefty with o...more >>

Get the domain name
Posted by Bruno at 4/27/2005 2:59:09 PM
Hello friends I need to create a simple application that returns the domain name where the user name logs in. For example, if I acccess in a computer with the domain user Contoso\bruno, my application should return the value "CONTOSO". Basically, my application when executed in a pc that be...more >>

"in use by another process"
Posted by Bob at 4/27/2005 2:57:55 PM
I've been repeatedly annoyed by situations where a process has failed or otherwise something has gone wrong (not from any of my own apps) where I cannot move, rename, or delete a file because Windows thinks it's "being used by another process". There are no processes evident using the file(s) or...more >>

ArrayList Columns
Posted by Kent Ogletree at 4/27/2005 2:46:35 PM
I have an ArrayList that is filled from an IDataReader. In one function I need to add one column to this ArrayList. Since the ArrayList is filled at a lower level in the application and reused by several functions within the application I do not want to modify it in the stored procedure. Is...more >>

Alternative to Interface?
Posted by Brett at 4/27/2005 2:41:04 PM
I have created an interface with five properties and five methods. Five classes are accessed through this interface and contain the implementation. This setup works fine now. All the classes are encapsulated by the interface. If one of the classes requires a new method, this means I have ...more >>

VB usage of C# Dll Constructor and Enum
Posted by JimM at 4/27/2005 2:36:40 PM
I know this is the VB languages new group. I have a .NET library (DLL) written in C#. I am adding examples to my documentation for my VB users. I have a VB example that will not compile. C# struct and enum: using System; namespace VLib { public enum Types : sbyte { ...more >>

Working on project on 2 PC's
Posted by Gary Paris at 4/27/2005 2:02:36 PM
I am working on a project which I have on my desktop. The project and data reside on the D: drive Sometimes I copy the project over to the laptop which is on the C: drive. Each time I have to edit the following code to put the proper Drive letter in. g_DataLocation = "D:\Test\Test.m...more >>

Inherited form - Protected sub / Derived form - Private Shadows subs
Posted by dbuchanan at 4/27/2005 1:48:00 PM
Is the following behavior normal? Both the 'Protected sub' in the inherited form and the 'Private Shadows sub' in the derived form fires. My interpretation of MSDN help on the topic "Shadows" does not seem to indicate that this is the designed behavior. (the topic is rather cryptic to me. ...more >>

Combobox - Is this the right way?
Posted by Gary Paris at 4/27/2005 1:36:47 PM
I have a question regarding the combobox. I populated a Combobox on my Windows form by databinding. In table I am binding contains a StaffID field and a StaffName field. When I ran a query to retrieve a field, I wanted to display the correct value (StaffName) in the combobox. This is th...more >>

Question about Implements
Posted by Michael at 4/27/2005 1:29:12 PM
Hi everyone, I'm trying to implement the ISupportInitialize interface, in the object browser there implemented like the followinfg: Public Overridable Sub BeginInit() Public Overridable Sub EndInit() I get the following build errors for both functions. 'MyDialog' Must implement 'OVerridab...more >>

What is ManagementObject's Get method do in this code?
Posted by Just Me at 4/27/2005 12:57:28 PM
I got the following code from the doc but find it works the same if disk.Get is included or not. The help for ManagementObject.Get says: Binds to the management object. Whatever that means. Can someone describe what Get does in a few more words? Should it be uncommented in the code below?...more >>

Is this .Dispose worth doing?
Posted by Dean Slindee at 4/27/2005 12:03:06 PM
After finishing with an access of a database table, I have been setting the data adapter, command, and connection objects to Nothing. Is it worth following the Nothing commands with Dispose commands as well, like this: Finally cn.Close() da = Not...more >>

Option Strict On disallows late binding
Posted by Dean Slindee at 4/27/2005 12:01:38 PM
I have a hash table that stores references to all open forms. If I implement Option Strict On, then the following two bottom statements are flagged for late binding. Is there a way to keep the hash table of form references and still implement Option Strict On? Public Const cfrmMain As Str...more >>

Combobox Question
Posted by Gary Paris at 4/27/2005 11:04:13 AM
I have a combobox on my windows form. It is populated from the "staff" table which has a StaffID and StaffName. The code is: cmbStaff.DataSource = objDataset.Tables("Staff") cmbStaff.DisplayMember = "StaffName" cmbStaff.ValueMember = "StaffID" When I query my contact database how can I...more >>

Newbie: Application hangs after long delay for SQL Server results
Posted by steve at 4/27/2005 10:49:22 AM
Hi, I have created an application that through a user interface "assembles" a T-SQL string, sends the querry to the server and fills up a datagrid. However my querries are (probably) not optimized (and hard to do since the posibilities through the user choices are endless), so *very* frequent...more >>

Installing my application - Publisher cannot be verified
Posted by Tony H at 4/27/2005 10:19:18 AM
I've built my first complete vb.net application.. Putting it on another computer hasn't been a pleasant experience. When I run the setup on my office computer (I built it on my home computer), I get a prompt to install '.NET Framework 2.0 Beta' which I of course agree to and it goes fine til i...more >>

Cookies and Paths
Posted by Shane Thomas at 4/27/2005 10:03:57 AM
Hello, I'm having difficulty handling cookies with paths other than "/". An HttpWebRequest object returns these headers: Date: Tue, 26 Apr 2005 21:29:39 GMT Server: Apache/1.3.33 (Unix) PHP/4.3.10 Set-cookie: phpusid=12345; path=/; expires=Wednesday, 09-Nov-2008 23:12:40 GMT,data=deleted; ...more >>

Easy label question...
Posted by Bruce D at 4/27/2005 9:49:01 AM
On my form I want to make a label visible when the user clicks a button (long process running in background). I have the visible property set to false at design time. On the click event of the button I set the property to true... The only way I got the label to actually appear while the long p...more >>

Removal of a service
Posted by UJ at 4/27/2005 9:04:21 AM
Guys, Before anybody even starts - yes I know I'm an idiot. Here's what I did - I wrote a service, works great. I inadvertantly deleted the installer for it so now I've got this service out there that I can't un-install. What's the easiest way to remove the service? I know there must be ha...more >>

calling op_Explicit directly
Posted by jim at 4/27/2005 8:56:05 AM
I have 3 classes, A, B, and C (written in C#). The C class has two explicit conversion operators - one that converts class C to class A and one that converts class C to class B. I need to be able to call the conversion operator from C to A. To do this in VB I do... objA = MyNS.C...more >>

ReadOnly ComboBox
Posted by Ahmed at 4/27/2005 8:42:36 AM
Hello everyone, I am trying to create a "ReadOnly" Combobox. I know I can disable the combobox but it will be unreadable for our users. So, I decided to extend the built in combobox and I succeeded in building what I want. The only problem is when the combobox is read only the mouse up event ...more >>

Excel range to dataset
Posted by Mac at 4/27/2005 8:16:09 AM
Hi I have a spreadsheet which I want to create an xml document from a range. In the past I did this by scrolling through the range and writing the lines to the document however this was fine but since we "upgraded" to dot.net (from vba), the speed of this process has dropped off considerab...more >>

datatable already belongs to another dataset
Posted by Sam at 4/27/2005 6:26:50 AM
Hi, I have this error message with the following code : m_dsSysInfo = New DataSet Dim dt As DataTable = m_fields.GetAllTables() m_dsSysInfo.Tables.Add(dt) Why??? GetAllTables return a single datatable, so it should work ?! Thx ...more >>

Week Number
Posted by poppy at 4/27/2005 2:25:17 AM
Does anyone know how I can get a week number from a datetime type ? These dates and times are killing me. Thanks in Advance...more >>

Newbie Question on parameters passed to stored procedure
Posted by kd at 4/27/2005 12:26:03 AM
Hi All, I am trying to pass parameters to a stored procedure from vb.net code and fails with the error that the variable is not a parameter to the stored procedure Here is the vb.net cod ---------------------------------------------------------------------------------------------- ...more >>

double qoutes in App.Config
Posted by DraguVaso at 4/27/2005 12:00:00 AM
hi, I'm having troubles putting a string with double qoutes (") in it in an application configuration file (App.Config). The string i need to put in it is: '/profile "MS Exchange Settings" ' I tried it like this: <add key="Argument" value="/profile "MS Exchange Settings""/> <add key="Arg...more >>

OT: SQL Server Memory Consumption
Posted by rawCoder at 4/27/2005 12:00:00 AM
Hi, How much SQL Server (sqlservr.exe) should be taking in memory ? I know its a very generic question, but any link or reference related to the memory conumption of SQL Server will be highly appreciated. Thank You rawCoder ...more >>

Convert 32bit vb.net programs to 64bit
Posted by yxq at 4/27/2005 12:00:00 AM
Windows XP 64 has released formally, i dont know how to convert the old 32bit programs to 64bit. ...more >>

maximise form
Posted by Doug Bell at 4/27/2005 12:00:00 AM
Hi, I am having some difficulty getting a form to Maximise. The form initially loads and maximises. With no User activity it will minimise after a delay. When the User clicks on the Task Bar the form re-appears but Normal not Maximised. I have the Forms WindowState property set to Maximised I ...more >>

Windows Forms Alt key dilemma
Posted by Rod Gill at 4/27/2005 12:00:00 AM
Hi, I'm learning VB.Net (VS 2003) and have built what I think is a simple application. It consists of a base form and a Main menu form that inherits from it. The menu form has three buttons added, each one of which when clicked should display a message stating the name of the button. Like I...more >>

Any new ways to sidestep VB.NET 2003 30mb overhead...?
Posted by Timothy Casey at 4/27/2005 12:00:00 AM
The vast majority of my customers (PC/Windows Users) do not want to wait six weeks for the mail to clear customs, anti-terror inspections, etc. Most have no access to broadband, and given that broadband and cable are infrastructure dependent technologies, it is unlikely that the bulk of my custo...more >>

Icons importing from DLL or EXE
Posted by JR at 4/27/2005 12:00:00 AM
Hi, I want to import Icons from DLL or exe files into a imagelist. I ave no Idee how to do it. I know the different icons have a 0 based index Jan ...more >>

Expiration Date of Beta 2
Posted by Michael D. Ober at 4/27/2005 12:00:00 AM
Anyone know when VS and VB Express 2005 Beta 2 expires? Thanks, Mike Ober. ...more >>

RickTextBox font properties
Posted by Adam Honek at 4/27/2005 12:00:00 AM
Hello, I have a rich textbox on my form and I want the user to be able to select the font properties via the font dialog box. 1) How do I bring up the font dialog box in the code? 2) How do I make the settings on it affect the rich textbox in question? Many thanks, Adam Honek ...more >>

Why does SelectedIndexChang­ed event fire?
Posted by Bruce D at 4/27/2005 12:00:00 AM
I have code in my tabcontrol.SelectedIndexChang­ed event. And I noticed the event fires when my form loads. Why? I don't think the event should fire. Didn't get much help reading from MS or Google... Any insight? -bruce duncan ...more >>

TextBox Validation and Containers
Posted by Phill. W at 4/27/2005 12:00:00 AM
Is there anything I need to watch out for when placing TextBoxes onto Containers like Tab Pages? I've got a funny where the Validating Event for a TextBox doesn't fire when I tab out of the TextBox, and adamantly refuses to fire *until* I tab out of the TabPage that contains it and onto anothe...more >>

Time Compare Function Problems
Posted by scorpion53061 at 4/27/2005 12:00:00 AM
Could you look at this function and tell me why I am getting an exception concerning date cast on line set apart by stars... If you have better suggestions of how to do this I would be open to suggestions. Public Function JobStreamCheck() As Boolean Dim hour As Integer Dim...more >>

clearing a text box
Posted by gordon at 4/27/2005 12:00:00 AM
Hi, I am using vb.net and loading up some SAS data into some text boxes based on an id selected in a combo box. I have a button that I wish to use to clear all the text box values and to set the combo box to a non-value "Select one...". I cannot get the boxes to clear. Several attemps ha...more >>

My app. start and exit right away.
Posted by Marty at 4/27/2005 12:00:00 AM
Hi, I am passing arguments by the command line of my application. I made a subroutine that check and validate arguments. 'This sub is in a module public sub main(args as string()) 'validate args() content.... 'display my main form.... end sub What happen is that when it reach the e...more >>

security settings and setup
Posted by C-Services Holland b.v. at 4/27/2005 12:00:00 AM
Hi everyone, we've got an application here that could (and probably) will be installed to a network drive. Therefore a permission set needs to be added to the framework policy. Now I've got it figured out how to do that using caspol giving the url of that directory fulltrust permissions. ...more >>

Deployment problem
Posted by Agnes at 4/27/2005 12:00:00 AM
As I modify some forms , I need to update my client's version, My client got over 50PC, Any simple and fast method that I can update their exe file ???? Thanks alot ...more >>

How to know whether it is a Chinese character?
Posted by James Wong at 4/27/2005 12:00:00 AM
Hi everydoby, I would like to know whether it is possible to distinguish whether a unicode character is Chinese character or alpha-numeric character. Thanks for your attention and kindly advice! Regards, James Wong ...more >>

Sending a string using SendMessage
Posted by Nick at 4/27/2005 12:00:00 AM
Hi there, I'm trying to send a string to another window using SendMessage, unfortunately I'm not having much luck turning the pointer back into a string, this is what I'm currently doing, '//Window sending the message '//iData is a Char array Dim pIPrData As IntPtr = Marshal.AllocHGl...more >>

Question about printing Chinese characters
Posted by James Wong at 4/27/2005 12:00:00 AM
Hi everybody, In MS-Word (Traditional Chinese Edition), it is possible to configurate two fonts for one string, one for Chinese characters and the other for English characters. MS-Word will apply font according to string contents automatically even it is a mix string of Chinese and English ch...more >>


DevelopmentNow Blog