Type: Posts; User: georgekar
Search took 0.03 seconds.
I Have 6 examples. We have to put the Bible13.txt.
Because some examples cannot work with books, I make all examples to count all books. I put an example with a HashTable class (from Francesco...
Your example is very fast but from using safearry isn't too much gain of speed.
To prove that please insert this line :
WD.SetStringCompareFlags cmpIgnoreCase, English_United_States,...
Ok, I will look better your library. Not to replicated it :)
perhaps you can find that this
give totally different output...
In my machine is 12sec for binary search with auto sorting, 20 if I use the old one that compares only equal length words, and 90sec if I use binary search and quick sort for every entry.
I found another part that is not sorted by vbtextcompare...in olaf routine
This is from my routine (i can cut because is written in an RTB. Olaf's is in a Listbox...)
Its time to read code...
So if you read that is a quicksort for my example
But I found a better way to sort words. Without Quick sort. I found a way to sort the list of word while...
This is the sort routine...is very fast
QuickSortExtended 1, top
Public Sub QuickSortExtended(ByVal LB As Long, ByVal UB As Long)
Dim M1 As Long, M2 As Long, pivlen As Long
Dim Piv As Long,...
You can pass dib data to a string I do that in M2000 code, you can find in the signature. You have to include cDIBsection class (also define a MDM() global array, usedfor printer...
There are lotteries that you win more if you have plus 3 and or minus 3. And that is for lottery company a 3pla lottery...So perhaps you have a game that has a lottery stage, how you can...
In a form we place a rtb. No distinguish books...nor headers.
Countwords make no sort. I leave the order of appearance. We can feed a listbox with sort capability. It isn't the best one, but uses no...
I run your code. But your code is not visible, is not open source. So If I want to do it, then I have to make as closed code..but free to use, like yours.
thank you for your answer. About the OP code, it is obvious that it isn't password cracker because no one can use 6 char length as password, and the combinations are too many...to check every...
The code I am sure isn't a password cracker...
Can you follow what I wrote in #4?
The scope isn't needed. The answer is that this approach, to feed a caption a string as all combinations for a series of letters, is wrong.
What you need is a function where an input value give a...
So words are in a string in a cell so you need my word count routine.
And a small idea ..
He can take the code in #14, and there is an easy way to make it to read words from array, or excel cells. My code find words but here the words are in separate cell...so he need...
String Array means an array of strings like a paragraph. A vbcrlf is a paragraph break, and needed only if we have one string text.
When we read from a file line by line we use "line input". (this...
You have not to hide list, just set enable to false, do the process and change to true. About the calculation, is not true that every demand for refresh is executed in time. It depends...
Never add to a listbox in a for loop without disable it before.
When you forget that, then for each addition the listbox perform a refresh. So 10000 refreshes are a big time. A...
This function counts words (using VbTextCompare) that are different.
I leave as exercise to alter this to get the times each word appear in the text.
Also notice that I use pointers (as offsets in...
If I found time I will make the code...But my problem is that I wrote my thoughts with the greek way where the object is present once and then I can write some sentences without reference to that by...
I give my thought here, not a single line of code.
Every word in a dictionary can be simplify like this "like" to be "li" and "ke". So We can use an array of 1000 strings in a shorted array (using...
I use this
Public Function LoadFont(FntFileName As String) As Boolean
Dim FntRC As Long
FntRC = AddFontResource(FntFileName)
If FntRC = 0 Then
LoadFont = False...
I know that you know what it is. I write for those that don't know. As for speed it is an old rule that said you gain speed if loose memory. A lookup table used for speed. A select case has a good...
This is what we call a lookup table. In a string we can put values 16bit in a char position. But we can use an array for single...All we need is to know the smallest part. We can put a code like 0...
if is all about a range problem and the range maybe alter at run time then we need array to hold ranges
so we can search like this
for i=0 to n-1 step 3...
You convert in any language...but mostly a program for a work has two things to resolve, the data entry and the data report. So you choose a "studio" if you understand that two concepts..
So Vb has no Short Circuit evaluation
You are right...I do an example and I found that vb execute all the parts in an AND.
Function testA(a As Long) As Long
Debug.Print "I am A"
HighLow is used to combine two unsign integers (we use long as containers for unsign integers)
HighWord give unsign integer as long
LowWord give a sign long that has the same bits as the one we...
You can read a long and you can extract the low word or the high word. Also you can combine two words (2 bytes) in one long.
? right$(hex$(lowword(&h2fff1bcd&)), 4)
I write a new thread about the use of the Lavolpe fast code for regions.
There is a revision 12. In revision 11 was a bug in the rotation algorithm. Because I would like to synchronize the bitmap...
With the help of a quick algorithm by Lavolpe to generate a region, and the idea that regions can be transform (so can be rotated), I change the code accordingly to support players (sprites) that are...
I found the optimum solution...
Here is a sprite over scrolling text.
I use a very precise rotation and zoom routine, and I apply your routine after the rotation and scale. I do many...
This works fine if piw=pih, so if we have a square sprite. We do a 1/1.3 down scale...and we can rotate using the middle pixel as the center of rotation.
Myw and Myh are the size of the new...
I have software sprites in m2000 that have the hot spot in the center. The players (or layers if we see with the second interface) have a hot spot in the left top pixel.
Is not finished yet but now...
Maybe you need Vbcmpfix.exe to fix some componets in vb5...so after maybe it works, I am not sure.
But have a try;
ok I put your method in M2000 revision 11 (not publish yet). I didn't use the hack for BGR color because I use a range so for any R G B value the range is compare with each pixel in the bitmap (I use...
Click Here to Expand Forum to Full Width
Survey posted by VBForums.