vb5prgrmr 143 Posting Virtuoso

You cannot create a dll in VB with C++ coding/syntax. However, you can create a dll in VB with VB coding/syntax that does the same as what you want to accomplish with the C++ code but you may have to jump through some hoops. It all depends upon what you want to do.

Good Luck

vb5prgrmr 143 Posting Virtuoso

Okay, is this data that you captured written to a file? I ask because you use the past tense "captured" as this is not a NRT (Near Real Time) application. If it is a NRT application and you recieve this data in chuncks then the way you handle this data is just a bit different that if you were reading it from a file.

However, either way you will need to know about the following vb functions...

InStr, Split, Left, Right, Mid...

Good Luck

vb5prgrmr 143 Posting Virtuoso

Okay, in you Visual Basic 6.0 IDE (Integrated Design Environment) you have a toolbox. Usually located on the left side of the screen. It is where you find textbox controls, comboboxes, commandbuttons, and so on. Well by default, in VB6, with a standard exe project, there are other controls than those listed above. One of them is a shape control. which is capable of drawing on your form various simplistic shapes (rectangle, square, oval, circle, rounded rectangle, rounded square). Then, located next/near to that control is the line control.

Now, with these controls, you can use the shape for the head, and the line controls for the torso, arms, and legs. All you need to do is to place them on the form where you want them. Make them visible = false at the start and as the user makes incorrect guesses you just make each control visible = true.

Also, you can use the line controls to make the gallows if you want.

Good Luck

vb5prgrmr 143 Posting Virtuoso

Well, to find the average of any group of numbers it is the sum of numbers divided by the number of elements.

Good Luck

vb5prgrmr 143 Posting Virtuoso

In the most simplistic way, you can use the shape control for the head and line controls for the rest of the body. Stepping up from that you can use a picture box control to draw in via line and circle. Then from there you could use a predifined image and copy parts of it via BitBlt API and its friends. After that it gets even more complicated.

Good Luck

vb5prgrmr 143 Posting Virtuoso

To tell you the truth, I don't know but in later versions of VB, the setup.exe that the user would start to install the program is a project that you can modify. See if there is a setup project where your version of VB is installed and if so make a copy of it before you even open it for modification. Then modify the copy to handle the potential larger disk sizes. I'm betting that if there is a project it uses the old version of GetDiskFreeSpace and should be replaced with GetDiskFreeSpaceEx.

Good Luck

vb5prgrmr 143 Posting Virtuoso

How much memory on compiling system? >2Gigs? (Like I said, grasping.)

Good Luck

vb5prgrmr 143 Posting Virtuoso

See SaveSetting, GetSetting in vb's help.

Good Luck

vb5prgrmr 143 Posting Virtuoso

I am sure you know that the result of command.execute is record set. so may be explain your question more?

Yes, I do realize that if you...

Set recordset = command.Execute( RecordsAffected, Parameters, Options )

but the way maheshsayani used it...

command.Execute RecordsAffected, Parameters, Options

does not return a recordset, hence my post...

As for understanding the OP's origional Q see post #1 above. It seems pretty strait forward to me...

Good Luck

vb5prgrmr 143 Posting Virtuoso

What mode? 16 or 32? If 16 on 32 bit machine it just might be your problem but it has been such a long time since I worked on 4 that I am just grasping at straws.

Good Luck

vb5prgrmr 143 Posting Virtuoso

Yeah, if your looking for a specific unique identifier based upon the text of the combo box that the user selected and your database has been normalized and you have defined the relational fields then...

Private Sub ComboCountry_Click()
SQL = "SELECT tblState.State, FROM tblState INNER JOIN tblCountry.iCountryID = tblState.iCountryID WHERE tblCountry.vCountry = '" & comboCountry.Text & "'"
'....execute query, loop through RS to populate comboState...
End Sub

Good Luck

vb5prgrmr 143 Posting Virtuoso

Perhaps a boolean array with elements that equal your animation array elements that you can check against for specific element pauses/freezes. Just a thought...

Good Luck

vb5prgrmr 143 Posting Virtuoso

See winzip functionality documentation

Good luck

vb5prgrmr 143 Posting Virtuoso

See my answer in your other similar thread.

Good Luck

vb5prgrmr 143 Posting Virtuoso

WinZip has this functionality...

http://www.winzip.com/prodpagese.htm

Good Luck

vb5prgrmr 143 Posting Virtuoso

A definition at the top, a Java example, then a VB6 example...

http://compsci.ca/v3/viewtopic.php?p=146070&no=1

Another...

http://www.tek-tips.com/viewthread.cfm?qid=1387082

Good Luck

vb5prgrmr 143 Posting Virtuoso

Hmmm... Something along a card shuffle algorithm...

Option Explicit

Dim NumArray() As Integer

Private Sub Form_Load()
Dim ForLoopCounter As Integer, Temp As Integer, HoldValue As Integer
ReDim NumArray(9) As Integer

Randomize

For ForLoopCounter = 0 To 9
  NumArray(ForLoopCounter) = ForLoopCounter
Next ForLoopCounter

For ForLoopCounter = 0 To 9
  
  'get random number from 1 to 10
  Temp = Rnd() * UBound(NumArray)
  
  'set labels caption
  Label1(ForLoopCounter).Caption = NumArray(Temp)
  
  'check to make sure we need to continue
  If UBound(NumArray) = 0 Then Exit For
  
  'now swap values
  HoldValue = NumArray(UBound(NumArray))
  NumArray(UBound(NumArray)) = NumArray(Temp)
  NumArray(Temp) = HoldValue
  
  'then get rid of used number
  ReDim Preserve NumArray((UBound(NumArray) - 1)) As Integer
  
Next ForLoopCounter

End Sub

Good Luck

vb5prgrmr 143 Posting Virtuoso

Should be something like...

myrs.Open " SELECT memberpersonal.name,memberpersonal.memberid, FROM memberpersonal, INNER JOIN memberunion ON memberpersonal.memberid = memberunion.memberid where memberunion.memberid = " & cmbUnion.Text , mydatabase

Good Luck

vb5prgrmr 143 Posting Virtuoso

Well yes, you can use FindWindow or EnumWindows but the code by Hypetia is what you were looking for and is quite easier than the other solutions I just mentioned. Plus the modifications to your code would be minimal. All you would need to add is a public variable element array of doubles to keep track of the task id's and then when you want to check to see if any of the spawned programs still exist, you would call the solution in a for loop.

Good Luck

vb5prgrmr 143 Posting Virtuoso

What are you supposed to do to correct it...

Step through the code with F8 to find out where the dialog box is being spawned from. Then check that connection string with the rest of your connection strings (if you have more than one connection string) to see if there is a difference. Check the help files and see what it says and if necessary check www.connectionstrings.com.

I'm betting that the offending connection string has a true value where there should be a false value or the adPrompt(spelling) value set when it should be adNoPrompt(spelling).

NOTE: (Spelling) off the top of my head may be other constants but I hope that you get what I'm trying to say.

Good Luck

vb5prgrmr 143 Posting Virtuoso

Well since you have command buttons on the form you cannot use the form's keypreview property but you can use any of the following events of the command buttons as long as they have the focus...

KeyDown, KeyPress, KeyUp

Now, as for checking if the letter is within the word/phrase you can use the Instr function (see vb's help(*)). To replace the dash with the letter the user guessed you can use the mid function(*). Also, when the user has a word like "Remember" and they guess the "e" you will need to check for each "e" in a loop when using instr.


As for incorrect guesses you will need a form level variable and as each new game starts you will have to reset it there. Then as each incorrect guess is made you will have to decrement the value of the variable prior to displaying its value and prior to testing it for equaling zero (0).

Good Luck

vb5prgrmr 143 Posting Virtuoso

I don't think so it is possible to do it in VB6 but it can be done in VB.NET!

I can send you the code if wanted!

Regards

Oh how contraire akshits...

See...

http://www.tek-tips.com/viewthread.cfm?qid=1095460

Good Luck

vb5prgrmr 143 Posting Virtuoso

In VB's help, on the index tab, type in SetPrinter and hit enter. When the help file comes up scroll down to the bottom and click on Printing and Print Spooler Functions. You will need to look at OpenPrinter, PRINTER_DEFAULTS, DEVMODE, DeviceCapabilities, GetPrinterDriver, and quite a few others including the SetPrinter. Now what you will have to do is to figure out if the driver is printing to disk and that is easy enough via the GetPrinterDriver, as least for known drivers like adobe's, but for others, well you have enough information to get started.

Good Luck

vb5prgrmr 143 Posting Virtuoso

What kind of access are you using? ADO, ADODC, DAO, DAO ODBCDirect, RDO?, What version of Access? If ADO, are you using a DSN?

vb5prgrmr 143 Posting Virtuoso

Correct me if I am wrong maheshsayani or anyone else, but using a command object used that way will not return a recorset....

>need a small help can anyone help me in showing how to call a stored procedure which returns a recordset

Hence, my suggestion to use a recordset object...

vb5prgrmr 143 Posting Virtuoso

Okay, very open ended question but since you say it is your web site I must guess that you have at least some knowledge of HTML. Now, if you are wanting these programs to be downloadable for installation then you need to make setup packages. Then drop those zipped up packages in a folder on your webserver and just as you would create a link from one HTML page to another, you create a link to the zip. It would be the same thing if you are wanting people to view the source. Just zip up the source files, drop it on the server, and create the link.

Good Luck

vb5prgrmr 143 Posting Virtuoso

Just use a recordset object as you normally would. i.e. say your SP has a name of MySP and it accepts one parameter. So you query string would be something like...

MyQueryString = "MySp " & MyValue

Then execute the query as you normally would.

Good Luck

vb5prgrmr 143 Posting Virtuoso

Check www.connectionstrings.com to see if your connection string is in the proper format. Then when you created your DSN did you test it? Did it work? Test it again to see if it is working. If not, is the service running on your computer?

vb5prgrmr 143 Posting Virtuoso

On the remote machine... Did you create the ODBC DSN so that it pointed to the machine with the DB? Because that is the gist of the message.

vb5prgrmr 143 Posting Virtuoso

First, if Option Explicit is not at the top of the code window, type it in.
Second, delete the .text and type in the dot (.). If textPrincipal is an actual control you should see the list of properties come up.

Now, it could be that you may have accidently renamed the control or perhaps misspelled the controls name in code so here is what I want you to do...

Go to the form view and select the textbox in question. Look in the properties window at the name property.

If it looks like the correct name then go back to the code window and remove everything after the open paren of the val function (val(....). Type in textp and hold down the CTRL key and press the space bar. Your textbox name should appear in the drop down list and if so just hit the tab key. Then type in the dot (.) and text should appear in the list BUT if you see caption then you have a label named as a text box.

Good Luck

vb5prgrmr 143 Posting Virtuoso

What version of DAO are you using?

vb5prgrmr 143 Posting Virtuoso

At the top of the code window, above all other code, do you see the words "Option Explicit"? If not, add these words and press F8. Your error, when you compile, should now be highlighted. Now, in the future so that this appears automatically, goto VB's menu Tools>Options and when the dialog appears, place a check next to where it says "Require Variable Declaration". Click OK.

Good Luck

vb5prgrmr 143 Posting Virtuoso

Sounds more like a combo box you are using. If so see this thread post #2

http://www.vbforums.com/showthread.php?t=566063&highlight=type+ahead+ability

Good Luck

vb5prgrmr 143 Posting Virtuoso

see my instrucions in this thread

http://www.daniweb.com/forums/thread181952.html

post #4 to see if it can give you any ideas...

Good Luck

vb5prgrmr 143 Posting Virtuoso
vb5prgrmr 143 Posting Virtuoso

Okay, in post #5 you wanted to change the format to the 24 hr format. If this is still correct then you what I previously told you is correct, but, you cannot access it via the DTP.Value. You need to use something like...

MsgBox DTP.Hour & ":" & DTP.Minute

Good Luck

vb5prgrmr 143 Posting Virtuoso

In form view, select control. GoTo controls Properties window. Click on ... (Custom). Set Format to 3 - dtpCustom. Then in CustomFormat enter HH:mm .

Good Luck

vb5prgrmr 143 Posting Virtuoso

use the keydown,keypress, or keyup event of the command button and form (just in case the command button looses focus).

Good Luck

vb5prgrmr 143 Posting Virtuoso

Perhaps those "spaces" you are talking about are actually "tab" characters. Try replacing with vbTab instead of " ".

Good Luck

vb5prgrmr 143 Posting Virtuoso

Okay, downloaded your project and I see that you are using .NET. This is the "classic" vb forum for versions prior to .net 2k2 (2k3,2k5,2k8,(2k10)). However, what I said before still applies and I think I understand more of what you are asking.

Okay, in classic vb as in .net you can declare a public variable in the general declarations part of a form and then reference it by using...

formname.variablename

via retrieving or setting...

somevariable = formname.variablename

or

formname.variablename = somevalue

just as you would do...

somevariable = DirectoryForm.HayesLabel.Text

Now, as to try to answer your other question...

When a form is hidden and not unloaded everything contained within that form that has been exposed (controls, public variables) are accessible from other forms or modules (don't get confused here, its okay).

I hope this helps clear some thing up.

Good Luck

vb5prgrmr 143 Posting Virtuoso

Real simple answer is to add a module and declare your varibles with the Public keyword. Then from each of your forms as you complete your calculations you can assign these/this variable with the result of your calculations. Thus in the next form you should be able to retrieve the valued stored within this/these variables.

However, if you do not want to add a module you can declare a public variable at the top of form1 in the general declarations area. Then you could reference that variable from the other forms via Form1.VariableName = Value or Value = Form1.VariableName as long as you don't unload the form, Hide it until program ends or only unload it after you are done with your calculations.

Good Luck

vb5prgrmr 143 Posting Virtuoso

You can try the forms zorder (=0) but you may want to look at either the SetWindowPos API or SetForegroundWindow API.

Good Luck

vb5prgrmr 143 Posting Virtuoso

AddFontResource API

Good Luck

vb5prgrmr 143 Posting Virtuoso

So you want to limit access to the database based on access times. Well then, you will need some sort of table in the database that contains the user and the start/stop access times. Then at program start you would query for this information plus you would need to query a machine other than the users machine for what time it is via the netremotetod API....

http://support.microsoft.com/kb/249716/EN-US/

However, since you can see that is in C you will need to convert it to VB (Good Luck).

Now, this will only tell you at program startup if the user has the right to access the database and if they don't you should end the program with an informative message of not yet or time expired.

But, once the program is running you will need to occasionally check the machine you have designated as your time server. Hopefully, you will pick a machine that is not to busy and you may need to ask you network admin on which machine you should point this api to. So, you could check via the api prior to updates to see if the user has permissions.

Now, the reason I am pointing you to this fairly difficult API is because it is a very simple task for the user to change the time on their computer but if you have your code pointed at a machine they cannot get their hands on, well then, you will be keeping …

vb5prgrmr 143 Posting Virtuoso
vb5prgrmr 143 Posting Virtuoso

search "Watch Folder" via google/yahoo and you might want to add vb6. Also there is a sample at tek-tips.com in the vb 5/6 forum I believe by strongm.

Good Luck

vb5prgrmr 143 Posting Virtuoso

Add the microsoft internet control to your toolbox (It's actually the webbrowser control). Then you can simply use WB.Navigate pathtofile.

Good Luck

vb5prgrmr 143 Posting Virtuoso

good day everyone! how can i distribute the exe application w/o using package and deployment wizard?

You can't.

i just made it executable. the problem is the the database path changes because i did not use the App.Path. I know how to use App.Path using ADODB, but with ADO Data Control, you can only set by means of setting the properties at design time (such as C:\Documents and Settings\Arvin\My Documents\My Files).

Yes you can set the properties of the ADODC in code. Just use the name of the ADODC (ADODC1) . (dot) the same property name that is in the property window = the setting you have.

Of course, if I distribute the exe, the specified path will no longer be the path. Or is it possible with App.Path. Any idea on how to solve this issue. Thank you for responses.

If the database is meant for single user then you can use the app.path method or if you want you can use the common dialog to allow the user to navigate to the database to select it.

Good Luck

vb5prgrmr 143 Posting Virtuoso

In VB press CTRL+T or right click on the toolbox and select components. A dialog will come up. Scroll down to the Microsoft Masked Edit Control. Selrct it and click OK. Place it on your form, select it, and press F1 to read all about it.

Good Luck

vb5prgrmr 143 Posting Virtuoso

Well, you are going to need some sort of way to know where the paths are. Once you have that then the rest should be easy. One thought is to color the areas where your object are not allowed to travel with a color of your choice. Then you can do some collision detection to make sure your objects do not go where they are not supposed to go.

Good Luck