Tag Archives: vb.net

How to evaluate excel formula inside vb.net

Questions: I have a rather different situation in my opinion. I’m trying to write a custom function for an excel based program that I use regularly. The main problem is that you cannot reuse code in terms of having a function and returning an evaluated formula. So i had the idea for the following. I… Read More »

prompt for opening a save dialog for excel file using vb.net

Questions: Iam using visual studio 2012, i would like to open “save dialog” to choose where to save my file instead of using fixed path, the following code is a sample of what i would like to use it in: Private Sub Button1_Click(sender As System.Object, e As System.EventArgs) Handles Button1.Click Dim xlsWorkBook As Microsoft.Office.Interop.Excel.Workbook Dim… Read More »

Need an Excel-like grid in VB.NET [closed]

Questions: I am designing a program in VB.NET that can use an Excel-like grid. I want the grid to be able to handle merging and unmerging of cells. Suggestions? Answers: This Stack Overflow question contains some anserws which could be helpful: What is the best third-party WinForms grid for .NET? You could try Syncfusion’s grid,… Read More »

Excel auto fit column in VB.NET

Questions: I have here my code in VB6 and its working well. For CLms = 1 To 10 ws.Columns(CLms).AutoFit ‘<—Autofilt data on XL sheet Next CLms I have searched on what is the equivalent or alternative on how to make the excel columns width autofit in VB.NET, but I’m still not getting the exact AutoFit… Read More »

How can I overwrite an other Excel-file without the Dialog “Really want to overwrite” in VB.NET

Questions: How can I save an Excel-file, which I’d edit with VB.NE, to a file, which already exists? Evertime there is a dialog: File already exists. Do you really want to overwrite? YES|NO|Abort How can I overwrite without this dialog? Answers: You should have a look at setting DisplayAlerts=false Application.DisplayAlerts Property Set this property to… Read More »

SQL Server database new schema using VB.NET

Questions: Using VB.NET, I successfully created a new database and imported data into a table from an Excel file into a SQL Server 2012 Express database. The new table is created with the default schema dbo. I would like to create a new schema for the database just created (i.e. cad) and assign the table… Read More »

Excel auto fit column in VB.NET

Questions: I have here my code in VB6 and its working well. For CLms = 1 To 10 ws.Columns(CLms).AutoFit ‘<—Autofilt data on XL sheet Next CLms I have searched on what is the equivalent or alternative on how to make the excel columns width autofit in VB.NET, but I’m still not getting the exact AutoFit… Read More »