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 > february 2004 > threads for thursday february 26

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

Stopping a process as a impersonated user
Posted by Riaan CilliƩ at 2/26/2004 11:12:22 PM
Hi I need a bit of help. I need to write a utility that will end a process as the administrator. I have managed to impersonate the administrator. The problem is that I cannot seem to end the process after the impersonation. The System.Diagnostics.Process object simply returns "Access Denied" ...more >>


DateTimePicker
Posted by Atley at 2/26/2004 11:04:06 PM
Is there a way to use the DateTimePicker to pick a time or is it just used to pick dates? If so, why is it called DATEtimepicker? ...more >>

How to send a char to TextBox
Posted by scottiedog at 2/26/2004 10:41:09 PM
Hi How can I send a char to Textbox so that KeyPress event is called? I have a button and with a click I would like to send a char, e.g. "C", to the Textbox. But Textbox1_KeyPress is not catching the event (I can step thru KeyPress ok but nothing goes to TextBox). KeyPress itself works fine with...more >>

Trying to get a Date Breakdown
Posted by Atley at 2/26/2004 10:30:10 PM
I am trying to get a overall difference on two dates, I can get the difference in Years, Months, Weeks, Days, Hours, Minutes, Seconds, no problems... What I cannot seem to figure out is how to get: 2 Years, 3 Months, 1 Week, 3 Days, 14 Hours, 21 Minutes, 33 Seconds. The hardest part of ...more >>

Determining the current procedure name and the namespace for the class it is in
Posted by roddles at 2/26/2004 9:46:53 PM
Hi I need to at runtime determine the name of the function I am currently in, and the namespace of the class the function is executing from. I need this information for some logging routines i am writing and I do not want to have to hard code everything Can someone tell me which classes i need t...more >>

How to limit my VB.NET app to show only one taskbar entry
Posted by Neal Miller at 2/26/2004 9:16:06 PM
Hi all What can I do to make my app show only one entry in the taskbar, instead of one for each open window in the app Thanks Neal Miller...more >>

Importing namespace does not work??
Posted by grawsha2000 NO[at]SPAM yahoo.com at 2/26/2004 8:11:36 PM
Hi, I tried to import Drawing namespace and then declare one of its classes, but this seems does not work with me. Imports System.Drawing Dim gr as Graphics = MyForm.CreateGraphics 'This give error; Type expected Dim gr as Drawing.Graphics = MyForm.GreateGraphics 'This works ...more >>

Help with data grid
Posted by Kimberley Wiggins at 2/26/2004 7:02:56 PM
Can someone please help me? I am still learning vb so this is fairly new. I have been chasing this problem for 3 days now and I think that I am ready to give up. Does anyone know how to make my data grid display on a tab control? I have a tab control with 2 tabs on it, one for the dat...more >>



Base table
Posted by Kenneth at 2/26/2004 6:41:47 PM
What's best way to keep base values in memory In dataset or array I have som base tables I load when my application start and I dont want them go backward and forward to the SQL server, but is it best to kepp them in a dataset or? //Kenneth ...more >>

Sending arguments to a context menu event handler
Posted by Don Peters at 2/26/2004 6:27:59 PM
I can't seem to find an answer to this problem in spite of many searches. I have a VB.NET program that has a context menu popup event. In it I associate some menu items with their events, as follows: ContextMenu1.MenuItems.Add("+1", New SystemEventHandler(AddressOf Me.Plus1)) Contex...more >>

Return DataRow or Row index from DataView
Posted by tim_frawley NO[at]SPAM fishgame.state.ak.us at 2/26/2004 5:40:50 PM
I need to return a DataRow or the Row Index in a DataSet wherein the value I am attempting to find is not a primary key. I have to do this often, more than 200 times when importing a file so it needs to be fast. Could I use a Dataview to filter for the value (which is unique) and return eit...more >>

Is it time to change from vb to VB.Net?
Posted by BadOmen at 2/26/2004 5:12:38 PM
I know the obvious answer here on the VB.Net... I bought for a couple of years ago Visual Studio 6.0 Pro and I wonder what I have to gain in getting me the .Net version? I am rather new to VB 6 so learning VB 6 or VB.net does not mater... Is it easier or harder to learn VB.Net? I have made...more >>

Icon in ListView column heading?
Posted by Tom at 2/26/2004 3:51:33 PM
Is there ANY way to put an icon/picture in a listview's column heading? I must say I am disappointed with Microsoft's conversion of the ListView control to .NET. With the old VB6 one, I was able to sort easily and to put images into the column heading (i.e. putting an up/down arrow to indicate t...more >>

Treeview Help
Posted by A-PK at 2/26/2004 3:39:54 PM
Hi, I am using treeview as my menu. my menu is like the following + Users & Groups - Users -Groups + Departmenuts - Engineering - Business Currently, I am using mouse down event and trigger my mouse right click. so when my mouse cursor is in the treeview, and I right ...more >>

clearing a listbox
Posted by amber at 2/26/2004 3:31:05 PM
Hello I'm keeping this list busy! : Okay, now I'm trying to clear a listbox The way I have it set up, the user can either enter a value into a textbox, then hit a button, and 1 specific record is shown in the listbox. Or, the user can just hit the button (leaving the textbox blank) and all possib...more >>

HOWTO?: decimal property to supply null
Posted by Ringo at 2/26/2004 3:23:58 PM
I have a class that wraps up data from a database. It's consumed by a procedure that populates another database. I thought I'd been pretty clever with the design until I realised that a null would have to pass to the destination database and end up as a null. The decimal property insists o...more >>

Strong Names??
Posted by SStory at 2/26/2004 3:04:47 PM
OK.. I know enough to be dangerous.. but still learning. Seems from reading that I should use a strong name if my app is a dll that is going to be shared. 1.) What if it is just and EXE? 2.) Could I use it so that if I have a DLL and an EXE, only my EXE could use the functions within that...more >>

Timer as form inactivity monitor - tick event firing unexpectedly
Posted by Dan at 2/26/2004 2:46:25 PM
Hi, I have a timer on a form (System.Windows.Forms.Timer - Framework 1.1) that is set to 60 seconds as sort an of inactivity monitor. If 60 seconds have elapsed without any user activity I want the form to close. I stop/start the timer at button clicks and keydown events etc of the various c...more >>

GroupBox text - invisible in W2K, ok in XP
Posted by Jeremy at 2/26/2004 2:00:28 PM
I have a form with 4 groupboxes on it, each with a text property (caption in upper left). When the app is executed on an XP box, all the groupbox captions display correctly. When executed on win2k pro, the caption on the upper left groupbox is invisible (but there is a broken border where the ...more >>

using windows services
Posted by Srinivas at 2/26/2004 1:54:26 PM
Hi, I have developed a vb.net assembly which I use in existing asp.net pages. I also want to execute it every night at 12. I am new to windows services. Can anyone guide how to execute this program using windows services only once every day at 12 in the night. Any pointers to code samples wou...more >>

Exporting Table in a Dataset to Excel
Posted by Tor Inge Rislaa at 2/26/2004 1:34:14 PM
I have a need for exporting the content of a table in a DataSet to an Excel Sheet. Is this possible? MyDataAdapter.Fill(MyDataSet) 'Something here to export MyDataSet.MyTable to Excel TIRislaa ...more >>

How to calcualte date1 - date2 = # of years?
Posted by RH at 2/26/2004 1:24:25 PM
Hi, I would like to calculate the number of years between 2 dates. I tried using the DateDiff function but I don't get the result that I want. MSDN says: If Interval is set to DateInterval.Year, the return value is calculated purely from the year parts of Date1 and Date2. I would like the...more >>

using c code in vb.net projects
Posted by Craig at 2/26/2004 1:21:11 PM
Is there any way to include c code in a vb.new project (or have both c and vb.net projects in one solution) that will allow the vb.net code to directly call the c functions? I know this can be done as dll and activeX but I was under the impression that this was possible with the new visual studio ....more >>

How do I keep the TCP/IP listener running?
Posted by cf_rich NO[at]SPAM hotmail.com at 2/26/2004 1:12:55 PM
I took some samples from the net to help me create a TCP/IP socket listener. I stripped out most of the code and put it below. Bottom line is when I receive the ***END*** line from the client, the client is done sending me data. Of course when this happens, my server stops. I would like to k...more >>

Any book recommendations???
Posted by alcayro at 2/26/2004 12:56:06 PM
Hi Any book recommendations for Visual Basic .NET Intermediate Level and for building web services....more >>

Windows Service Description
Posted by Jerry Camel at 2/26/2004 12:41:16 PM
I suspect this should be pretty easy, but i can't figure it out... I've created a windows service - runs just great. How do supply information to show in the description field of Services control panel applet? Thanks. Jerry ...more >>

Nested Collections
Posted by Atley at 2/26/2004 12:38:57 PM
I am trying to set up a nested collection so I can run statements like this me.lblquestions.text = mysteps.item(1).questions(1).Asked Any ideas on how to do this? I have created a Class(Steps) with a nested Class(Questions) inside of it and a Collection of that Class(Steps) and it works fin...more >>

Formsize larger than screensize
Posted by Mikael Sorensen at 2/26/2004 12:12:12 PM
At designtime I would like to create forms larger than my screen size (1024x768) in VB.NET 2003. However I am not able to create forms larger than 1036x780. - I would like to resize the form to 500x5000. At runtime the form will be resized to fit the screen. In VB.NET 2002 I did not have thi...more >>

how to init array of objects? (controls)
Posted by Rich at 2/26/2004 12:06:26 PM
Greetings all, (apologize in advance if I am too VB6'd out). So I have a list of controls on a vb.net windows form. 2 datetime pickers, 2 checkboxes, 4 textboxes. In VB6 I could load these guys up into a variant array and initialize them. I understand in vb.net the variant went away f...more >>

Network State
Posted by MrMind_15 NO[at]SPAM Hotmail.com at 2/26/2004 12:01:39 PM
Hi everybody, I hv got a serious problem upon which I hv made a software tht needs to enable and disable the state of network adapter. Please send me the code or tell me the api by which I can do this. Also post some code for using tht api. Any reply will highly be appreciated. Thanx....more >>

test production
Posted by Vivek Kumar at 2/26/2004 11:59:24 AM
test production ...more >>

how can i browse the pictrue quickly?
Posted by lemonvital at 2/26/2004 11:22:12 AM
i wan to browse product'picture by category.but there are too many pictrue in database,how can i browse quickly?i want the function like Acdsee. ...more >>

Serial Communications: best way to start??
Posted by Jack Black at 2/26/2004 11:16:26 AM
Hi, all! Using VS.Net '03 under Win2k3 Server; clients will be XP, Win2k... I'm just beginning to look into how I would go about building serial communication apps in VB.Net, and am not sure where to begin looking for info, libraries, etc. The applications will basically query serial devices ...more >>

please help me.textbox do not work well
Posted by lemonvital at 2/26/2004 11:16:19 AM
i have a main form and i want to ada a childform,so i do it with the way such as me.controls.add code : Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click If IsNothing(lead) Then lead = New lead lead.TopLe...more >>

data types
Posted by Seshasai S at 2/26/2004 11:11:32 AM
In .Net all built-in types are classes. We know that these all were inherited from object class. Object class has GetHascode() function and GetType() function. Is there any significance in these functions. My doubt is that these built-in types are storing data internally?...more >>

How to view MS Access reports from VB.NET
Posted by Parveen at 2/26/2004 10:26:05 AM
Hi Does anyone know how I can view ACCESS reports from my VB.NET application? I know that in VB 6.0 the following works.. Dim appAccess as Access.Applicatio Set appAccess = new Access.Applicatio appAccess.OpenCurrentDatabase strDbNam appAccess.DoCmd.OpenReport "Report_Name", acViewNormal Bu...more >>

specifying selected item in a listbox
Posted by amber at 2/26/2004 10:11:10 AM
Hello again : How do I specify which item in a listbox I want selected The listbox is already populated, and if the user types in a value into a textbox, I want that value to be highlighted in the listbox Thanks Ambe ...more >>

etched line look quickly
Posted by Brian Henry at 2/26/2004 10:08:59 AM
Is there a quick way to produce an etched line look that microsoft uses to split up sections (similar to the bottom line of a group box) with out actually using the GDI commands to draw it as line and another line? i thought i saw a way in the past but cant find it now... thanks ...more >>

API call to GetTopIndex not working for Listview (vb.net)
Posted by Henry at 2/26/2004 9:52:56 AM
I'm trying to get the index of the top row in the display area of a listview (vb.net) by doing an api call to ListView_GetTopIndex. See code below. The call is returning a 0. The SDK doc states that ListView_GetTopIndex "Retrieves the index of the topmost visible item when in list or report ...more >>

How do I do this?
Posted by Merlin at 2/26/2004 9:52:07 AM
Hi, This is want I want to do, but not sure how to do it:- I want to create a class that has events, for example a Class called "Security" that has an event called "Security Changed", I then want to attach this in some way to some forms and controls and then have the event "Security Changed...more >>

Cast from 'DBNull' to "string' is not valid
Posted by amber at 2/26/2004 9:21:07 AM
Hello I'm new to this, and I'm not sure how to avoid the following error I use the following code to pull data from a SQL database, depending on the choice selected in a listbox Private Sub lBoxCP_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles lBoxCP.Sel...more >>

Focus of RadioButton
Posted by jahuer1 NO[at]SPAM yahoo-dot-com.no-spam.invalid at 2/26/2004 9:19:46 AM
On my Form I have several Panels with several RadioButtons on it. When I start the Form, on each Panel a RadioButton should be selected if it was selected when I called the Form some time ago. Problem: How can I force that the focus remains on a specific RadioButton after it is selected? (so ...more >>

Showing treeview nodes in Bold
Posted by Steve Shanks at 2/26/2004 9:11:05 AM
Hi Al Is there away to show specific treeview nodes in BOLD when building the treeview up in code Thank Steve...more >>

How to Access Data Using Query?
Posted by mathews NO[at]SPAM aecl.ca at 2/26/2004 9:03:51 AM
Hi All, I am new to VB.Net and am having a problem with the below code. I am trying to fill in a datagrid with the below query but it keeps giving me error where the *'s are located below. I have an OleDbDataAdapter, OleDbConnection and DataSet on my form. This is the actual error: An unh...more >>

?disable txtbox without graying out font?
Posted by Rich at 2/26/2004 8:30:01 AM
Hello, So I would like to disable a textbox on a vb.net form without the text getting grayed out. In vb6 I could place a textbox control on a frame control and disable the frame leaving the textbox enabled and text/background were intact but mouse cursor remained an arraw (as opposed to ...more >>

Print button on PrintPreview dialog box not working?!
Posted by ctbusdev NO[at]SPAM cox.net at 2/26/2004 7:32:57 AM
I am using printpreview dialog box control in my VB project. I can see the multipage document in preview but when I click on the Print icon in the dialog window, I get a blank page ! Does anyone know what is the issue ? Thanks. -AR...more >>

How do I step through my DLL?
Posted by mike at 2/26/2004 6:46:10 AM
I have a dll that I created to use in all of the programs I create. I have one program that when I call a sub or function that is in the dll I can step into the dll code and look to see if I have any problems with the dll. I have another program where I cannot step into this dll. I assume this is...more >>

TO LEARN PROGRAMMING
Posted by GUSTAVO at 2/26/2004 6:11:08 AM
Hello, my name is Gustavo Vásquez and I want to learn how to program computers What one needs to be a good programmer of computers Which your advice are to be a good programmer How is the logic acquired Is it true that people that are good in mathematics are made easier th programming of Compu...more >>

Grab filename from drag&drop into ListView? How?
Posted by Ken Swanson at 2/26/2004 5:11:49 AM
Hi, In VB.NET, how do I determine what filename has been dropped into a ListView? In my ListView's DragEnter() event, I am trying this, which according to the Help, should work: MyFilename = e.Data.GetData("FileName").ToString I have also tried e.Data.GetData(DataFormats.Text) and GetDat...more >>

Email Application
Posted by Cristina at 2/26/2004 4:50:08 AM
In order to send automated email from my application I have used MAPI controls.Unfortunatly I don't know how to handle the MAPI control Error Messages described here http://msdn.microsoft.com/library/default.asp? url=/library/en-us/mapi98/html/mapicontrolserrs.asp. For example if my mail doe...more >>

Find Dialog
Posted by genojoe at 2/26/2004 4:16:07 AM
VB.NET has items in its toolbox for OpenFile dialog, Print dialog, etc I am creating a form where I would like to use the Find dialog by either pressing Ctrl-F, or by making a selection from a context sensitive menu or a button on the form that applies the Find dialog to a textbox Is there an ea...more >>

Urgent: Outlook with VB.net
Posted by srinivasasarma NO[at]SPAM bharatmail.com at 2/26/2004 4:06:50 AM
Hi, i'm trying to retreive the appointments from different profiles of outlook. My outlook has 3 profiles created.('Sample1','Sample2','Sample3') my form contains 3 buttons.each one for each profile. so when user clicks on a button my code has to show the appointments for that particular profi...more >>

Comparison Operators
Posted by carlob NO[at]SPAM global.co.za at 2/26/2004 1:50:20 AM
Hi I need to average the two highest numerics entered in separate text boxes using an if statement. So far I have got if txtFirst.Text >= txtSecond.text and txtFirst.Text >= txtThird.text then FirstHigh = txtFirst.text elseif txtSecond.Text >= txtFirst.text and txtSecond.Text >= txtThird...more >>

Looping through a bunch of text boxes
Posted by teddysnips NO[at]SPAM hotmail.com at 2/26/2004 1:46:22 AM
VB.NET I have a bunch of textboxes on my form txtPart1 txtPart2 .... txtPart16 When the user presses "Ok", I need to concatenate the values into a single string and paste it into an email. I wondered about this (AIR CODE): Dim strParts As String Dim iintIndex As Integer For ii...more >>

Problem with different time zone
Posted by anniech2000 NO[at]SPAM hotmail-dot-com.no-spam.invalid at 2/26/2004 1:39:23 AM
I need to call a webservice in a windows application by passing some parameters and gets a dataset from the SQL service through the webservice to print a report. However whenever there are datetime field in the dataset, the webservice automatically add/minus the time gap if the server is set in...more >>

Create DLL in VB.NET
Posted by Nick Wright at 2/26/2004 1:21:08 AM
Hi I'm trying to create a dll in VB.NET, the DLL needs to be a C type DLL, i.e. not an Active X Dll.. an example in C would be... Example - test_ep.c #include /* This function simply returns the larger of x and y* long find_max(int x,int y) if (x >= y) return x else retur...more >>

Update a Progress Bar asynchronously
Posted by Vinay at 2/26/2004 12:31:06 AM
Hello I am trying to update a Progress bar on a form. I am able to update it via using a simple clock timer, but as soon as I perform a long operation G1 (generation of a report) in a separate form, it stops updating it, but keeps on incrementing the Progress bar values in the background and displ...more >>


DevelopmentNow Blog