vb.net

Export to excel in .net

I have following code for export to excel in ReportByApp.aspx page containing crystal report crReportbyApp.rpt Dim outstream As System.IO.MemoryStream Dim strFileName As String strFileName = "Report_" & Now.ToString("MM-dd-yy") & " " & Now.Hour.ToString & Now.Minute.ToString & Now.Second.ToString & N...

In C#/VB, how do YOU determine whether a method is declared normally or as an extension method?

Extension methods are useful for types that you don't own and can't/don't want to derive from and extend (e.g. reference types and interfaces). Obviously, interfaces should be kept as short and to-the-point as possible, so extension methods for interfaces are particularly useful (e.g. LINQ). For classes, especially classes that you own...

How to Depoly Vb.net Application containing Crystal Report and Access Database file

Hi guys, I am trying to build a setup file which will install my vb.net application with database and crystal report files to the client. 1.) I created my vb.net application in release mode. 2.) I created new setup project and added my vb.net application project in that solution. 3.) Also added the primary output in application fold...

Serializable dictionary, how to set key name ?

Question: I use a serializable dictionary class, found at http://weblogs.asp.net/pwelter34/archive/2006/05/03/444961.aspx , to serialize a dictionary. Which works fine, but I run into an annoying problem. <System.Xml.Serialization.XmlRoot("DataBase")> _ Public Class cDataBase <System.Xml.Serialization.XmlNamespaceDecl...

Which softwares for Visual Basic 6.0/8.0/9.0 programming ?

Hey guys, I am a new visual basic learner and I already have some difficulties in finding the proper softwares to start my first programs ;) I will have to develop in vb6.0 and 8.0 (.net 2005) and 9.0 (.net 2008), what softwares do i have to use ? From my search, I will have to use Visual Basic 6.0, Enterprise Edition (or another edi...

FNT font file in C#

Hi all, I would like to know if I can use FNT font file in c# .net. FNTs are not windows font file. If such fonts are available, can you please tell me how to load it and change windows form font to FNT? I use .Net GDI+ technology, but please let me know if WPF is better for this. Thanks, ...

.NET VB How to have Server Listen on Multiple Ports?

I'm writing a very small and simple server that I want to listen on multiple ports. I'm using the below, but connections to port 8081 are not being accepted - any suggestions what I'm doing wrong? (I actually want to listen on multiple ports, I'm not confusing multiple connections) Public Sub StartServer() Dim ports() As Integer...

How to pass integer as Unsigned parameter in VB.Net?

I'm new to VB.Net. I'm using a library call setInstance(ByVal instance As UInteger) in my VB.Net code. The parameter I need to pass is an Integer. Is there anything I need to do to convert the integer parameter to an unsigned integer? The number is garunteed to be positive and less than 10. ...

understanding webrequest GET and POST

I am trying to implement the webrequest get and post methods. I am accessing a secure site that requires login authentication and was told that instead of sending a login request all the time; login to the site and capture the cookie and use this to send it in the header to get results from the page. In other words let us use google for...

Catching mouse events for a custom SplitContainerDesigner

I'm trying to create a user control that will provide a draggable splitter between two panels — exactly like SplitContainer — in a custom IDesignerHost implementation. SplitContainer itself, as far as I can tell, is not an option; it will raise an exception unless used in Visual Studio's Designer. My implementation would look roughly li...

Error when Saving into SQL Server

So here is the error... An error occurred while saving the Panel. System.ArgumentOutOfRangeException: Index was out of range. Must be non-negative and less than the size of the collection. Parameter name: index at System.ThrowHelper.ThrowArgumentOutOfRangeException() at System.Collections.Generic.List`1.get_Item(Int...

What does this really mean: Compiler Error Message: BC30451

I'm getting this error in an open source project that runs fine on a dev machine with iis7, but breaks in iis6. Has anybody else gotten this message or is there a way to decifer it? ...

Create a solution explorer like Visual Studio

I want to be able to create a tree view that can get its nodes form a directory on a computer. In the code below, I am able to get all of the files into a list, but I cannot get the folder correct. What I mean is in your user directory, you have sub directorys such as, Documents, Music, and Pictures. When you run this code, it displays t...

Insert INTO in vb.net

I have 2 databases. In first one I have 10 tables. Second one is only 1 table. I would like to select 1 columns from each table from 1st database and Insert INTO another database. How can I manage this using INSERT INTO statement in VB.net? ...

DTS SSIS- Task Script and Threading?

Dear All, I have written a task script using vb.net that have thread used in the code, the problem is how i can know when will be finished all the threads so i can return the success result. Thanks alot. ...

Problem in threading

I want to use it for a project and I am in trouble. I have a Windows Form in which I started two threads and then close the form and threads continue their works. How can I abort first thread when the second thread stops? I made the first thread IsBackground,but the second thread is not the only thread of program and the first thread is...

GET webrequest parameters

I am sending a GET request to a site and would like to know what would be the proper way to do this based on the following parameters. Host: www.somesite User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.2.6) Gecko/20100625 Firefox/3.6.6 GTB7.1 ( .NET CLR 3.5.30729; .NET4.0E) Accept: text/javascri...

onclick event activation

I am sending web requests to a site and getting the responsestream and would like to perform the button click programatically, here is the tag for the event: <a href="#" onclick="getResults('apple', 2); return false;" id="nextLink" class="next button_grey_sm">Next &raquo;</a> any ideas appreciated? ...

How do I open a folder from CD drive using VB.NET?

Hey, I'm trying to write a program that opens a folder from the CD disk when a button is clicked. The program will be run from a CD, and aims to open a certain folder. However, I can't use "shell "explorer...."" because the drive letter will change between different computers. Is there a way to open the folder straight from the CD in VB...

Converting Number to French

Hi, In ASP.net using VB, how can I Convert a number e.g 4.5 to french (4,5). And a quick question, when storing this in database, will It store as 4.5 or 45? Thanks, Kyle ...