Exact Search ...
Dear Friends,
I have the following code using for MSAccess database which shows the search result similar to the text typed in combo1.text box. I need the exact result what I typed for. How can I do it?
.....Where Customer Like '%" & Combo1.Text & "%' .....
Thanks in advance for the help.
vblearner6
View Complete Forum Thread with Replies
See Related Forum Messages: Follow the Links Below to View Complete Thread
Exact Search Result?
Dear Friends,
I am using the following code in a command button (cmdSeptember2007). When I click the button (cmdSeptember2007) it will show all the expenses done in the month of September, 2007.
It is working fine. But the problem is, if there is a record which was entered
in the month of September but in the year 2006 also it shows. So how can I resolve this problem?
Code (in Commandbutton "cmdSeptember2007") :
Code:
rs.Open "Select Description, TDate, Amount from Expenses where MONTH(TDate) = 9 Order By TDate Desc", db, adOpenDynamic, adLockOptimistic
What I need is, if I click the "cmdSeptember2007" it should show all the transactions (records) done in the month of Septermber, 2007. It should not show the records entered in the month of September, 2006 or other years.
Using MS Access Database
Filed Name: TDate (Transaction Date)
Data Type is : Date/Time]
Format is : Medium Date (dd/mmm/yy)
Thanks in advance.
vblearner6
Search For An Exact String
mornin...
i wanna search for an exact string within a string
str1 = "Dude where is my cat"
str2= "Dud"
I want to search str2 in str1. If I use the Instr function I will get a true value cause 'Dud' is present in 'Dude', but I want to be able to search for the exact string 'Dud'.
One solution I have is to check whether the next charachter (after 'Dud') is a blank space, but that would be quite messy with all the strlen's and everythng. any easier way to do this ? perhaps even a straightforward VB function ?
tx...
LIKE Statement: Not Exact Match DB Search
I am trying to search a database in a not exact manner and know that I can use the like statement to help with this search of the database but do not know exactally how to do this. Any help?
Search And Display Exact Record
Help me by mailing here!!!
i am developing a small utility for a school as part of my project and there is no one to guide me.here is my problem.please help me
my database has 12 fields in ms access 97.i have in all 4 forms which i have done in vb 6.0.i completed
assigning all the text boxes to the fileds of database using data1 found in toolbox,
Now my menu bar looks like this
file-->open-->form1,form2,form3
when i click on a form and enter the serial number i want all the data back into their respective fields
corresponding serial number. Iused text boxes for these fields and assigned them to database usind Datasource and datafields
please help me
L.Subrahmanyam
Search The Exact Word Or Number In Any Field
I had a question before of searching a word in any field of database. Thanks to webbone who gave me a code like this StrSQL = "SELECT * FROM MyTable WHERE TextField LIKE '%" & Text1.Text & "%'". Yes this works, this code select a record in any field but to a word that only starts from it.
Is it possible to search the exact Word or Number in any field.
Ex. 1
100 X 100
200 X 200
300 X 300
400 X 1000
Ex. 2
Excavation of Drainage
June is Rainy season
I like it when it rain
Because on that code:
Ex. 1
If I search for 100 it should give me "100 X 100" rather it will give me a result of "100 X 100" and "400 X 1000".
Ex. 2
I want to search just the word “Rain” which should give me "I Like It When It Rain" but it will give me three results.
Thanks and anticipating.
How To Search In MshFlexgrid And Go To The Exact Row Which I Type In A Column ! NeededHelp
Hai,
I am displaying the Stock details in MSHFlexgrid. It contain more than 300 Records. I need to make program work as below i stated. Kindly suggest is it possible and its the correct way or what.
I also tried in the forums, but i couln't find and exact dilemma, so i am posting here again.
The user will type the text in the MSHFlexgrid anyplace in column 1, because Column (1) -ProductCode is the Id,
the the row in the MshFlexgrid should highlight which is matching to the user typed.
Thank you,
Chock
itchocks@rediffmail.com
<HTML>
<B><font color="#008000">HAVE A NICE DAY !</font></B>
<HTML>
Instr Doesn't Work Properly-Need To Search Exact String!
Instr doesn't work properly-Need to search exact string! Hi All,
I have the following function which is used to search a range of cells for text and then return the cell as string i.e "AC1":
Function ContainsText(Rng As Range, Text As String) As String
Dim Txt As String
Dim myCell As Range
For Each myCell In Rng 'look in each cell
If InStr(myCell.Text, Text) > 0 Then 'look in the string for the text
If Len(Txt) = 0 Then 'if the text is found, add the address to my result
Txt = myCell.Address(False, False)
Else
Txt = Txt & "," & myCell.Address(False, False)
End If
End If
Next myCell
ContainsText = Txt
End Function
The problem is that when I have two columns say one has the caption:
IIBC Code and the other has IIBC Code Description, it returns the two when the text search is IIBC Code. Is there anyway to search the exact string...what am I doing wrong.
Once again many thanks in advance
Search For Exact String In Target String
Hi,
I am new to VB. I want to know if a built in function exists to search for exact string in the target string.
InStr works fine but it some part of search string matches in target string it gives the position of the same. However, i want to search for whole search string in target string.
For Example :targetstring = Template 0005
search string = Template 000
instr (targetstring,searchstring) - should return 0 as there is no string exactly like Template 000 however presently instr return the index of Template 000.
I hope i am clear.
Kindly help me in this.
Regards,
Sharmili.
Exact
I need help...
i have two workbooks i use if function to compare two cells both are the same (inhalt, format) but i always get false?!
So i tried exact function which works but i can't use this in VBA, it doesn't recognise it.
thax
Not Exact Value
In a simple subtraction of two variables the following happens
x=a-b
a=8.25
b=8.209
x should be 0.041
VB6 gives me 4.10000000000004E-02
Why the bit at the end?
Thanks
Need Exact Timings
Hello everyone, I am developing a application to read subtitles and the function to read subtitles is ready but I have a problem...
It reads .srt subtitles, which format is for ex.: "00:01:58,393",
well, I have a label with the timing in this format, but sometimes it skips some dialogues..
I think this is because the timing is not exact, for example, the dialogue is in "00:01:58,393", but the timing skips from "00:01:58,390 to "00:01:58,400", i am using the timeGettime api and a timer control (interval 1) to show it on the label with the timings.
I am almost sure that the problem is in the timer control, but what can i use instead of it? because i want to show the timing of the api timegettime in a label in real time.
How can i solve this?
**Hope you understood, english is not my native language.
Thanks
Exact Time
As you all know its spring forward, and I have been trying to make a simple ..yet hard program.. im trying to display time zones for several cities..anyway to make a long story short the time on your pc is not always correct for various reasons.. and the timer functions just pulls off your already pre-set clock. My question is: How can you ask timer to pull up what zone your in..and using that calculate the time..because for example im in eastern usa currently so the time would be on eastern..but vb doesnt know that and if i start going down the line with other cities i could be wrong.. so basicly i need to know how to get the timer to recognize the time and timezone its in.
Exact Count
I have this loop:
VB Code:
Dim X As SingleDim LowX As SingleDim HighX As SingleDim StepX As Single For X = LowX To HighX Step StepX'...Next
Now, inside the loop I must place some code to update a progressbar. so I must know the maximum value it can reach. With integers it's easy, as you know exactly how many times the loop is going to be executed but with single type variables, you can't just calculate
MaxVal = (HighX - LowX) / StepX
and round off to the nearest integer because you (or, rather, I) never know how the numbers will be rounded up so at times MaxVal comes out different by 1 from the actual number of iterations. Therefore I somtimes include a "dry run" just to count the number of loops:
VB Code:
Dim Counter As LongCounter = 0For X = LowX To HighX Step StepX Counter = Counter + 1Next
and then I place the actual loop.
The problem is for some complex nested loops this means too much overhead so I'd like to know if there is some cute algorithm to replace
MaxVal = (HighX - LowX) / StepX
yet giving the exact result.
Obtaining Exact Day
Guys
I have a problem. I need to know what DAY a random date of the year is. For example, I know 27 February 2005 is a Sunday but VB doesn't. I need to determine this in my code so if the user picks a date from a DTPicker, I can return it as, for example, Sunday 27 February 2005.
Any ideas?
Cheers
Exact FindWindow()
I'm running a program using
Code:
hProcess = OpenProcess(PROCESS_QUERY_INFORMATION, False, Shell(sShell, eWindowStyle))
This code is part of a larger function called ShellAndWaitForTermination() which runs a program and waits until it has closed before returning control to the calling code. The full function is attached.
When the program has started up it opens up one dialog. I want to change the WindowTitle of that dialog. I have been doing it by including the following code in the function
Code:
Dim hWnd As Long
hWnd = FindWindow(vbNullString, "Untitled - Notepad")
SetWindowText hWnd, sWindowTitle
This works but I am concerned that if there are already windows open with the same initial WindowTitle, FindWindow might give me back the wrong one and I'd end up setting the WindowTitle of the wrong window.
So, how can I get from the handle returned by OpenProcess() to the handle of the new application's main window?
Few Speed Questions (10 To Be Exact)
Hi folks,
few speed questions:
1. which is faster: D3DCREATE_HARDWARE_VERTEXPROCESSING or D3DCREATE_MIXED_VERTEXPROCESSING?
2. How can i easily check if one of these are supported? i have read the tutorial on directx4vb but that crashes my computer all the time so was wondering if it could be easier
3. d3ddevice.SetRenderState D3DRS_SRCBLEND, D3DBLEND_SRCALPHA if i turn the alphablending always on instead of only when it is needed does this slow the framerate or is the switching between alpha or not more consuming?
4. is there a difference btween d3ddevice.SetRenderState D3DRS_CULLMODE, D3DCULL_CCW and de CW version of this in speed?
5. i use a lot of integers. is it smart to increase speed to convert them to Long?
6. does gettickcount decrease speed alot? or is it not noticable?
7. what is faster using cases or if statements?
8. ViewingAngle + pi180 * MouseMoveX, how is this calculated? first the + and then the * or the other way around?
9. Scaling through matrixes does this cost a lot of time because i can also scale them correctly in 3dMax so i don't have to do it ingame or is the fdifference very little?
10. D3DWindow.BackBufferFormat = D3DFMT_X8R8G8B8 is what i use to format the backbuffer but how do i format the normal? i just can't find it
tnx in advance
Finding An Exact Match
Hi,
I don't have any written code but was hoping someone might direct me in the right direction.
I have a Column A containing 10 different names and I would like to compare each of those names against a template of names in Column B (Which has 100 different names).
Once each name from column A finds it's match in column B I would like to bold the name in question (In column B).
If sorry if this sounds confusing. I'm ok for writing the majority of code although I am getting stuck on how to look for an exact match.
I would appreciate any advise or help on how to perform a Match search.
Thanks
Timer Control Not Exact
Hello:
I am working with a timer control and i have seen thant if i use a counter in a timer control with interval 1 and wait when it reaches 1000, there hasnt really passed a second... How can i make the timer exact??
Because if we consider that the timer interval is in milliseconds, when the counter reaches 1000, there should have passed 1 second, but if you compare it with a clock, it is not really a second...
Here's the code:
Code:
Private Sub Form_Load()
Timer1.Interval = 1
Label1.Caption = 0
End Sub
Private Sub Timer1_Timer()
Label1.Caption = Label1.Caption + 1
End Sub
How can i make the milliseconds exact?
Thanks..
Exact Text Compare
How can I make an exact mach of text?
If I have a "John" and "john" this should not mach. Is there a function or something for this?
Match Exact String?
hi all,
how do i match the exact string "telephone" and extract the whole line?
cause the instr function can only find the occurance
eg.
/telephone number/telephone calls
/telephone/phone call/ ====> the desired record
/mobile telephone/phone
.
..
...
Exact String Replacement
I thought for sure somebody had asked this question, but I've been searching for hours with zero luck.
I need a function for Visual Basic 6 that replaces EXACT words inside a string that are seperated by spaces and/or vbCrlfs. How would I go about doing that (or finding that)?
Saving To An Exact Line
I am using a Setup.ini to save many properties of my program. I cant save into different lines. I want to do something on these lines:
[vbtemp]
open "setup.ini" for output as #1
'then print strDisplayStatus to line 2
close #1
[/vbtemp]
thanks
Lucas
Exact INPUT #1, Structure I Want
Basically I want to write the Structure for the Follwing DATA
Basically i Type for CLass 1 in Text1.TEXT
The follwing data consits in the Marks.Data file
"FILENO 1"
"School 1 "
"CLASS 1","GROUP Z","PAPER1MARKS","PAPER3MARKS","PAPER3MARKS"
"1"--------SHOWS THE RECORD OF CLASS1
"PAPER NO","PAPER DATE"
"FILENO 2"
"School 5 "
"CLASS 1","GROUP A","PAPER1MARKS","PAPER3MARKS","PAPER3MARKS"
"CLASS 1","GROUP B","PAPER1MARKS","PAPER3MARKS","PAPER3MARKS"
"CLASS 1","GROUP C","PAPER1MARKS","PAPER3MARKS","PAPER3MARKS"
"CLASS 1","GROUP D","PAPER1MARKS","PAPER3MARKS","PAPER3MARKS"
"4"--------SHOWS THE RECORD OF CLASS1
"PAPER NO","PAPER DATE"
Basically There are different files of School Names
where i want to find the CLass 1 RECORDs
if you see the above
-------it shows Two different filenames with Two different School name and different no of records of Class 1
-------with different Groups
-------Even No of Record may vary Even you may have single SCHOOL like the above you have TWO SCHOOLS or EVEN SCHOOLS MAY INCREASE
OPEN "C:RESULTSMARKS.DAT" FOR INPUT AS#1
DO UNTIL EOF (1)
i% = i% + 1
how to input# , The ABOVE DATA or Variables
? ? ? ? ? ?
LOOP
CLOSE #1
Thanks
Samyo
How To Print In Exact Coordinates.
Hello again,
Once again master im here and id try to solve it my self but it took me 3 hours and half just to search for answer on this one, I am trying to print on a given or predifined form but i kept printing on a different location of my sample form , let say way of 15 spaces approximately. please see my attached file on it.
i know i missed some coding here.
thank you.
guys
Reading Ini, But Not By Exact Line?
VB Code:
Public Function GetSett(Section As String, Entry As String, strbuff As String, jPLace As String) As String strbuff = String(256, 0) c = GetPrivateProfileString(Section, Entry, _ "", strbuff, Len(strbuff), jPLace) GetSett = Left$(strbuff, c)End Function
Ive written this nice sub just to read an ini file, but im wondering..is it possible to read a line by an not-exact name? i could read it by regular I/O but this is much faster
Getting Exact Byte Regions
Hi,
Is there any easy was to get the exact byte code between 2 points. For example, I open a file and I want all the bytes from 5032 to 6123 to save as a new file. If I was using string, I could use the Mid$() command - but is there an equivalent command for dealing with bytes?
Thanks guys
WATTO
watto@watto.org
http://www.watto.org
Getting The Exact Number Of Days...
Another DateDiff problem, have never used it before. Please tell me how can I get the exact number of days from today to any date that I enter in the text box????
Exact Delay In VB Program
How to create delay in program witch will be same length on every computer (from 100 MHz 486 to Pentium III). I do some computing in in this time interval and timer on the slow machine seems to slow down.
I need exact delay 700 ms (+ - 50 ms).
What can I do?
Ermin
Exact Time On A Timer
hi!
I wanted to know if there's code I can put into a timer (or anything else), that will always display the current time (minutes and seconds). I found a formula that works on my computer, but if I would run it on a 486, it would be much too slow. Any ideas?
------------------
Regards,
Alexander McAndrew
VB Zone
http://gsenterprise.server101.com
Exact Time On A Timer
hi!
I wanted to know if there's code I can put into a timer (or anything else), that will always display the current time (minutes and seconds). I found a formula that works on my computer, but if I would run it on a 486, it would be much too slow. Any ideas?
------------------
Regards,
Alexander McAndrew
VB Zone
http://gsenterprise.server101.com
Exact Location Of Text
I want to create a multiline textbox in VisualBasic 2005 express edition, and i want to know how to set it to, on button click, insert text at a specific location, or more than one exact location, or to insert it where the users cursor is.
Tv Programmes (i Don't Know Exact English Name)
just because i can't found some soft to get tv progs from internet, i made one.
it's a "gas machine" but it works fine. maybe some european people can be interested...
(only european broadcast tv : TPS and Canal sat)
this is the "code"....
StoredProc That Calculates Exact Age
Does anybody here in codeguru has a T-SQL code that calculates the exact age(days, months, years) of a certain birthday? I have a code for such but not in T-SQL and I'm encountering problems converting it to T-SQL, I hope somebody here helps.....
How To Drag And Drop To The Exact Location?
I developed a system where it calculated the angles between certain points.(For medical field :X rays) I use labels scaled down in to very small size as the points and use the moveobject method to move them when the user drag it over..but when it is dragged and dropped it drops slightly away from the exact position where its supposed to be (about 10-200 away) then i have to re-drag it in to the exact position. How do I do it on first time? to drop it to the exact position I want.. Pls help!!!
How Do I Select A Range Without Having To Specify Exact Location?
I just need to have the form command select the next row down and then select the A,B,C range. Just select it without me having to specify which cells such as Range ("a1:c1").select. I want to skip the ("a1:c1") part and have it select a,b and c whichever row is selected at the time. I don't want the whole column just the first 3 and the if I move data around using a form, I can click on commandbutton and it will go down next row below and automatically select the 1st 3 cells.
I hope it makes sense
using VBA with Excel
thanks
D3D 7 Exact Collision Idea - But Is It Practical?
In Direct3D7 i've finished a 3D engine and i'm ready to write the game engine for it - time to look up collision.
As much as i look nothing seems to work too good at all for terrin collision... at least, as far as i understand. it'd require checking each and every triangle surface to see if there's contact. with such as a Quake map that would take a long time.
I've already written a map loader. i have a converter for quake maps to points list and tile UV formats. i write maps in QuArK, save them as .Map and then convert them to my loader format.
Sample of my own map format is:
(just example)
Polygon
points 4
( 10, 20, 5)
( 30, 20, 10)
( 10, 55, 30)
( 10, 20, 12)
Texture
MyPic
(12, 46)
(8, 1)
(7,3)
(4, 099999)
I store each polygon in an array (eg: Polygon(#).oPoint(#)) and loop through
drawing them as a triangle fan. comes out real sweet.
and draw them all in one matrix object (map object = all faces, for example)
by looping through trianglefan.
Code:
For i = 1 To NumPolys - 1 'Go through each face...
Device.SetTexture 0, Polygon(i).oTexture
Device.DrawPrimitive D3DPT_TRIANGLEFAN, D3DFVF_VERTEX, Polygon(i).oPoint(i), UBound(Polygon(i).oPoint()), D3DDP_DEFAULT
Next i
so you can see how this can give me a bit of a headache with collision detection with walls, terrein, ect..
so i have this idea and i need some feedback on it before i go nuts trying to figure out how to do it.....
when loading the map, store the highest and lowest of each XYZ point for a triangle. eg: the lowest Z of all triangles is -15 the highext Z of all triangels is +99192
do this for the XYZ of the map to get the upper and lower limits of each demension. the result will be something like this:
X ( -59 , + 9999)
Y ( -70, +80010)
Z ( -80, +8808)
use this to create a 3D array
Dim WorldLimit (Low X to High X, Low Y to High Y, Low Z to High Z)
then loop through all faces and find each point - we'll look at a 2D flat surface to explain this:
this polygon has 4 sides:
( -4, 5)
( 5, 5)
(5, -5)
( -4, -5)
in our sufurace array we treat the above cordinates as points and mark those as 1 for solid, 0 for nothing there, even have the value at 3 or something for water or other such user-made-surface.
Code:
-5,-5 5,-5
0, 1, 0, 0, 1
0, 0, 0, 0, 0
0, 0, 0, 0, 0
0, 0, 0, 0, 0
1, 0, 0, 0, 1
5,-5 5, 5
in the array connect lines from each point.
Code:
-5,-5 5,-5
0, 1, 1, 1, 1
0, 1, 0, 0, 1
0, 1, 0, 0, 1
1, 0, 0, 0, 1
1, 1, 1, 1, 1
5,-5 5, 5
now fill it in.
Code:
-5,-5 5,-5
0, 1, 1, 1, 1
0, 1, 1, 1, 1
0, 1, 1, 1, 1
1, 1, 1, 1, 1
1, 1, 1, 1, 1
-5,5 5, 5
Now - as just a 2D example - we have an array of a surface. we do this for all surfaces in a single array.
now when you want to check for collision, you connect a line from your cordinates to the destination cordinates - but using the array rather than anything actualy drawn.
world matrix as array with ME at +6, -13 and destination X at -3, -3
{ the / symbol represents the therotical line of the cast ray}
Code:
-5, -14 +7, -14
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, ME, 0
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /, 0, 0
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /, 0, 0, 0
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /, 0, 0, 0, 0
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /, 0, 0, 0, 0, 0
0, 0, 0, 0, 0, 0, 0, 0, 0, /, 0, 0, 0, 0, 0, 0
0, 0, 0, 0, 0, 0, 0, 0, /, 0, 0, 0, 0, 0, 0, 0
0, 1, 1, 1, 1, 0, 0, /, 0, 0, 0, 0, 0, 0, 0, 0
0, 1, 1, 1, 1, 0, /, 0, 0, 0, 0, 0, 0, 0, 0, 0
0, 1, 1, 1, 1, /, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
1, 1, 1, 1, /, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
1, 1, 1, X, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
-5, +6 +7, +6
send to sub or function Orginx,OrginY, OrginZ (or D3DVector), DestinationX, Dy, and DZ (or d3dvector)
sub returns highest array value passed through, XYZ values of impact where first impact is made.
we set the direction for a short distance, such as a walk distance in a single game-cycle, or for a high distance- such as the high distance a bullet travels in a single game-cycle.
we can then know faster than many of these other formulas i've read how to detect collision. the map would take longer to process but the detection would be much faster and simpler - the map loader would handle the actual array setup each time a map is loaded.
.
.
I hope you understand my theory as i am very sleepy sitting here.
my questions are this:
1 - would this indeed be faster to process during actual in-game play?
2 - can you set the LBound of an array to under zero? (if not, then simply make an XYZ offset varable to add to origin and destination vectors when they are processed - another routine but not a hard one. it's already dancing in my head.)
3 - the math do actualy fill in the array for the surface. i'm not good at 3D geometry/vector math.
and keep in mind - although i explained it in a 2D fassion, i plan to apply this to a 3D world.
Thank you in advance for your feedback.
Need Help To Determine Exact Line And Column
I need a way to determine exactly where I'm at in a document.
Basically I am searching and replacing text and sometimes I need to insert additional text. For Example if a customer has a second address line I insert it. (See Below) But I'm finding it difficult to line the text up.
To: John Doe
Address Line 1
Address Line 2
City State Zip.
Programatically I have a tag in the document {CustomerName}. I search for customer name and replace it. Then I do the same for {CustomerAddress}. I use the range object to select and replace. Then use the same range object to insertAfter my text afte collapsing the range to the end.
I have tried range.information(Word.WdInformation.wdStartOfRangeColumnNumber) but it does not produce a value or if it does it is bogus. I also looked through all of the allowable variables the range.information object would return. No luck.
Any help on determining exactly which line and column the insertion pointer is at would be appreciated.
Exact Match In Excel Cell
Hi,
I am developing an application that searches thru the cells [data] of an excel sheet. I 'm using the .Find method and things were going well, till I realized that .Find method searches for the first occurance of the search string.
What I want to do is to search for the exact match. Can anyone help me with this? Thanks.
In case, you didnt get it, it's like this.
I want to search for cell containing number 4748. But before that there's another cell with the number 9885744748. When i use .Find method, this long number returns too. I want to search for exact match, i.e. in this case, 4748.
Thanks once again.
voids.
How To Let My Excel Have Exact Columns Number?
Hello, Everyone:
My data sheet has A-R columns and they has different width. So, it show to W column. I need to move scoller to see the first column. Would somebody be kind to let me know how I can remove the spare columns and let it show exact A-R columns which I just want?
Thank you very much!
Charlie
Multiple Forms With Exact Same Code
I really hope someone can help me with this. In my program, I'm gonna have 3 forms that look the same (the user will be entering different data in each). Is there a way to mimic indexing forms? I really do not want to have the exact same code in 3 different forms. Any idea anyone?
Pause For An Exact Amount Of Time
Im almost done with a program that takes all my frames that i exported from a program and puts them together in an AVI file. I have a preview thing, but right now it go just as fast as the timer can go. Is there a way to have the timer repeat with exact time intervals? I remeber a code that paused the script for a time, but im not sure if it could handle miliseconds, and the switch from the pause to the beginning of the script again might be off.
Exact Controlling Of Input Into A Text-box
Hi,
I have tried to figure out how to control the input into a textbox for some time but without any result.
I have a textbox that should contain a cars licence-plate number. I would like to get the checking to happen while the user enters down the number in the field. The format for these plates aree:
AA[A]-9[9[9]]
in other words:
2-3 characters (a-z and åäö)
a dash (-)
1-3 numbers
I have created a If---Then monster in the keypress event that sets keyascii to zero if a wrong key is pressed. What I got to work is the validation of what keys are accepted, but what I can't figure out is how to do the positional checking when the user enters the licence-number...
Here is my "monster" (that is still under work...)
Code:
If (KeyAscii >= 97 And KeyAscii <= 122) Or _
(KeyAscii >= 65 And KeyAscii <= 90) Or _
(KeyAscii >= 48 And KeyAscii <= 57) Or _
((KeyAscii = 229) Or (KeyAscii = 228) Or (KeyAscii = 246) Or _
(KeyAscii = 197) Or (KeyAscii = 196) Or (KeyAscii = 214) Or _
(KeyAscii = 8) Or (KeyAscii = 45)) Then
If ((KeyAscii >= 65 And KeyAscii <= 90)) Or _
((KeyAscii >= 196 And KeyAscii <= 214)) Then
KeyAscii = (KeyAscii + 32)
End If
If ((KeyAscii >= 97 And KeyAscii <= 122)) Or _
((KeyAscii >= 228 And KeyAscii <= 246)) Then
KeyAscii = (KeyAscii - 32)
End If
Select Case Len(txtLicenceNumber.Text)
Case 1 To 2
If Not (Asc(x) >= 65 And Asc(x) <= 122) Then
KeyAscii = 0
End If
Case 3
Debug.Print "3"
Case 4 To 7
Debug.Print "4-8"
End Select
Else
KeyAscii = 0
End If
Rene:
Moving To Exact Cell In Flexgrid
I am using a MSFlexgrid that I am having a text box float around so the grid can be editable. I was wondering if there was any way to go to an exact row,column combination. What I want to see is if there is any way to get around first doing flexgrid1.row = 2 then doing flexgrid1.column = 5. Is there any way to say go to 2,5 without moving to the row then to the column?
Thanks in advance.
SQL Like Statement Only Returning EXACT Matches
MyRecSet.Open "SELECT * FROM ACEMAIN WHERE CUSTOMER = '" & CustName & "'", MyConn, adOpenForwardOnly, adLockReadOnly
I am using this code to execute my query, where it finds an exact match in the recordset for the value supplied by my textbox (CustName). I have altered the statement because I would like to return close matches. If I change the = to Like (see below) it still only returns exact matches. What am I doing wrong? Is it just me, or is this shiznit crazy?
MyRecSet.Open "SELECT * FROM ACEMAIN WHERE CUSTOMER LIKE '" & CustName & "'", MyConn, adOpenForwardOnly, adLockReadOnly
Any help is more than appreciated.
Finding Exact Position In WMV-file
I'm using the MCI API to play media files in my application. I've implemented a slider that shows the current position of the media file while playing. When a user manually scrolls the slider, I use this command to move the media to the correct position:
mciSendString("seek " & AliasName & " to " & to_where, 0&, 0&, 0&)
This works fine with all kind of file types as long as the media file is located on my hard drive, but I can't get it to work when I stream a WMV-file from a server. The command returns with no errors, but the command has no effect. The media file's position is the same as it was before the MCI command.
The strange thing is that it seems to be working when I stream MP3-files from the same server. Why doesn't it work with WMV-files?
Check For Exact Two Sentences In A Field
Hi all,
Each morning i get a excel sheet with each row containing possible two sentences in it.
I have to manually check whether each field contains exact two sentences.
if any field contains more than two sentences or less than two sentences then i have to mark that row a Invalid.
Can anyone help me to automate this process of checking each field for Two sentenses and Invalid marking.
I have attached the sample file.
Thanks in advance.
Get A Controls Exact Screen Location
Ok, in my program I have 2 forms (just a simple walkthrough). Form 1 has an image box. I would like form 2 to position over form 1 in a specific spot. Since form 1 can be moved I need to have form 2 position based on form 1.
I want form 2s top and left points to be the same as the top and left points of the image box on form 1. I cant just use the code form2.top = form 1.top + imagebox.top.
Say image1 top left is 100/200 respectivly. If I say "form2.top = form 1.top + imagebox.top" form 2 positions wrong. THIS DOES NOT take into acount the height of the title bar, and menu, as well as the borders also. Does anyone know how to get the top/left points of a control (in the actuall screen pixles)? Then I can position the form correctly. I need this becuase on windows XP and windows 2000 the title bar and side borders change size.
Let me know if you need more info. Thank you.
|