AllExperts > Visual Basic 
Search      
Visual Basic
Volunteer
Answers to thousands of questions
 Home · More Visual Basic Questions · Question Library  · Free Encyclopedia ·
More Visual Basic Answers
Question Library

Ask a question about Visual Basic
Volunteer
Experts of the Month
Expert Login

Awards

About Us
Tell friends
Link to Us
Disclaimer

 
 
 
About Robert Nunemaker
(Top Expert on this page)

Expertise
String manipulation, Database access and usage, Class creation, and encapsulation are my strong suits. Active X Controls and DLL`s also. Although I don`t deal with Crystal - frankly because I don`t like it; I prefer to do things manually.

Experience
Employment history: Programmed with the Air Force for 15 years, and have continued in the private sector for the past 1 year. Used VB (all versions) for the past 8 years.

Organizations: MCP and MCSD certified.

Education: Computer Science Bachelor degree.

Awards: MCP and MCSD certified.

   

You are here:  Experts > Computing/Technology > Basic > Visual Basic

Questions Answered By Expert  Robert Nunemaker 
In Category  Visual Basic

SubjectDate Asked

Searching Word for Word 2007 Text Boxes and Printing Contect to a File1/27/2009
  Q: Back on 4/28/07 on this forum Jonathan Roach provided the code below for printing the content of a ...
  A: In Word 2007, text boxes are slightly different. They are "Shapes". So, use: Dim Doc As ...
Find data between Dates1/9/2009
  Q: I am using Microsoft Access as a database and VB 6 as programming language. In Access I have a ...
  A: Your dates need to be wrapped in "#" symbols if they are true Date or Date/Time fields. Example: ...
Very Ungent help Required1/8/2009
  Q: I have a immediate requirement for one of my client. the requirement is the jpeg images are loaded ...
  A: You could do this with a LOT of work with an Image or Picture control. However, there are ActiveX ...
Batch commands1/7/2009
  Q: Hey Robert, First of all, my question isn't in a field you list as an expertise so you are excused ...
  A: I'm sorry, but I'm not a batch file Guru as much as I used to be. However, a few things. - When ...
attempt to make EXE, I get a out of memory error1/6/2009
  Q: i have a large VB6 project which runs & compiles in IDE, but when I attempt to make EXE, I get a out ...
  A: Your computer likely doesn't have enough memory. You probably only have 1 GB? Try closing ...
about ranking9/13/2007
  Q: I have a database with a field total marks in ms access and connected to vb. Now I want to ...
  A: You say it's already connected to VB. So just sort it how the rankings would be by (i.e. score, ...
BACK UP AND RESTORE DTBASE9/12/2007
  Q: I AM MAKING A SIMPLE APPLICATION WITH VB USING DATABASE ACCESS.MDB, BUT I DON'T KNOW HOW TO BACK UP ...
  A: Backing up is easy as long as you decide upon a naming convention. For example, say you want to ...
HTML mailing code9/7/2007
  Q: I'm looking for some free VB6 code for editing and sending HTML mails with embedded images that can ...
  A: Your request is rather generic. Do you want to use Outlook, Exchange, or SMTP? But, if you want to ...
EXE FILE9/6/2007
  Q: HOW TO CREATE AN EXECUTABLE FILE USING TIMER CONTROL IN VB6.0
  A: I don't know what it is you want to accomplish, but the below is an example: - Create an empty form ...
viewing data from text file9/3/2007
  Q: i have form with 3 text boxes and command button. i can save data from text boxes to text file by ...
  A: I don't quite understand. Are you saying you want to read from that file and then display the ...
String conversion3/16/2007
  Q: I need to convert some strings: for example string1: R1K1+R1K2+R1K3+R1K4+R2K1+R2K2+R2K3 string2: ...
  A: Not too tough as long as you have consistent formats in. Try the below function. Call with: ...
Access Reports in the BODY OF email message automation3/12/2007
  Q: I was wondering if you could help me with the following code. I'm trying to output Access report in ...
  A: You can't put a database as part of the BODY of an email. Only text or HTML. Even HTML is tricky ...
deleting folder using vb code3/3/2007
  Q: Respected Sir, how to delete a perticular folder which is present in my hard disk using vb6.0 code. ...
  A: BTW, I notice you were the one who asked me about querying a CD drive's files. You do know you ...
how to show cd files in vb3/1/2007
  Q: Respected Sir, I have doubt in vb how to show folders and files IN LIST BOX which are present in ...
  A: Believe it or not, you can do this with 3 lines of code. There should already be 3 controls in your ...
Adding runtime controls or forms2/28/2007
  Q: I am trying to create a program that creates a custom form while the program is running depending on ...
  A: Sure. I'll let you figure out how to do how many you want and placement on the form. But creating ...
Starting external batch program from VB2/26/2007
  Q: I currently have a program wirtten using VB6 that outputs infomation to a text file located on the ...
  A: Sure, it's simple. But wouldn't it be easier to just check for the existence of that file name and ...
MS Access Autonumber issue2/19/2007
  Q: I have a simple question. I have created a table in Access with field "id" as primary key and I ...
  A: Unfortunately, it's not straight-forward though it's also not difficult. Create your table with an ...
Visual Basic(vb+MSaccess), Iam an Inter2/16/2007
  Q: Your solution for my previous question is working wonderfully. Thanks again. My next 2 questions are ...
  A: In your first query, you say you are looking to "Update" the description field. If that's the case, ...
sstabs2/14/2007
  Q: ive included an SStab control on my form. Now i realised that i have 1 tab that i dont need but am ...
  A: You've stumbled upon a limitation with this control. Once you have the tabs, removing one is ...
VB in MS Access2/9/2007
  Q: would you be able to give me the code i could use in MS Access so when someone edits the data and ...
  A: This is actually a very difficult thing in Access because they've tried to do it all for you. So ...
VB6 Listbox control question...2/8/2007
  Q: For every item I add to a listbox, I would like to assign a specific value for each item. How do I ...
  A: If the value is a numeric value such as an ID or SSN, then you can just use the ItemData collection ...
Linking to DLL Created in Visual Fortran 62/5/2007
  Q: Sorry I wasn't clearer before. The '*' in '*.dll' is just a placeholder for the real name ...
  A: What does your Declare statement look like? Obviously if you have a full path on it, that's where ...
Visual Basic(vb+MSaccess), Iam an Inter2/4/2007
  Q: Sorry to meet you after a long gap. your small help is a big solution for my pblm. so far you have ...
  A: Create an AfterUpdate event for the field using "Event Procedure". Then add the following into it: ...
searching folder in my hard disk and cd rom2/3/2007
  Q: Respected Sir i would like to know how to find a perticular folder in my hard disk as well as in CD ...
  A: Using the FileSystemObject is a much better method as it is exclusively for this exact purpose and ...
multiuser simulteneous database access on network1/29/2007
  Q: I code in VB6.0 I wish to write a program that will run on a small network , (2-3 pcs) and require ...
  A: With so broad a question, I'm sure you know I can't give anything specific. However, multiuser ...
Problem in Accounts Distribution1/13/2007
  Q: There are two list box.In the listbox name lstOpenAccounts there are three hundred values. In ...
  A: I'll let you figure out how to populate your collections instead of my listboxes. I just did it ...
CreateObject hang1/5/2007
  Q: We have an activeX exe that is instantiated in a loop. On almost all machines, it works fine. On a ...
  A: This is tough to solve remotely. However, I would hone in on the machine itself. Unregister and ...
Want to display summarized cost for each group1/2/2007
  Q: related to using user defined functions in access. Thanks a lot. Now i am having problem in printing ...
  A: I really don't do Crystal much. However, I know in Access, you can do this fairly simply by ...
Sql queries12/31/2006
  Q: How can I make a single query that would look like the one below. CientID Client Name ...
  A: If you are saying you don't want the repeating values returned in the result set, that's not ...
Create High Score List12/30/2006
  Q: I am hoping that you will advice; or piont me in the right direction: I made little game in VB and ...
  A: You could use an INI file, but then users would have easy access to it. A better alternative would ...
Transfer the message from outlook to Excel by Macro12/29/2006
  Q: but I have one last doubt ... I created one macro to store the To, CC, Subject, Body and other ...
  A: I don't understand. You don't want "Hi" and you don't want "Regards"? I doubt you don't want the ...
calling select statement with user defined functions12/25/2006
  Q: My problem is that i want to use a recordset with select statement having user defined function. ...
  A: Unfortunately you can't because Access has a SUPERSET of the SQL engine to allow it to inherit those ...
Save listview data12/24/2006
  Q: Robert. I'd like you to help me with saving listview data. I made a program which you add data in a ...
  A: I believe I already answered this for you a few months back. Here is the answer I gave then. Just ...
Transfer the message from outlook to Excel by Macro12/22/2006
  Q: Suppose if I sent a mail to friend.The body of the mail is automatically send to Excel with that ...
  A: Pretty Easy. Create a Workbook with a sheet with whatever name you want (I used C:\MyWorkbook.xls). ...
searching and displaying record12/20/2006
  Q: good day! i just want to ask how to search and display selected record in a textbox in vb.. there ...
  A: The simplist way is by using the VB Data Control. Try this. Add 3 text boxes a Data Control to a ...
chart´s position12/19/2006
  Q: Yes.Actually I get the values for the charts from test*.txt files. But that is not a problem since I ...
  A: Ah! Your problem is that Charts aren't entered into Cells. They are entered into the Excel sheet ...
chart´s position12/18/2006
  Q: Hallo Robert, I want to paste a chart into cell R8 in my excel file named work.xls. The chart is ...
  A: You say you are trying to get your data from test1.xls, but that isn't referenced in your code. I ...
opening pdf files from vb12/16/2006
  Q: i have number of pdf files in my hard disk. i want write a program in vb, like i want to store all ...
  A: Here's a way using API's to display the PDF's that'll work as long as Acrobat Reader is known to the ...
HELP12/15/2006
  Q: ive created a simple databse in access but whenever im trying to access it on Visual basic a pop ...
  A: You're either using the wrong ADO version or the wrong Access connection string. For maximum ...
VB and DBF files12/13/2006
  Q: I have VB aplication with DBF files using DAO connection. Can I use ADO connection and if I can help ...
  A: Sure, you can use ADO 2.1, 2.5, or 2.6. I prefer 2.5 or 2.6 because they have a couple more ...
VB Runtime error -2147217887 (80040e21)12/8/2006
  Q: I have developed a program in VB6. It is in a shared mode and working on network. Its works properly ...
  A: You didn't state which kind of DB. But this is actually a generic error number that usually has to ...
Excel 11.0 Object Library12/7/2006
  Q: Robert, Do you know of a help file or api help for the Excel 11.0 Object Library with maybe some ...
  A: Actually, if you go into VBA for Excel (Alt-F11 from an Excel workbook), then go into the help ...
VB6 access of MSAccess Tables11/29/2006
  Q: I am relatively new on VB MSAccess connection. I am able to open the database but i am having ...
  A: You have a number of small problems. First, you shouldn't declare your variables as "New". That ...
string concatination11/23/2006
  Q: i am coding for bank cheque formate. in which i have chop the digits of numeric value and convert ...
  A: It's not really difficult, just tedious. Try this. Create form with a text box named txtAmount for ...
Uploading Excel in vb11/22/2006
  Q: my question is on excel when i run the program that time i want all information will be store with ...
  A: Not too hard. It's not a great way to record your usage. You could simply open a txt file and ...
calculator using functions help11/19/2006
  Q: I am trying to build a basic calculator using the following code. When I click on each number it ...
  A: You've only sent me the calculation code. Not the rest of your code for updating the box. It ...
Dates in VB11/15/2006
  Q: I have developed an application program in VB with Access as B/end. I m storing dates through ...
  A: It's impossible to tell without seeing your code. However, it's obviously a regional date format ...
Visual Basic(vb+MSaccess), Iam an Inter11/12/2006
  Q: I have 2 questions 1) This is an ordinary coding to save new data to database. I want to ...
  A: For your first problem, I couldn't really see everything (such as your CodeSave function). However, ...
Datagrid Sorting11/7/2006
  Q: I am a former VB programmer that left the biz about 7 years ago. Now, for my small office, I'm ...
  A: Not sure why you are using code if you are using the ADO Data Control. It naturally binds to the ...
about masked box10/19/2006
  Q: Good day! How can I use maskedit box correctly with adodc? I'm having problems using it in my ...
  A: This means either your mask is incorrect (i.e. use ##/##/#### for the US), or your data has errors ...
Database access10/17/2006
  Q: am a beginner of VB. i need to know the code to find a value in a database. am using two tables in a ...
  A: If I understand you correctly, you want to see if a value is in a table, and if so, replace it. If ...
VBcodes Encryption and decryption10/14/2006
  Q: How to encrypt and decrypt a string
  A: This is really too general. If all you are looking is for a cursory way of encrypting a string, ...
selecting a Datagrid row in code10/11/2006
  Q: Good day! Is there a way to automatically select an entire row by using a command button? Hope you ...
  A: Sure. Just use the Bookmarks collection of the ADO control bound to the datagrid as in below. ...
about visual basic listbox sorting10/10/2006
  Q: .it helped me a lot. here's another one.. i use 2 textboxes to add items & item amount on a ...
  A: Since you are putting them in the same entry, I would just grab the applicable text for the line. ...
VB6 Update10/9/2006
  Q: How can i update the datebase with flexgrid? tnx
  A: You can't directly because it wasn't designed for that. The DATAGRID is what is designed for ...
dbf files with dao10/7/2006
  Q: I have developed a program of stock correction for which I have used access as back-end and VB as ...
  A: There are multiple DB formats that use DBF files. Dbase and FoxPro come to mind. However, for ...
about visual basic listbox sorting10/6/2006
  Q: how can i sort words ascendingly & descendingly in a listbox using a command button?
  A: Ascending would be easy by just setting the Sorted property True and Refreshing the listbox. ...
VB6 recordset problem10/3/2006
  Q: I have successfully used your suggestion to work around the problem. However, the database continues ...
  A: It really isn't possible to say without seeing your database. However, I would still check the ...
VB6 recordset problem9/30/2006
  Q: The following code initially appends new records sequentially at the end of the recordset. After ...
  A: Databases are sequential in nature. So if you add a record tomorrow it goes to the end. HOWEVER, ...
cmduncan@jcis.net9/29/2006
  Q: Access Automation with VB6I have seen many answers to this question and tried to implement them. I ...
  A: I tried your code and it works fine. I would recommend first trying Access itself and see if you ...
Text Format9/28/2006
  Q: i am new to vb and iface difficulties when format the text in the textbox in vb.my program require ...
  A: For your first requirement, just use the Microsoft Masked Edit control. If you can't see it in your ...
VB for Word Form problem9/25/2006
  Q: Ok, here is the scary part. I almost understood that. One semester of VB, years ago. My fields ...
  A: The sequence doesn't really matter. But the names do. Also, the error checking I have just in case ...
copy data in excel from sheet 2 to sheet 19/24/2006
  Q: I'm trying to copy data in excel from sheet 2, column D, rows 1-46 to sheet 1, column C, rows 3-48. ...
  A: For the copy/paste, print, and close portion, it's pretty simple. Try this code: Option Explicit ...
VB for Word Form problem9/23/2006
  Q: Robert, I hope I have not already sent this to you. I have a MS Word Form with 175 form fields. ...
  A: I don't really mess with Word VBA that often, but it's just getting to understand the object model. ...
deploying a .net winforms that has to connect to remote sql server9/22/2006
  Q: I have a windows application vb.net (2005) that uses a sql server database. I am having problems ...
  A: Why not include your connection information (server, database, userid, password [encrypted unless ...
saving new data9/19/2006
  Q: Firstly you are certainely right when you said "The EXECUTE method is only used for an action ...
  A: The only reason the IF block would come back false is because it doesn't select a record from your ...
Picture box in VB9/18/2006
  Q: I am using Visual basic 6.0 ,my question is how to put horizontal and vertical scrollbar in a ...
  A: Not too tough. Here's a technique I learned a while back. The key is to have TWO picture boxes on ...
VB6 & Power Point9/16/2006
  Q: i am trying to view a power point presentation thru a Visual Basic program. It works fine when ...
  A: Not too hard. You just need to use an API to get the applicable file association. This way, if ...
vb retireving data from ms sql9/15/2006
  Q: wish to write a vb program to access the tables in ms sql, and retrieve some data. pls provide some ...
  A: First of all, this is a very generic question. I can get you a couple of lines of code, but you ...
saving new data9/14/2006
  Q: I am beginner in VB6, I developed a small program. I need to save the data from the text into access ...
  A: I'll assume your connection is happening correctly. But you have a number of problems with your ...
CDATE9/13/2006
  Q: I go nuts here. Trying to solve a Excel 2003 problem with VBA. I need CDATE or other solution that ...
  A: It's semi-easy. Just create a table in your sheet or another sheet with the month numbers and their ...
vb data grid9/11/2006
  Q: Need your help on vb data grid, i include these code in mly project however no error display and the ...
  A: I don't know your database so I can't tell for sure. But if you get no error, then I think the ...
Call dll procedure from MS Access20039/10/2006
  Q: i am working on a project that need to call dll and display data every 2second. i would appreciate ...
  A: Calling the DLL is no different in Access as in any other VB app. Just use Tools/References to find ...
Call dll procedure from MS Access20039/8/2006
  Q: i am working on a project that need to call dll and display data every 2second. i would appreciate ...
  A: Your question is far too generic. However, some code similar to this will work for you. The code ...
visual basic databases9/6/2006
  Q: I'm developing an application for an order management system.The application uses VB as the ...
  A: This is far too general and complex. You must be more specific. It depends what you want to do ...
writing a macro script9/5/2006
  Q: I am trying to learn how to write a macro script for the iopus.com software. I was wondering if you ...
  A: While I don't want to get into the full code of something like this (that takes the fun out of it, ...
MiDocView Control6/8/2006
  Q: Have you used this control before? I am having problems getting to work. Do you have any sample ...
  A: I'm not very familiar with this control. However, I've put the objects and their methods below. ...
vb66/7/2006
  Q: i am using vb6. i have 7 command buttons and 1 label. i want to be able to click command1 and the ...
  A: This sounds like a homework question. I'm not sure I understand. You just want to add a specific ...
Strings vs singles4/6/2006
  Q: Using VB5 Win98SE. I have a text field in my table with the following data: V1*V2*10 If I assign ...
  A: Not too tough. Here's a formula to do just that. Below it is the sample code to call it. It's ...
Visual Basic 6.0 datagrid4/3/2006
  Q: I am Marcos and I need help urgently if u please, I have a program with a master-detail relationship ...
  A: Datagrid is intrinsicly local-bound until you actually pass the updates. The easiest way to do this ...
VB Code3/20/2006
  Q: Sir, I want a VB Code to delete all the following files in the given order. Temp files Temporary ...
  A: Believe it or not, the 2nd on your list is rather difficult. That's because even though you can see ...
Download MSACC8.OLB for Visual Basic 6 programming3/19/2006
  Q: I have Windows XP Prof.Ed., Office 2000 professional edition and Visual Basic 6 Prof.Ed. Where can I ...
  A: Why not use DAO 3.5? That's actually the proper way and much more efficient. You should already ...
vb .net - datagrid binding question...3/10/2006
  Q: I got it to work using run-time binding as opposed to design time... I kept getting some crazy error ...
  A: This is one aspect I always felt should be a simple property. You have to define a tablestyle for ...
vb .net - datagrid binding question...3/9/2006
  Q: I am brand spanking new to vb.net and I am trying to do something really really simple - just to get ...
  A: You're almost there! You just need to right-click the Data Adapter and click Generate Data-Set. ...
VB 6.03/8/2006
  Q: In one of my project I want to print some lines in parallel port 1(LPT1). For this I used the ...
  A: There could be a number of reasons for this. Maybe the computer doesn't have a default printer. ...
Visual Basic Compatibility with Firewall Protection3/6/2006
  Q: We run an accounting program written in Visual Basic especially for our small business. We cannot ...
  A: This definitely does not sound right. Either he doesn't know or isn't willing to invest the time to ...
Auto Play3/5/2006
  Q: I want to create an application in vb such that as i execute that application a video file should ...
  A: Here's another method that might be simpler if you want them to have control. If you don't, just ...
connection with sql3/3/2006
  Q: i am wanna to make a connection with sql please tell me how this is made and what is the code for ...
  A: It can be done in a number of ways. Depends on if you want integrated security (windows ...
VB Code to search and display hidden and unhidden duplicate files2/24/2006
  Q: I want a VB Code which searches for a file on all drives(including folders and subfolders) and ...
  A: You can of course use the File System Object and call it recursively. But it's 5X or more slower ...
incorrect syntax error2/23/2006
  Q: i encounter this error msg " Run-time error '-2147217900 (80040e14) Line 1 : Incorrect syntax near ...
  A: What you have appears to be fine. So it depends on how your SQL is formatted; if it's a Command ...
String manipulation in EXCEL2/22/2006
  Q: I have a set of strings like the following: "1  User xxxxxx authenticated for application" in an ...
  A: VB or VBA? Save how? Either way, it'll be pretty much the same. Also, can the XXXXXX have spaces ...
changing the font for just a part of a textbox2/17/2006
  Q: is there any way to partially change the font or the fontclolour in a textbox? i have a database i ...
  A: Sure, very easily. Here's some code below to change the colors so you can get an idea about it. ...
Month Increment2/16/2006
  Q: I am developing a small application for Cheque Printing, If printing command is given for multipule ...
  A: Sure, just use the DateAdd function. Here's some sample code you can use. Good Luck! Dim nLoop As ...
Visualbasic2/15/2006
  Q: i developed a vb application billing software. how to prevent the piracy? is it possible to prevent ...
  A: Preventing piracy is directly proportional to how much effort you wish to put into it. If someone ...
Send SMS2/9/2006
  Q: Robert, I am watson, who is trying to develop an SMS application. I want to send and receive SMS ...
  A: No use trying to reinvent the wheel. I have a Class pasted below that I've used in the past. I ...
User Defined Type>64K2/8/2006
  Q: I have a compile error "Fixed or static data cant be larger then 64K". Is there an 'easy' way round ...
  A: What this means is that your fixed and static data (fixed strings, constants, fixed arrays) in your ...
arraylist or vector2/7/2006
  Q: ive been using Java for a few years now and have used a vector in this language as a reliable ...
  A: You haven't stated what version of VB you are using or the purpose for your usage. But in .NET, you ...
Program will not run2/4/2006
  Q: I have a file kiosk.exe that has several files associated with it. Thay have extentions of .glf and ...
  A: I'm sorry, but I need a LOT more information. If the file is opened exclusively, you could get this ...
SSTAB Back color and Tabcolor1/22/2006
  Q: How can i change the back color of an SSTAB control and also the back color of the tab in visual ...
  A: I already answered this, but it may not have made it through the system. You really can't with this ...
Multiple programmers same project1/17/2006
  Q: What is the best way to have multiple programmers working on the same project. Is there a way to ...
  A: There is no real facility for doing this in any language. Not simultaneously anyway. BUT, the ...
Debugging with Form_Paint1/9/2006
  Q: I am a VB6 programmer, but have a small issue when debugging code where a Form_Paint event is ...
  A: You're a victim of recursive calls caused by your own code in the Paint routine. To fix it, you ...
Visual basics1/6/2006
  Q: Who invented Visual Basics?
  A: This sounds like a homework question, but ... A dude named Alan Cooper is credited with being the ...
Comparing 2 files1/4/2006
  Q: "Hi, I'm using VB 6 and would like to compare 2 .csv files. If there are any differences I would ...
  A: A CSV file is just a text file, so you could just compare them that way. However, if you want to ...
Beginning Programming8/5/2005
  Q: i am a real real novice.. Will a basic vb.net book be a good starting poit.. do you have any ...
  A: Definitely. Deitel makes books for Experience and novice programmers. But there are MANY of them. ...
Treeview control problems...8/4/2005
  Q: I am really new to the treeview control and I have been unable to find what I am looking for on the ...
  A: Sorry it took so long to answer. I never got the initial email. You need recursion in one magic ...
Beginning Programming8/3/2005
  Q: I have been working mostly in the print trade. However i have always had a keen interest in ...
  A: Visual Basic .NET would be my recommendation because it's the newest flavor of Visual Basic and VB6 ...
ActiveX socket problems8/2/2005
  Q: Im using an ActiveX control in my program to automatically manage XML and socket connections. I ...
  A: It's very difficult to tell without actually debugging. But I suspect what's happening is that the ...
Manipulating files in VB8/1/2005
  Q: I am trying to automate the following in V.B 6.0: 1. I Create a file in excel (saved to an ...
  A: Pretty easy. Just use a routine something like this and pass it the path name. You'll need a ...
Navigation Pane7/30/2005
  Q: I often have to use navigation pane of database,including first,last,next,previous buttons...find ...
  A: Not sure what you mean. Are you talking about the Data Control? It already has those buttons and ...
on error7/28/2005
  Q: i have project written with visual basic 6.0 ,using sql data base. when there's an error ,the system ...
  A: Why would it take a lot of time? You either use On Error Resume Next and put If Err.Number <> 0 ...
GIF7/27/2005
  Q: Is it possible to save a picture in a picture box that has been created in runtime from the .Image ...
  A: You can only save a picture in a picture box in the same format it was loaded as. So, if the ...
Filling forms in IE using VB7/25/2005
  Q: I am using Microsoft Visual Basic 6. I just want to ask how can I fill in information into a website ...
  A: You can't. That's what site security is for. Otherwise, anyone could get a secure webpage, spam it ...
vb7/22/2005
  Q: sir, how r u my problem is in the code given below i am using ms access database ...
  A: It's hard to tell without seeing it and knowing your schema. But, it would appear that the field ...
Retrieve data type from Databases7/20/2005
  Q: glad to know there's such forum. I would like to check with if there any way i can retrieve data ...
  A: Very easy. Whatever the column is, just query one of the system tables. So, if you want column ...
Class creation7/17/2005
  Q: I am quite new to class module in VB6. Could you please tell me what the syntaxs are to create a new ...
  A: It's rather easy to create a class as you probably know by just right clicking the project file and ...
spinner button controls7/14/2005
  Q: I am trying to creat a simple text box that is linked to 3 spinner buttons I want one button for ...
  A: Pretty easy. Here's a sample. First, create a project file (PROJECT1.vbp) with the following: ...
Reading a Text File and adding Carriage Returns7/12/2005
  Q: First of all, I like to thank you in advance for any help you provide. I have a text file (lets ...
  A: Provided your files aren't massive (MB's in size), the below should be quick and easy. Hope this ...
Left and Right string operators7/11/2005
  Q: Why do I get an error message that says, "Cannot refer to an instance member of a class from within ...
  A: Probably because you don't have the keyword SHARED in front of the Sub it is calling. The class ...
randomize7/10/2005
  Q: How can I use "Randomize" instruction? What is difference of "Randomize" and "Rnd()"?
  A: The two statements are actually used together. Randomize simply "initializes" the Rnd function. ...
Excel and VB programming7/7/2005
  Q: I have developed this workbook in excel that has multiple sheets, and a couple of them have simple ...
  A: Odds are it's nothing to do with what you wrote. Rather, what your references were or API calls. ...
enhancing the look of your forms7/4/2005
  Q: I am programming in C#, but l have also used VB as well. All the windows applications I create ...
  A: It depends if you want to pay for the package or create your own. I think a good place to start ...
MDB On Remote Machine7/2/2005
  Q: I want to know the connection string and how to open a recordset if my access database (mdb) is on a ...
  A: You connect the same as you normally do to an Access database. Just use the computer UNC instead of ...
searching database6/29/2005
  Q: I have this question. Ok, lets say you have two database tables, one of the tables is sorted ...
  A: If you are going to compare 2 Text tables, the fastest way would be to do a Binary Search for each ...
vb6/22/2005
  Q: my problem is that i have 4 textbox on my data entry screen i add a code in txtbox change event as ...
  A: Are you saying that you are trying to delete the RECORD? If so, that's probably the cause of your ...
how to connect multi access files6/18/2005
  Q: , I have many access database files, that the appropriate file only be connected with program that ...
  A: I'm not sure what you're asking. If all you're asking is to open the applicable Access file when ...
Visual Basic6/16/2005
  Q: How can I get user name and Password Of Connection
  A: You can easily get the user name by examining the ConnectionString property of the Connection. ...
How do I highlight (select) a row in the data grid control programmatically?6/15/2005
  Q: I am using VB6 and Access2000 to create a program. On one screen I have a standard data grid ...
  A: Try reading it via it's tied ADO Data Control. I've included a sub you can call where you can pass ...
Lost coding of .Frm File6/14/2005
  Q: Yesterday i was coding a file "working.frm"; a saved file. Suddenly, power fell-down and my system ...
  A: Sorry, but unless you had a backup (which you should do at least weekly if not daily), there's ...
Version of windows and style6/6/2005
  Q: I have written a program which was originaly for Windows 98/2000. It is now being used on XP. The ...
  A: I think I understand what you are after. I can give you the API and call to find out the windows ...
Adding constraints on argument values6/2/2005
  Q: I'm working on VB6.0 and here's what I request your help at: If one is using a FileSystemObject to ...
  A: I guess I did misunderstand, because the enumeration is easy to make. As is tying the value without ...
runtime controls6/1/2005
  Q: I have a project and I make sume controls. the user chose difrent controls from toolbar and put them ...
  A: For the name, you really can't change this at runtime because you can't tie events to it. You'll ...
Dear Robert, Hello and thanks...5/28/2005
  Q: Hello and thanks for everything. What's Equql to Design View (that there is in VB6)in VB.NET Please ...
  A: Shift-F7 should still work in VB.NET. But, check your Start Page and click the My Profile tab. ...
Pictures5/27/2005
  Q: I've painted a picture into a picture box control at run time, but when I save it with code, it ...
  A: You're probably saving it with millions of colors. That's the problem with painting it to the ...
Registry, Package & Deploy5/26/2005
  Q: Robert, What is the best way to package a compiled project? I have tried running the Package & ...
  A: I wouldn't worry too much about the Dependency option. That's mainly for when you create your own ...
How to Start VB Programming5/24/2005
  Q: good Expert Hello. How is it doing ? I wish that your are doing well. I read your good experiences ...
  A: I really must say that you will not be able to learn Visual Studio .NET or even VB6 with any skill ...
Built-In Database5/22/2005
  Q: [please do not mind my sloppy english] Its about a week im just searching and asking about this ...
  A: If you need to maintain a database that you DON'T need to have the data to after the program ends, ...
Error Updating Edited Record5/18/2005
  Q: I am having a strange error in one of the forms on my project. The rst.Update method after editing ...
  A: Double-check a little closer. Your recordset may be a read-only recordset. Or, the cursor may have ...
regarding exe5/16/2005
  Q: sir, my problem is as stated below after completion of my vb project for my inhouse client i made ...
  A: My guess is that you just copied the EXE to the client's computer. VB6 is not .NET meaning it is ...
vb5/14/2005
  Q: How can I make a text box or a label that only accepts specific letters e.g. A and B only So If I ...
  A: Very easy. Just use the Keypress event of the text box and use the following code. If you want to ...
Like operator,odbc connection and reports5/13/2005
  Q: I'm using vb6 and want to query my database using the LIKE operator. I'm able to use the operator ...
  A: I can help with points 1 and 2. I'm sorry that I can't help with 3 because I don't like Crystal and ...
View Report landscapely5/9/2005
  Q: my question is that : how can i make the data report to be viewd landscapely? i searched too much ...
  A: You didn't state if it was an Access report or a VB Crystal Report. If Access, you can use the ...
vb5/8/2005
  Q: How can I calculate the total of numbers that are stored in a text file using a command button and a ...
  A: Please don't take this the wrong way, but this sounds like a homework question and one that you ...
Designing Reports in VB65/7/2005
  Q: Robert, a lot. A great help. However, if you can shed some more light on the issues below, I shall ...
  A: 1. Unfortunately, there is no way to do what you ask. VB was essentially just a platform to "goose" ...
disadvantages5/4/2005
  Q: What would be the disadvantages if a COM service is run on "Local System” account and not as a ...
  A: While I can't give you a definitive Microsoft type answer, in my experience, the difference is what ...
Windows scrollbar5/3/2005
  Q: i have a simple question, how do i change the size of microsoft windows xp scrollbar using vb.net ...
  A: As far as I know, you would need to use the Windows API for this type of control because I don't ...
Opening a File in VB 54/22/2005
  Q: I am creating a program in Visual Basic 5 - Learning Edition. In my program i have already been ...
  A: Not sure why you would want to do such a thing. But, just "calling" it won't launch it. What you ...
multi level sort of an msflexgrid4/19/2005
  Q: i need to know how to apply more than one level of sorting on a flexgrid i have an msflexgrid with ...
  A: The keys used for sorting are determined by the Col and ColSel properties. Sorting is always done in ...
String4/17/2005
  Q: How to example: str = "az001 webpage homepage email" I want to get a string "webpage" and str ...
  A: There are a couple of ways of getting this. But the most flexible way because it'll handle changes ...
hardware access4/16/2005
  Q: 1- hi 2- how could i read a serial number of a hardware , like mainboard , hard disk ..... 3- ...
  A: This has always been a problem for VB developers. You can get a freeware or shareware control to ...
vb crystal4/11/2005
  Q: sir , my problem is very simple i want to add crystal report control on my form so i opened the ...
  A: If it cannot lod the control, either it doesn't exist on your system (verify with Explorer), it ...
VB and SqlServer Locking4/9/2005
  Q: Using VB6 and SqlServer2000. I want to do like this: Suppose one user has given a query "Select * ...
  A: First of all, I definitely would NOT recommend this. This is normally a poor programming process ...
vb4/6/2005
  Q: sir first i will show u some code Private Sub cmdDelete_Click() On Error GoTo DeleteErr If user1 <> ...
  A: You should definitely move up to ADO 2.5. There are performance gains with it as well as quite a ...
vb4/5/2005
  Q: sir first i will show u some code Private Sub cmdDelete_Click() On Error GoTo DeleteErr If user1 <> ...
  A: This is usually a problem with the Version of ADO you are using. You can either drop-down a version ...
ado and remote database connection3/31/2005
  Q: Dim con As Connection Dim rs As Recordset Private Sub Command1_Click() Set con = New ...
  A: I have to be honest; I've never done that before. However, something I would try is to use a ...
Resource in VB3/30/2005
  Q: .. Do you know how to use RESOURCE in Visual Basic? I mean, how can I "insert" bitmap, sound, etc ...
  A: I've never been a huge proponent of these because what's the harm in just distributing the Bitmap, ...
String Manipulation3/29/2005
  Q: While using the Left,Trim,Right,Format function in VB 6.0, we are getting a "Expected Array" error. ...
  A: The only time you'll get that error is if you are using them as embedded functions in another ...
Viewing IE's session cookies3/26/2005
  Q: Hey, Bob! This is daru, an expert from PHP category. I've got a very hard question for you. There ...
  A: If I understand you correctly, you just want to find the applicable cookie, open it, and then drill ...
Trigonometric Functions3/25/2005
  Q: Robert; Could you please tell me how to write the following functions in VB: Cos^3(aº-bº) and ...
  A: Sure, try this function: Public Function GetCosignValues(ByVal nAngle1 As Single, Optional ByVal ...
vb3/21/2005
  Q: my error on running following code is multiple step operation generated errors check each status ...
  A: I presume the .DELETE is the line causing the problem. I've come across this line before and 2 ...
Coding Servers3/18/2005
  Q: I am a bit confused as to how to code a server using VB.NET. What is the difference between an ...
  A: This is a bit involved and possibly some beyond my knowledge (hey, gotta be honest, right?), but ...
vb3/17/2005
  Q: my question is related to textbox event which is change event sir please tell me the format of ...
  A: The Index argument will only be included if you have created a TextBox array. Meaning, you created ...
guid3/16/2005
  Q: How do I get a new GUID in VB?
  A: You didn't state if this was VB6 or VB.NET. In VB.NET: Public Function GetNewGuid As String Dim g ...
vb6 comboboxes3/15/2005
  Q: i'm a vb6 beginner, im trying to work on an aplication that will ask input from the user, Im triyng ...
  A: For your first question, it really depends on the purpose of your program. Take for example that ...
Listbox individual item3/14/2005
  Q: I'm using VB6 with an Access 2002 database. I am about intermediate (new to VB and Computer Science ...
  A: Actually, if you use a ListView control instead from the Windows Common Controls Component, you ...
GB BANDWITH3/13/2005
  Q: PLEASE, I KNOW NOT MUCH ABOUT COMPUTERS. WHAT IS DIFFERNCE BETWEEN BANDWITH SIZES SUCHA AS THIS GB ...
  A: This isn't really VB programming related, but I'll take a few minutes to answer. A byte is a ...
vb3/10/2005
  Q: sir i will be very grateful if u solve my problem my problem is that on a vb form i declared no. of ...
  A: I'm not sure I understand. Are you saying your textbox is only showing 12 after you enter 12.12? ...
Query Help3/8/2005
  Q: Sir, I am developing one software using vb as frontend and oracle as backend.When i am taking ...
  A: Your SQL looks fine to me. However, step through your code and do 2 things. First, after the ...
Play AVI from resource3/7/2005
  Q: this is mywith Visual Basic how can I play an AVI file (with sound) taking the file from a resource ...
  A: I don't know if you intended on playing it through the Multimedia control, or using API's, Windows ...
VBA MS Access3/6/2005
  Q: I want to open form with all record but to go to the record with [ID]=2000. I need to go to specific ...
  A: You actually asked the question in the wrong room. However, whereever you are deciding what record ...
store range of values3/4/2005
  Q: How do I mention a range of values in a field in MS access? For instance one of the fields in my ...
  A: You don't store ranges in your database per se. In your case, all you'd do is enter the ceiling ...
regarding date function3/2/2005
  Q: actually my problem is when i run the following code if not isdate(mdate) then message("enter the ...
  A: I couldn't duplicate this. It always validated correctly. However, what are your settings for the ...
Visual Basic with Seagate Crystall report2/22/2005
  Q: I am Using Visual Basic 6 with Seagate Crystall report 7.00. When I am making the package by Package ...
  A: It's quite possible that the installation isn't picking up the file as being needed. Ensure that ...
vb2/20/2005
  Q: I want to display only one double quote (") because I am using Nepali font and " is one of the ...
  A: For the quote problem - if I understand it correctly - you want to display a single double-quote in ...
Encryption and Decryption2/18/2005
  Q: I'm writing a program, in VB 6.0, that parts of which requires a password to gain access too. These ...
  A: First, if your program is DB oriented, the password should be stored there since you can control the ...
variant data type trouble2/15/2005
  Q: I use vb 6. In my project i am using varables with byte data-type.My problem is some of these ...
  A: Without seeing the rest of the program and/or the data, it's very difficult to say for sure. ...
hi,I use visual basic 6.0...2/12/2005
  Q: I use visual basic 6.0 and work mostly with hex data. i use the format instruction to ensure that ...
  A: Not sure what you are after, but have you tried: Format$("0" & YourHexNumber, "000") BTW, if ...
data compression2/11/2005
  Q: I am working with Visual Basic 6.0 SP4 and AppForge Mobile VB 4.0 I would like to compress data in ...
  A: The only way I can see to do something like this is to put the database in a Windows compressed ...
Date Textbox2/10/2005
  Q: I am facing a problam for saving date by textbox, When user feed date in dd/mm/yyyy format ...
  A: This is a problem that has vexed programmers for a while. The issue is something that Microsoft put ...
Picture Boxes2/8/2005
  Q: I'm just wondering how I can overlap the contents of two picture boxes, but with the top picture ...
  A: It's rather involved to explain, so here's some code for you to load into a test project. I can't ...
Picture Boxes2/7/2005
  Q: I'm just wondering how I can overlap the contents of two picture boxes, but with the top picture ...
  A: If you are using VB.NET, it's fairly easy. If VB6, it's fairly difficult. For VB6, there are 2 ...
string manipulation2/5/2005
  Q: Access 97 How would I utilise strings and sub strings and is it possible to sort them in various ...
  A: You would need to give me an example of what you are talking about. There are many algorithms ...
vb62/4/2005
  Q: How can print the numbers in words. For example 10215 should be printed as "Ten thousand and Two ...
  A: Essentially, you just parse the number taking care to know where every 3 digits end. Since no ...
VB1/29/2005
  Q: I am from Nepal. And my Question is : I want to display " sign in the label. How should i display ...
  A: Are you talking dynamically from code? If so, you simply include 2 of them. For example: ...
Open Browser1/28/2005
  Q: I want to open default internet browser in a new window with the given URL. How can I do that? The ...
  A: This has long been a problem within VB6 and is only cured with a third party control. You can of ...
connecting MS Access reports with visual basic1/26/2005
  Q: our respected expert.. if I may ask you... I made a database by using MS Access to connect it with ...
  A: Unfortunately, this isn't possible. The Crystal Reports within VB is a special DLL version of it ...
Working with Access and Print1/24/2005
  Q: I have a table with 6800 dealerships and a table containing participants who receive awards. I have ...
  A: It sounds like all you've done is bind a grid or dataform to the table. What you need to do is for ...
doubt in tapi control1/21/2005
  Q: hai I already created a project in vb6 using mscomm control to make a call from the system.I even ...
  A: I can't really help with this as it's really involved. However, I do know there are a number of ...
running a text box1/18/2005
  Q: hai I need alabel control to run like a marquee in windows screen saver. it shd run from right to ...
  A: This is a case where it's easier to see it happen and the code than to explain. It's pretty easy ...
Is 100% Reliable MS - DT Picker1/14/2005
  Q: I have faced a problem With DT Picker, When Date picked from DT-Picker in Form the format was ...
  A: Don't know which database you are using, but that's actually pretty desireable. Your database will ...
VB61/13/2005
  Q: How can prevent writing CD using VB6 ?
  A: In what way? You don't want them saving to a CD from your program? If so, you can just use the ...
Leave Calander1/12/2005
  Q: Please Guid me abt. : A Dynamic view of leave status by Calander In an Employee leave manager form ...
  A: The only way you could get this is by either using a third party calendar control, or by interfacing ...
copy a record1/9/2005
  Q: I am working on a project with VB6 and ACCESS. How I can copy a complet record from a table to ...
  A: You'll want to open both databases at the same time using DAO if possible (DAO is more efficient ...
ADO Connection Optional1/8/2005
  Q: First of all many - many thanks for replying my last Quest. abt Search Table, Here is another ...
  A: You didn't mention how you want to connect to each. Security, trusted, etc. However, assume your ...
Database Path Variable1/7/2005
  Q: I'm using VB6 to create a database Application with ADO. I need to allow users to set the database ...
  A: This type of functionality is actually something I have in a functions library for many programs. ...
Search Table1/6/2005
  Q: How can we search a particular Table asked by textbox if table not found it should reply. Thanks
  A: First, rather than a text box, you should use a combo-box and populate it with the table names. ...
Strings might be bringing me down.1/5/2005
  Q: I'm using VB 6 and doing a lot of string manipulations and I am having troubles, kind of. I am ...
  A: I strongly doubt it. The worst you would get is a Out of Memory or Out of Stack Space error. Your ...
Calculate Sunday12/31/2004
  Q: How can we calulate sunday in any month of any year. Thanks
  A: Not too bad. Here's some code. I put in a check for the LAST desired day of the month too because ...

All Questions in This Category

Email this page
     
User Agreement | Privacy Policy | Kids' Privacy Policy | Help
Copyright  © 2006 About, Inc. AllExperts, AllExperts.com, and About.com are registered trademarks of About, Inc. All rights reserved.