all groups > vb.net > january 2004 > threads for thursday january 22
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 31
Thread problem
Posted by fred at 1/22/2004 11:46:08 PM
This is the first time I have tried to use multiple threads in an
application so I hope someone can help me.
I am using a second thread to do some work but I need to be able to cancel
the thread at any time. I have implemented the thread as below.
The problem I have is that usually when I call t... more >>
VB.NET: Updating executable if it is in use..
Posted by rbrown NO[at]SPAM edium.com at 1/22/2004 9:59:21 PM
Hi All..
I have written an application that clients of ours use at their
business. The application checks our main FTP server for new reports
and then downloads them. The download process also downloads NEW
versions of the executable they are running.
What I want to do is have the program t... more >>
threaded Login-splash-screen with progressbar
Posted by sotto at 1/22/2004 9:46:56 PM
I need a loginscreen, that will show a progressbar that changes values
based on a method in the main application (loading data from database)
how would i do this?
(i guess i need threading for this)
the main application shouldn't be accessible when the login password
hasn't been entered c... more >>
String question
Posted by Able at 1/22/2004 8:55:01 PM
Dear friends
I have a large string with the character "*" spread randomly in the string.
My goal is to search the string for the character "*" and retrieve the
string with these removed. How is the best way to achieve this?
Regards Able
... more >>
Please Help! Dynamic Allocation of array of structures
Posted by RBCC at 1/22/2004 8:44:58 PM
Does anyone know how to dynamically allocate array of structures? Or where
Ican find info on this on the web? John... more >>
What Microsoft newsgroup is For Active Server Pages 3.0?
Posted by Christian Blackburn at 1/22/2004 8:41:57 PM
Hi Gang,
I'm trying to find an ASP 3.0 newsgroup at News.Microsoft.com does anyone
know what that might be?
Thanks in Advance,
Christian Blackburn
... more >>
Printing a multi-page document
Posted by Jason James at 1/22/2004 8:38:42 PM
Hi all,
I have an application that needs to print numerous
documents of different styles (either to the printer
or print preview dialog).
I have selected which document type to print by
using a select statement in the the
PrintDocument.PrintPage
event handler. This appears to work... more >>
how to destory the application without getting error msg ?
Posted by Daylor at 1/22/2004 8:23:04 PM
hi.
i want to destroy the application when i catch some exception.
i have multithread app.
how can i destroy the application and exit immedietly ?
... more >>
Don't see what you're looking for? Search DevelopmentNow.com.
Show new form?
Posted by Sven at 1/22/2004 8:21:35 PM
In VB 6 I could show a new form like this:
Form2.show
how is this possible in VB.NET?
Thanks a lot
... more >>
Help with webForms
Posted by Ken at 1/22/2004 7:34:03 PM
Hello,
I have a webform that gets a record from SQL Server by using a stored
procedure.
The stored procedure uses 3 parameters in which after the record is found,
stored procedure #2 runs to update one of the columns called Status from
"incomplete" to "Pending"
Status is one of the paramete... more >>
Checking for Existing Key in Collection
Posted by Blake Weaver at 1/22/2004 7:11:38 PM
Subject pretty much says it. I'm testing my Collection to check and see if
an item has already been added, thus avoiding duplicates. I don't even know
what value to check it against... some sort of Null I'd guess. I tried
IsNothing(MyCollection("key") but I get the following error:
System.Argu... more >>
Threading
Posted by Anthony Nystrom at 1/22/2004 6:33:31 PM
What is the correct way to stop a thread? abort? sleep? Will it start up
again... Just curious... If the thread is enabling a form, if the form is
disposed is the thread as well?
Thanks,
Anthony Nystrom
... more >>
Netcam and VB .NET
Posted by Randy at 1/22/2004 6:31:09 PM
I'm new to VB .NET and have yet to get my hands on the software. Currently I am working on developing an APP for digital camera inspection system. I have experiance with C++ and some VB. Can someone point me in the right direction as to good tutorial site for VB .NET. Also, if anybody has any info o... more >>
About Context Menu shell extension
Posted by yxq at 1/22/2004 6:00:21 PM
Hi
Some vb6 code have some errors(Wave line) in vb.net, i refers to "Shell
Extension Interfaces v1.21"
The code
Implements IContextMenu
Implements IShellExtInit
Thanks
... more >>
SQLServer Projects
Posted by Jeff Block at 1/22/2004 5:56:23 PM
I am running VB.Net Standard Edition - can't create a solution or project
(or anything else for that matter) that uses SQLServer, except for the
Desktop Edition. I get an error message stating as such (or Access).. can't
locate any easy to read charts on MSDN that would point me to the right
ver... more >>
Function for converting to minutes in decimal?
Posted by Masahiro Ito at 1/22/2004 5:50:29 PM
I have column of data that have elapsed time in minutes.
For example:
1:15
1:47
23:12
I like to be able to use sql server to do simple math functions. Does
anyone have a simple function/formula that will convert into a decimal
minutes form?
EG: 1:30 should equal 1.5 minutes
T... more >>
TypeInitializationException - HELP
Posted by Dino M. Buljubasic at 1/22/2004 5:16:10 PM
Hi,
I am receiving an exception each time I open one of my projects in VB.net.
I do not have to run it, I just open the project and a Message box pops up
with the message:
TypeInitializationException: The type initializer for "MyProjectName.Module"
threw an exception.
This message box reop... more >>
Call as400 program from VB.NET?
Posted by Scott Johnson at 1/22/2004 4:44:52 PM
Hi
Does anyone know how to execute a program on an AS400 from Visual Basic? I
have no problem inserting data into the tables (files) on the as400, but I
need to execute a program on there to process the data. (I can't use
triggers either)
The command I need to execute on the as400 is
... more >>
REPOST : Context Menu
Posted by Dino M. Buljubasic at 1/22/2004 4:33:51 PM
I have several context menus added to my form. The form is displaying items
in listviews connected to the context menus. When I click on an item in a
list view, a popup context menu shows allowing me to chese between editing
or deleting the item from the list view. That works fine.
However... more >>
VB.NET service stops running after 10 minutes
Posted by Sam Straub at 1/22/2004 4:12:51 PM
Hello,
I've written a windows service that runs on a server, every 24 hrs it
generated a ton of files, sometimes in the neighborhood of 3-5,000. When
there are that many files to generate, the script seems to stop running
after 10 minutes, I see the dates on the files generated range by 10 mi... more >>
memory question... I don't think I posted twice, if so sorry....
Posted by Anthony Nystrom at 1/22/2004 4:12:07 PM
When would it be appropriate to call this: Anytime, specifuc events? When is
smart when is not... Also, can someone give me a complete example of doing
this in vb.net? Please define the hprocess and IntPtr proc and int min and
int max.... Say my app runs in an instance named appnew, what would b... more >>
Strange DBNULL Error - Please Help!
Posted by Martin Feuersteiner at 1/22/2004 4:09:28 PM
Dear Group
I'm having a very weird problem. Any hints are greatly appreciated.
I'm returning two values from a MS SQL Server 2000 stored procedure to my
Webapplication and store them in sessions.
Like This:
prm4 = cmd1.CreateParameter
With prm4
..ParameterName = "@Sec_ProgUser_Gen"
..S... more >>
Copy arrays without looping
Posted by Amjad at 1/22/2004 4:01:05 PM
I want to copy 1-D arrays to columns of a 2-D array. Is there a way of doing that without using a loop that will copy element by element?... more >>
Loop through certain controls
Posted by Kevin L at 1/22/2004 3:59:30 PM
I have the following loop:
Dim objPanel As Panel
For Each objPanel In Me.Controls
'do something here
Next
I receive an error when my loop encounters a control that is not a Panel
control.
I only want to perform actions on the Panel controls on my form and skip any
other t... more >>
Convert boolean to a 1 or 0
Posted by Alex Stevens at 1/22/2004 3:23:37 PM
Hi All,
I want to cleanly convert a boolean value to a bit value (1 or 0) in vb.net.
I can:
Math.Abs(CInt(bolValue))
or:
cint(bolValue) * -1
However, I wondered if there was a built-in method.
Thanks
Alex
... more >>
Mixing Sound Files
Posted by Bradley Jewell at 1/22/2004 3:06:09 PM
I am wanting to be able to take a templated sound file and superimpose other sound files overtop of it. If anyone has any idea's I would appreciate it. ... more >>
command line compile options
Posted by Gary O at 1/22/2004 3:01:05 PM
I would like to compile a class I have built to a library. I use the following command line:
vbc /reference:Microsoft.VisualBasic.dll /t:library /sdkpath:c:\windows\microsoft.net\framework\v1.1.4322 ClockControl.vb
But I get the following errors (not all are listed):
vbc /reference:Microsoft.V... more >>
Datagrid on winform question
Posted by dgk at 1/22/2004 3:00:07 PM
I can't seem to find a way to get a boolean database column to map to
a checkbox. It's maps to a plain text column that gives a value of
"True" or "False". Not really very elegant. I can't find a way to set
this through the designer.... more >>
Display Question
Posted by Andre at 1/22/2004 2:43:45 PM
Hi,
I need a little advice with this ;
I retreive some data from a database, and i want to create an output
with a link, logo image, title etc..
But i want to change the data before displaying it..
Ex : if the data is "IN" i want to dipslay "Internet" and make a link to
"in... more >>
Question: 'System.Web.Mail' namespace not found
Posted by VB Programmer at 1/22/2004 2:00:21 PM
I'm trying to send an email from my VB.NET application.
From the examples I've seen everyone imports 'System.Web.Mail' first. But,
when I type 'import System.Web.Mail' the editor says it can't find the
namespace. The message is: "Namespace or type 'mail' for the Imports
'System.Web.Mail' ca... more >>
File Explorer Tree View?
Posted by Robin Tucker at 1/22/2004 12:57:28 PM
I'm looking for a windows explorer style Tree View (that shows from the
desktop and includes "network places" etc). I can't seem to find a free one
anywhere! Any ideas?
Cheers
... more >>
Unable to start debugging on Web server
Posted by tguillor NO[at]SPAM ems.jsc.nasa.gov at 1/22/2004 12:55:26 PM
VB .NET 2003
I get the following error when trying to start my project:
Error while trying to run project: Unable to start debugging on the
web server. Server side-error occurred on sending debug HTTP request.
----------
I get the following error when I try to start the project without
deb... more >>
Using a .NET assembly in a VB6 application
Posted by Henke at 1/22/2004 12:53:37 PM
Hi!
Is it possible to use a .NET assembly in a VB6 application? We have an old
VB application to which we'd like to add a new module, no communication is
needed to the old app. Is it possible to develop it using VB.NET and then
use/call it in the VB6 application.
Thnaks in advance!
/Henke
... more >>
how to Swap DBgrid columns in runtime
Posted by Mat at 1/22/2004 12:49:07 PM
Please do i swap dbgrid columns in runtime from code?
i want to do the samething like when user move columns
Thanks you
... more >>
ListBox or ListView?
Posted by cr113 NO[at]SPAM hotmail.com at 1/22/2004 12:40:08 PM
In VB6 if I wanted to display a group of records, and possibly allow
the user to select one or more records, I would use the ListBox. For
example suppose I wanted to display something like this:
Name Address Phone Number
Johnson 111 South Av 111-1111
Smith 222 Main St 222-2222
... more >>
Memory...
Posted by Anthony Nystrom at 1/22/2004 12:21:27 PM
When would it be appropriate to call this: Anytime, specifuc events? When is
smart when is not... Also, can someone give me a complete example of doing
this in vb.net? Please define the hprocess and IntPtr proc and int min and
int max.... Say my app runs in an instance named appnew, what would b... more >>
Sending Mail with Lotus Notes
Posted by Jason MacKenzie at 1/22/2004 12:16:36 PM
We're moving frome Exchange to Notes soon and I'm wondering if anyone has
any info about sending mail using Notes and Vb.Net (or C#).
Any help or suggestions for a tutorial are very much appreciated,
Jason
... more >>
Inconsistency in indexof
Posted by Art Krumsee at 1/22/2004 12:04:20 PM
I have a console app that reads and parses the command line. The code
originally read something like this:
dim CmdLine as String = Command()
if CmdLine.indexof("-trace") then
'tracing is enabled...
end if
In Visual Studio on my development workstation this was working fine. But
on m... more >>
Doevents
Posted by ZR at 1/22/2004 12:00:18 PM
Hi all,
Is there an equivelet to the "DoEvents" keword (in vb6), in vb.net?
Thanks in advance
zr
... more >>
What do I need to get started?
Posted by Dave at 1/22/2004 11:11:08 AM
Folks,
I'm old a programming and new at VB. What do I need to get started? I've ordered some books, but as far as tools go when the books arrive. If I've got a standard MS2000 install, do I have enough to write code?
What tools are recommended to make programming easier?
Any help, thanks... more >>
Implementing a key/value pair collection...with a catch
Posted by Jeff L. at 1/22/2004 11:06:29 AM
I have an interesting problem and I'm not coming up with any answers in my
searches, so hopefully someone can give me a hand with this. I have a
feeling it's easy, but I usually get my nose stuck too far in the details to
see the big picture. :)
I want to create a collection of key/value pai... more >>
SQLDataReader
Posted by SQL at 1/22/2004 11:02:23 AM
I'm new at this, so please forgive me if my question has a simple answer to
it.
I'm trying to get a value out of a SqlDataReader. Here is my code to do so:
Dim mySQLCommand As New SqlCommand("SELECT NextPrbKey FROM SystemAdmin", cn)
Dim mySQLReader As SqlDataReader = mySQLCommand.ExecuteRea... more >>
Set focus on combobox
Posted by Sven at 1/22/2004 10:32:36 AM
How can I set the focus on a combobox?
In VB 6 it was: combo1.setfocus
Thanks a lot!
... more >>
VB.NET sharpziplib question
Posted by SStory at 1/22/2004 9:44:30 AM
I know this may not be the place for this question, but didn't know where to
ask it.
Does anyone know what characters are invalid as filenames for zipentries in
SharpZipLib?
I am zipping files that use a character that looks like a "." but centered
vertically.
This causes problems upon t... more >>
Change listview icons size
Posted by fran at 1/22/2004 9:41:06 AM
Hi
I would need to increase the size of the icons of a list view, to show a list of images.
Is It possible to change this size?
Is there another control more accurate to do this?
Thanks for al
... more >>
KeyDown in VB.Net?
Posted by Sven at 1/22/2004 9:36:00 AM
I only know the keydown-event in VB 6, there it is like this:
Private Sub Form_KeyUp(KeyCode As Integer, Shift As Integer)
If KeyCode = 13 Then
XXXXXXXXXXX
End If
How can I do this in VB.Net? can I do this overriding other settings?
Thanks a lot!
... more >>
Add Record
Posted by vibe2u2 NO[at]SPAM hotmail-dot-com.no-spam.invalid at 1/22/2004 9:31:38 AM
As my previous Post I am a terrible programmer but giving it my best
shot. I’ve used the following code to bind the data from an access
database to text boxes in Windows Form in VB.Net. Now I want to be
able to add to the records using via text boxes. I thought the best
way would be to have a cl... more >>
Scrolling using ADHOC Bar!
Posted by vibe2u2 NO[at]SPAM hotmail-dot-com.no-spam.invalid at 1/22/2004 9:31:34 AM
I’ve used the following code to bind the data from an access database
to text boxes in Windows Form in VB.Net. Now I want to be able to
scroll through the records using a adhoc bar and be able to jump from
the first to the last record. this coding only displays the first
record. Can anyone pleas... more >>
User Control
Posted by Jay at 1/22/2004 9:26:10 AM
Hi,
i created a user control, inside the user control there is a text box. I placed the user control on a seperate form. how do i get the value that is inside the text box using the code in the form .. ?
Need Code PLEASE !!... more >>
Build Numbers
Posted by kevin NO[at]SPAM kevinsworld.com at 1/22/2004 9:05:38 AM
Hi all,
I have a couple questions about build number:
1- When I move the mouse over some executable programs, I see tooltips
that show a version number. How can I get that into my VB.Net
programs?
2- If #1 is possible, then how can I somehow configure Visual Studio
to auto-increment th... more >>
Use CopyMemory with DotNet??
Posted by active at 1/22/2004 8:56:25 AM
Has anyone used CopyMemory with DotNet?
In this instance I define it as:
Private Declare Sub CopyMemory Lib "KERNEL32" Alias "RtlMoveMemory" (ByRef
hpvDest As DEVMODE, ByRef hpvSource As Byte, ByVal cbCopy As Integer)
Private Declare Sub CopyMemory Lib "KERNEL32" Alias "RtlMoveMemory" (ByRef
... more >>
Vb.NET Interface implementation
Posted by Guy at 1/22/2004 8:56:07 AM
Hi
i have a base class (marked 'MustInherit') with a public property called IsValid and a public event called Vali
i have a class (lets call it 'Client') that inherits this base class
so the Client class now has a public event called valid and a public property called IsVali
the client class i... more >>
Licensing Issues
Posted by Mythran at 1/22/2004 8:43:04 AM
Was wondering...the following site provides a compiler for C# and soon, VB.Net on
a linux box:
http://go-mono.com/c-sharp.html
What legalities should be made aware in order to use this legally? Are there any
legal issues that should be made aware before jumping the gun?
Thanks,
Mythra... more >>
How do I know when Windows tells my program to close?
Posted by kevin NO[at]SPAM kevinsworld.com at 1/22/2004 8:41:13 AM
Hi all,
I have a program that has this basic flow:
1- Splash screen opens and creates a system tray icon (the splash
screen is the main form that is started on program execution, and
stays hidden to be the form that the tray icon "belongs to")
2- From the tray icon, multiple forms are opened... more >>
How to implement "On Error Resume"?
Posted by Rexel at 1/22/2004 8:18:08 AM
Implementing VB's stock error handler, "On Error Goto Err_Label", is
easy enough using Try/Catch/Finally.
I also figured out how to implement "On Error Resume Next" case, like
when you want to delete a file but don't care about the error if the file
doesn't exists.
So:
Try
'main code
... more >>
Win32 Resources in .NET Question
Posted by Christopher Burr at 1/22/2004 7:45:38 AM
I'm trying to retrieve a string resource from a Win32 file.
In win32 world I would just use LoadLibrary and LoadString.
What do I use in the .NET world?
--
Chris Burr
cburr@kcc.com
... more >>
Minimizing forms
Posted by Nathan at 1/22/2004 7:37:28 AM
Hello again,
I have an application with three forms. Frm1 has a button whose click event
calls frm2 -- frm2.ShowDialog(). Frm2 has a button that calls frm3 --
frm3.ShowDialog(). When I minimize frm3, I want the other two forms to
minimize as well. As I have it now, frm3 minimizes and a sm... more >>
Shared question
Posted by Rexel at 1/22/2004 7:36:09 AM
What is the point of having a shared method in a class?
By its definition the shared method is independent of any
instance of the class it is in. So what's the point of it being
there?
It could have just been in class B instead of class A, or in
class C.
Why is it not in a module??
I don't ge... more >>
When to use form's Load event?
Posted by Rexel at 1/22/2004 7:29:19 AM
In VB6 I usually use the form's events in the following order:
Initialize: To initialize variables if need be. Controls are not yet
loaded.
Load: Now that controls are loaded they are set up, e.g., combo
boxes are loaded, textboxes are filled with default values if needed,
controls are enab... more >>
User Control
Posted by Will at 1/22/2004 6:56:07 AM
Hey all,
I need to know how to create an Active x control (User Control)
i need code and examples PLEASE !!!... more >>
Using threading to provide ProgressBar
Posted by pmcguire at 1/22/2004 6:46:06 AM
Rather than putting a progress bar on all of my forms to show progress during time consuming tasks, I made a form called frmProgress with 2 controls, a Label and a ProgressBar. Suppose I expose 1 property -- prgValue (the Value of the ProgressBar); how do I use threading so that my time consuming t... more >>
EnumPrinters gives system.nullreferencedexception
Posted by sarmstrong NO[at]SPAM tally.co.uk at 1/22/2004 5:06:52 AM
I use the following code and can get all the correct printer
information back for Printer_Info_1.
However, when I try the same code for Printer_Info_2 or 5 I get a
System.NullReferenceException. Can someone please help
<DllImport("winspool.drv", EntryPoint:="EnumPrintersA",
SetLastError:=T... more >>
BUG with the Color.FromArgb function?
Posted by Steve Randall at 1/22/2004 5:06:06 AM
I use a ColorDialog control to select a number of custom colours using the code segment below, I've fixed the index to 0 for the purpose of highlighting the problem.
Dim intRed As Integer
Dim intGreen As Integer
Dim intBlue As Integer
ColorDialog1.ShowDialog()
intRed = Color.FromArgb(Colo... more >>
ColorDialog question.
Posted by Steve Randall at 1/22/2004 4:56:06 AM
If I use the standard ColorDialog control to select a colour (say a pale blue) I get the returned value of 16762980 which is fine (Red=100, Green=200, Blue=255), BUT why when I use the following do I just get a transparent background???
Panel2.BackColor = Color.FromArgb(16762980)
Many thanks.... more >>
Save 2003 as 2002
Posted by Michael at 1/22/2004 3:23:08 AM
I need to save a VB.Net 2003 solution as a VB.Net 2002 solution.
I am told a program to do that exists.
I did a quick Google search of the newsgroups and didn't find anything.
Is there such a conversion?
Thanks,
Michael
... more >>
Newbie database question
Posted by jy836 at 1/22/2004 3:15:43 AM
Hey all. I'm a newbie to VB .NET (though I've programmed somewhat in VB3 in
the past). I'm trying to display the contents of a MS Access 2000 database
inside a DataGrid, but I don't know how to make the connection. The database
is on my hard drive. I am using Visual Studio .NET 2003 on Windows XP... more >>
calling stored procedures with parameters
Posted by news.verizon.net at 1/22/2004 3:04:11 AM
I have a form with 5 strings serving as search parameters.
I collect them from the form, store them in local variables and call a
stored procedure executing a select based on these parameters
When the parameters are left empty in the form, I nees to make a select
without conditions on that param... more >>
Problem sending values from one page to another (pepehammer)
Posted by Marcelo at 1/22/2004 12:59:49 AM
Hi guys, I'm using the following code to send values from one page to
another, but seems to me, that the event Page_Load in the receiving page
never fires.
Why?
This is the code:
Thanks
-*-*-*-*-*-*
PAGE SENDING THE INFORMATION
<%@ Page Language="vb" AutoEventWireup="false" Codeb... more >>
DataSet to Text File
Posted by scorpion53061 at 1/22/2004 12:17:28 AM
Well I had a way to write an array to an excel spreadsheet but on a huge
time critical run it failed iwth the dreaded HRESULT: 0x800A03EC error. It
worked fine when i sampled the data to go in but when it all tried to go in
it bombed.
So I need to write this to a tab delimited file and I sure ... more >>
|