Answer Questions
Rahul_1980 Read and write a excel file using Visual Basic 2005
Hi, i need to read and write a excel file using Visual Basic of Visual Studio 2005. I try to do it like i had done before using Visual Basic 6 but it didn't work. Please give some ideas to do this Another article which shows communicating with an Excel spreadsheet is http://support.microsoft.com/kb/q301982/ You need to star by making a reference to the appropriate XL library...see these sample for further details: http://msdn.microsoft.com/vbasic/downloads/code/101samples/#vsto Thanks guys, I did it following the instructions of this article ...Show All
xlordt Process not completing
I have a vb form that runs a command line executable that creates a diff file from two existing files. When I run the program from the command line it creates a 419Mb diff file. When I run it as a process from my VB program it gets to ~400 Mb and stops. If I kill the VB program the command line executable continues to run and finishes the diff file. So I have 2 questions. Why does the process stop before for it finishes when I run it inside vb Why does the program continue to run when I kill the VB app. Here is my code Private Sub xdelta( ByVal strFile1, ByVal strFile2, ByVal strDelta) Dim strError As String Dim p As New Process Dim info As New ProcessStartInfo info.UseShellExecute = False ...Show All
Callan how to open ms word in windows application
in my project i have a requirement of opening the msword application and editing and saving this document can any one help me how to solve this problem in windows application . i have VS Pro edition and i want to work MS word inside my application not seperately Unfortunately there is no solution for working with Word inside an application. The OLE control solution is not supported by Win Forms in .NET. About the only alternative is the Web Browser control, but it will not provide the user interface necessary to work with Word inside the application. INFO: Visual Studio .NET Does Not Provide an OLE Container Control for Win Forms If you want to visually display the document t ...Show All
Keith Seifert ToolTip control and DataGridView
I have a tooltip control on my form. The tool tip pops up great for all the other controls on the form except for the DataGridView control. Any idea what could be the problem Sorry, I should have told you before, I did try that option. Does not work. Precisely. I set all properties at Design time. The tooltip shows for all the other controls except for this grid. Not sure if it matters, The grid is "DataBound" , and it is placed on a panel. Well, it works fine for me... So you've added a tooltip control to your form (lets say "ToolTip1"). And then you set the dynamic property on the datagridview: DataGridView1.ToolTip on ToolTip1 = "some text" And then you set DataGridView1.ShowC ...Show All
hawash Question about how to close whole program
Hey guys i have another stupid question 2 ask, apologise for my ignorace once again as this myt seem like a really stupid question. I have multiple forms for my program. I was wondering how i would close the whole program in the third form ( closing all forms) Me.Dispose() This only closes the form that i put this code in. These are just the final touches to my project for school. Would appreciate it if you guys would reply me! THANK YOU!!! :D You guys have been really helpful to me all along. that is correct but 99% of the time it will exit. The times it will not exit is if there are things like threading happening in the background and its still running - once that is complete it will th ...Show All
Paul Verdu Validate textstring as DateTime
Hello , Can this be done in VB2005Xpress Form elements: one TextBox, one Label (TextBox is used to receive Birthdate input, Label displays "<1", "1" "the age which is calculated from Today's Date - Birthdate" or " "). The age formula and the If statement for "<1", "1", "age" and " " is done. Here the TextBox is the choice for Birthdate entry. It is the most cost effective. DatePicker is excellent choosing a future date where the user want to be sure that the Day picked out do not fall for example on Sunday. Click event should be not necessary to display the result in the Label. Birthdate correct form is: ddMMyyyy Cases: 1. User type lette ...Show All
Namrata_Gupta Threading Race
I've got a multithreaded app that I'm working on. The code below is the shell of it. "DoABunchOfWork" is a function that needs to go out and get info from any number of SOAP webservices(this code is stripped for simplicity). I need to create an instance of an object that actually does the communication and run a method on the object. That code is easy as well. The problem that I'm having is with making each of those methods execute asynchronously. I have a race condition where it appears that System.Threading.WaitHandle.WaitAll() is returning before all of the callback finish, thus causing my return value to skew. Anyone lend a hand as to how modify this code so that I don't have that issue. Public Class ActionLayer Private De ...Show All
bikerchick #IF Designer Type Preprocessoring?
I was told to come here and ask this. I'm making an application that has a couple panels and I always run into the problem of where to design all the panels. I hate to resize the boxs all the time to make changes to them and usually work on them outside of the forms main size. Question: Is it possible to do something like this. #If Designer Then Me.ClientSize = New System.Drawing.Size(1200, 1000) #Else Me.ClientSize = New System.Drawing.Size(600, 460) #End If 'This is also used to move panels and such around... my expample resizes the actual form. I mostly want to do this to the panels because i've found that resizing all my panels onload causes a long lag on slower computers when starting up (its the only thing im calling onLoad the res ...Show All
Baldwintm Poor Forethought
I have run into a problem which I should have foreseen. My program lists Part records and their S/N's On my form I have listbox1 which is bound to an Access dB and is filled with S/N's for a given Part number. Listbox2 is unbound and is populated with items from listbox1 so that I can manipulate the list. Now that the list is manipulated to contain what I want I need to get this list of S/N's back to the dB. My problem is I can't get the items from Listbox2 back to Listbox1 because Listbox1 is Bound to the dataset. does anyone have any thoughts as to how I would go about this thanks tattoo I think the problem with that solution is, If I have changed any of the existin ...Show All
atomic Checking File Extension
How can I check a file's extension in a string Like, I have a TextBox1.Text and its text is C:\ProgramFiles\Microsoft\sample.txt. How can I check the "sample.txt" extension if it's .txt or .jpg Try using the System.IO.Path class: http://msdn2.microsoft.com/en-us/library/system.io.path_members.aspx This has .GetExtension() method which returns the extension of the filename in the path that you give it. ...Show All
Anton__ "TrollKit 1.0" - Not quite "Patterns & Practice" Material
I am sure the "Patterns & Practice" team @ MS are squirming about this InteropForms Toolkit 1.0. Honestly, I am a little disappointed in the emergence of this toolkit. Ideally MS should’ve created a migration path process and set of patterns to allow the developer to understand the inners-workings of this Frankenstein type applications. Instead MS decided to give the developer community what I would call a “TrollKit”. What happened to teaching people how to fish, instead of providing them with fishes Please do not use this “Trollkit”, instead take the route of visual inheritance & COM Interop, create your own set of class libraries, add WinForms to these class libraries, and you will be able to do anything with t ...Show All
Bandile Splash Screen... Delay?
Hello, I made this splash screen and since I just started working on my project, the app takes less than two seconds to load and the time for splash screen... .....is not enough.... I have tried to put System.Threading.Thread.Sleep(5000) but where I put it in the code of the splash screen, then it waits 5 seconds before showing the splashscreen and I put it in the main program, then the splash screen is out THEN it waits 5 seconds after the splash screen is gone THEN it loads.... I am very lost... Thank You for any reply! Keehun Nam If you want to change the default splash screen display time, then in the project property's Application page, click on "View Application Events". This will create a new file ApplicationEvents.v ...Show All
Whoisit How to get hold of the linenumber of the line where an error occurred
Hi. I have tried ( in vain ), when executing the VB executable, to find out how to show the line number of the error that occurs. I can access the line number when I'm in the VB IDE environment, but not when I run the executable. Below is the code I use to access the line number ( I also tried lo_stacktrace.ToString(), but again the line number did not show when I ran the executable ) This leads me to the question: Is it at all possible to access the line number when the executable is run Private Function CodeRef( ByVal po_ModInfo As t_ModInfo _ , ByVal po_ex As Exception _ , ByVal pb_ReturnSource As Boolean _ , ByVal pl_FrameNo As Long _ ) As String Dim lo_stackframe As Stac ...Show All
Sheikd DllRegisterServer entry point was not found
I'm trying to use a .DLL file in a program I'm writing, and it comes up with the following error: I am trying to register xvid.dll using regsvr32. xvid.dll was loaded, but the DllRegisterServer entry point was not found. This file can not be registered. plz help. I am trying to register xvid.dll using regsvr32. xvid.dll was loaded, but the DllRegisterServer entry point was not found. This file can not be registered. plz help. I am having that exact same problem. Help!! hai. I am trying to register a Ms-Access assembly using regsvr32. I need to do the Ms-Access application. In that application i need to send and receive email with at ...Show All
ismail-marmoush VB Express target x86 Platform?
I need to target the X86 platorm to use quartz.dll and directshow filters in the syswow64 folder of my XP X64 system. If I start a project in VB5 and then upgrade to VB Express, I get "Configuration:" and "Platform: drop down list boxes. If I start a project in VB Express, I don't get these boxes. How can I get to choose platforms in VB Express Quite a document. Here's the answer to my question: 1.44 References to 32-bit COM components may not work in VB and C# Applications running on 64-bit platforms Most existing COM components are only available for 32-bit platforms and will not run in a 64-bit process on a 64-bit platform (although they will run c ...Show All
