1,372 Posted Topics
Re: Well, Firstly, the slashes should be the other way.... I know in later versions of windows it understands both, but if you run it on a box that is earlier versions of window, most likely ME or 98, it will get pretty upset with you. The keyword to check if … | |
Re: I would suggest putting these skills into a data file, like a text file, or a database. I might strongly suggest that you look into SQL or ADO (you'll find that you will have less trouble with SQL) for this project. I, however, would go with text files (because I … | |
Re: First problem (in form_load): [CODE]me.show main.Setfocus [/CODE] Second: Dunno which box we are talking about... the big multi-line one? Third (on text1's keypress event, or whatever box you do the typing in): [CODE]if keyascii = 13 then keyascii = 0 main.text = text1.text & vbcrlf & main.text end if ' … | |
Re: The easiest solution is to shell a ping command, and redirect the output to a temporary file. Open the Temporary file, and have your VB Program read in the lines (compare using instr) and check if there is a timeout, or if there is a response from the server. If … | |
Re: I know that the API is a fun place to play around, but you should really consider using windows scripting for that task.... [CODE]dim NewValue as string dim WSH set WSH = createobject("WScript.Shell") NewValue = "Whatever you want CD Quality's Value To Be" WSH.regwrite "HKEY_CURRENT_USER\Software\Microsoft\Multimedia\Audio\WaveFormats\CD Quality", NewValue, "REG_SZ" set WSH … ![]() | |
Re: [CODE] Dim oFile as System.IO.File Dim oRead as System.IO.StreamReader oRead = oFile.OpenText(“C:\sample.txt | |
Re: it seems to me like you will need to calculate the height of the shape. So something like [CODE] if shape1.top = 8000 and (shape1.top - shape1.height) = 6000 then msgbox "yup" end if [/CODE] But remember, it might be shape1.top + shape1.height, depending on how you are looking at … | |
Re: Sure, The function is simply "Time", but it comes in a specific format. You can use the format function, to specify the format the time returns for example: [CODE] dim CTime as string CTime = format(time, "h:mm:ss") if CTime = "22:25:00" then msgbox "it's 10:25pm" end if [/CODE] If you … | |
Re: Actually, The second and third link refers to the .NET platform, which would be vb.net. This particular forum is for Legacy Versions of VB (Mostly VB6). He also says that he's new to Visual Basic 6, and so the syntax in .NET would be of no help to him. But … | |
Re: I'm still slightly confused... a for loop in and of itself is a counter, but umn, the error is in your syntanx, it should look something more like: [CODE] for I = 1 to 5 for J = 1 to I ' /* Do Stuff Here For Your Printing */ … | |
Re: That is complicated. I would start by narrowing down the list in your database by file size.... and then looping through the list of files with the same size, and comparing those to what you have. I imagine this process to take a long time, but the next step, would … | |
Re: I can help you with most of the problems you are encountering... however, I'm not sure about a volume control and an EQ. I tried to build an EQ once.... and failed horribly. To this day, I've been unable to figure out how to impliment an EQ with VB. A … | |
Re: I don't remember the exact number, I think at 100 posts you get promoted. I'm guessing this collection concern is for .NET? | |
Re: Or You go power user, and use sockets to connect to the mail server and send the message using the protocol defined in the smtp rfc: [url]http://www.ietf.org/rfc/rfc0821.txt[/url]. That's how I'd go about it ;) | |
Re: Yup. You set the objects back to nothing (destroying them) before you ever use them in the code: [CODE] Dim oXL As excel.Application Dim oWB As excel.Workbook Dim oSheet As excel.Worksheet Dim bolExist As Boolean Dim strCell_Value As String Dim i As Integer Dim num_cells As Integer Set oSheet = … | |
Re: Hmn, Maybe your code post your project in a .zip, or post the code that is relevant to each problem? | |
Re: The character codes for that are vbcr and vblf (also vbcrlf) which translate to chr(13) and chr(10) (those are carriage return and line feed). So, if it would be easier for you to merely check for an occurance of either of those in a string using instr, and replacing the … | |
Re: That's why he makes the big bucks ;) | |
Re: Yes, But it's a lot more detailed and complex than you might think. Basically, I've devised a way using the API (StretchBlt) That shows how you can copy an image from a picture box, to another picturebox, changing size from one to the other. A Few things to note, is … | |
Re: instead of sticking it in the body onload, have you tried calling it in the header of the page: [CODE] <HTML> <HEAD> <SCRIPT LANGUAGE="Javascript"> function some_function() { } some_function(); </SCRIPT> </HEAD> <!-- The Rest Of The Page --> [/CODE] | |
Re: Hmn, I get an invalid zip file.... maybe upload it again? | |
Re: Nice Code Here, But I would Personally Choose a different style. I think you have the right idea by using the word object, but I think you should use the methods of the word object to completely bypass the use of sendkeys (Well, At Least Put To A Minimum). For … | |
Re: Almost sounds like you are needing answers to a homework assignment, but since I give every one the benefit of the doubt, here are the answers to those questions: A static variable allows the variable to maintain it's previous value through repeated raises of an event. Meaning that, if you … | |
Re: Basically, you are trying to create a new qpfile object (er a variable of the qpfile type). The bad news, is that qpfile was installed on the 98 box, but doesn't appear to be installed on the XP box. The other viable problem, is that if the qpfile program was … | |
Re: Don't be silly. Open the process with a file handle, and you can write data to it that way. For instance: [CODE] # /* Open The Program (Just Like A File) Piping Data To It (For Writing) */ open (FH, "| /path2/install/program"); # /* Actually Write To The Process */ … | |
Re: Would It be possible to attach the project as a .zip file, with any needed files? | |
Re: He's absolutely correct, but beyond that, you may want to have a look at the setforegroundwindow, setactivewindow, and the setfocus API calls. Basically, this is to ensure that the window you are trying to send keys to is the active window. It MUST be the active window, in fact. The … | |
Re: The Zip is Invalid or corrupt... Please reattach the .zip in a new post to this thread. Thanks. | |
Re: Do you mean the target of a shortcut, or the target of an EXE? | |
Re: Ultimately, the concept differs depending on your application. If Word was [B]LAUNCHED[/B]with [B]YOUR[/B] Application, Then you can use the API Call "Waitforsingleobject" or (if your program doesn't need to do anything while word is launched) you can use WSH with shell and the .run method. With the latter, you can … | |
Re: Oh Yeah, It's On!!!! The Concept of how it works is this: The VB Program Makes A Batch File, Starts A Timer, And then runs the batch file. The timer searches for a specific file, every 100 MS... just exits the sub if it does not find it, but if … | |
Re: Assuming you are using a database program, and not something sick like flat files :eek: | |
Re: what do you mean by a list of possible actions? Something like the "open with" menu, or something like the properties menu? | |
Re: I would actually go with a control array of picture box's. This way, you could use pictures in the box's to represent the numbers, and if you wanted to give different styles or themes, it would be a breeze. If that seems a bit too complicated, go with the labels... | |
Re: Look Into The Excel Object. You can create/Manipulate excel documents with a VB Program (even with WSH alone) by using these objects. An Example [CODE] set xapp = CreateObject("Excel.Application") xapp.Visible = True ' Make a new Excel workbook: set workbook = xapp.Workbooks.Add set worksheet = workbook.Worksheets("sheet1") [/CODE] Basically, It just … | |
Re: I'm not sure why you would WANT to do that, but can't you just set the form to load maximized, and then use a timer control with a real short interval (like 100 ms) to call an API (setforegroundwindow) to make sure your maximized form is always the foreground window, … | |
Re: I don't understand what you are wanting to do.... do you want each word of the sentence in a new label, or do you want a random word of the sentence in the one label??? | |
Re: what exactly do you mean by reset? Just set it to zero? | |
Re: Is it possible that the vb open command is not waiting for the shell command to finish? You could make sure that VB deletes the random file, and then waits for the random file to exist again before finishing a doevents loop.... for example: [CODE] ' /* Check If The … | |
Re: I think the multiline property can only be set during the design, and not at run time. | |
Re: Really? For Real? This thread is 4 years old browsive. | |
Re: I'm guessing the problem is because QBasic is NOT installed. It came with older versions of Windows, and just about all DOS systems... however, with the advent of 2k and XP, I'm pretty sure that they don't have QBasic any more. I'm sure you can search around, and find a … | |
Re: Here is Microsoft's Response To Your Question: [url]http://support.microsoft.com/?kbid=233487[/url] | |
Re: have you tried running it in the VB IDE? If not, you might try that, and tell us which line gets highlighted.... | |
Re: Yes, Post Your code, so that we may see, and tinker with it. | |
Re: what you do, is set the timer's interval to 1 second. Then use a variable to keep track of the minutes (start at 0, and add 1 to the variable every time the timer fires, then, if the variable is equal to 59 [0-59 is 60 seconds], then reset the … |
The End.