370 Posted Topics

Member Avatar for seenivasaperuma
Member Avatar for AndreRet
0
57
Member Avatar for huhubebey

TeachLoad is a calculated field, so delete the first "teach.TeachLoad," and delete "teach." after the AS. also I suspect your final field reference in the join should be Staff.StaffNo=Semester.StaffNo.

Member Avatar for ChrisPadgham
0
121
Member Avatar for Polongo

You cannot do this as autonumber, it utilises a long integer data type. If you are adding the data using a form you can add code to the Before_Insert event to generate the number for you. if you moved to SQL-Server for the database engine you could add a trigger …

Member Avatar for ChrisPadgham
0
72
Member Avatar for martin11ph

Setting the KeyPreview property of the Form will enable the Form to process the KeyDown event before any controls on the form do.

Member Avatar for AndreRet
0
2K
Member Avatar for abelingaw

If you are using the SQL, you may like to investigate using the RecordsAffected property to determine whether the row was deleted and inform the user accordingly.

Member Avatar for AndreRet
1
146
Member Avatar for markdean.expres

what is the field type you are storing in. It should be text if you want the exact pattern stored.

Member Avatar for ChrisPadgham
0
91
Member Avatar for Polongo

I am guess there is a key violation, or some other data validation error, ie you are not entering data in a field marked as mandatory in the table. so the record is not being saved. Go through the table definition an check each field to ensure you know all …

Member Avatar for ChrisPadgham
0
87
Member Avatar for cavern

use .Find method to look to see for a record with the same value the .NoMatch property will tell you whether the record exists or not

Member Avatar for ChrisPadgham
0
87
Member Avatar for slugdoug

I am guessing you are not in the C: root when you execute, ie the TestFolder is being created under the folder you are in when execute.

Member Avatar for AndreRet
0
104
Member Avatar for Xjmaslord4

Why not add a command button that has code something like. [CODE] Hours = 2 Minutes = 0 Seconds = 0 Time = TimeSerial(Hours, Minutes, Seconds) Text1.Text = "2" Text2.Text = "0" Text3.Text = "0" Timer1.enabled = true [/CODE] also at line 84 why not say if label1.caption <> "00:00:00" …

Member Avatar for AndreRet
0
180
Member Avatar for PM312
Member Avatar for MaddTechwf
Member Avatar for roachae

[CODE]SELECT a, Count(a) AS CountOfa1 FROM (SELECT Table1.a, Table1.b, Table1.c, Count(Table1.a) AS CountOfa FROM Table1 GROUP BY Table1.a, Table1.b, Table1.c) GROUP BY a; [/CODE] This will return the number of combinations of "b" and "c" for each "a"

Member Avatar for roachae
0
161
Member Avatar for lielee

you could add an audit trail, keep track of who did which transactions when.

Member Avatar for lielee
0
165
Member Avatar for PM312

Find code below however this may not be the best way of achieving what you want. In the LostFocus event, you can check if they have entered a valid date as follows [CODE] if not isdate(text1.text) then msgbox "Please enter a valid date" text1.setfocus text1.selstart = 0 text1.sellength = len(text1.text) …

Member Avatar for PM312
0
68
Member Avatar for game4tress

In line [CODE] Set rsTesteSQL = DBTesteSQL.OpenRecordset("SELECT * FROM test", dbOpenTable, 0, dbOptimistic) [/CODE] dbOpenTable applies to Jet databases only. Try dbOpenDynaset instead.

Member Avatar for AndreRet
0
375
Member Avatar for srinivasan12345

Presumeably you are reading it into an integer variable, which, when you print it will be displayed, by default, in decimal

Member Avatar for AndreRet
0
125
Member Avatar for eiven_05

You want to be careful doing this, it can put quite a strain on the database in a multiuser environment causing performance issues. Order your table by LastName and use a find first to locate the first row that matches rather than requerying the table with each keystroke.

Member Avatar for AndreRet
0
102
Member Avatar for mr-antony

There are plenty of off-the-shelf inventory control products that can do this better and cheaper than writing something yourself. If your requirements are simple there is bound to be some freeware available.

Member Avatar for mr-antony
0
104
Member Avatar for EddyLLC
Member Avatar for ChrisPadgham
0
106
Member Avatar for abelingaw

If you want to go low level and have a printer direct connected to the a printer port (no idea how it handles USB) you can write to it directly as follows [CODE] Open "PRN" For Output As #1 Print #1, "Here is line one" Print #1, "Here is a …

Member Avatar for AndreRet
0
357
Member Avatar for problematic:)

Have you tried binding the text box to a column in the datasource that supplies the datagrid.

Member Avatar for AndreRet
0
103
Member Avatar for PM312

Inside the if/then you should set KeyAscii = 0 since you have handled it. however I don't think that will fix your error. have you tried hitting the Tab key and seeing what happens. Have a look at what is next in the tab order after the text box,

Member Avatar for AndreRet
0
1K
Member Avatar for problematic:)

If you are only interested in valid combinations then it is more user friendly to restrict the population of the second combo [CODE] RS.Open "SELECT UNIQUE FirstName FROM tblrecords WHERE LastName='" & combo1.Text & "'", cn, adOpenStatic, adLockOptimistic [/CODE] Also using the UNIQUE keyword will return only one instance of …

Member Avatar for ChrisPadgham
1
620
Member Avatar for wewehalim

This seems strange when I click "no" it does not append. You can handle it manually if you wish which will overcome the problem. [CODE] If MsgBox("are you sure you want to append these records", vbYesNo) = vbYes Then DoCmd.SetWarnings False DoCmd.OpenQuery "Query4" DoCmd.SetWarnings True End If [/CODE]

Member Avatar for ChrisPadgham
0
137
Member Avatar for keeda

If all three tables have the same primary key then all of the fields should be in the one table. There is no point in having them in separate tables.

Member Avatar for Dilton1958
0
173
Member Avatar for ame1904

A text field will allow alpha numeric input. You can put a mask on it to specify the format of the input but personally I wouldn't, I don't find them particualarly user friendly.

Member Avatar for ame1904
0
120
Member Avatar for Anila S

I think you will find that SQL uses the american date format mm/dd/yyyy, I usually find it safer to use dd-mmm-yyyy eg 14-jun-2010

Member Avatar for Bashir ahmad
0
107
Member Avatar for John888

Doesn't sound like you should be storing the second date in a field, put a text box on the screen and in its control source put the expression =dateadd("m",1, me.firstdate)

Member Avatar for ChrisPadgham
0
104
Member Avatar for ashukite

You should not be storing the total in the database it is a derived value and should be calculated on the fly as you need it. Storing derived values increases the complexity of your application and provides for data inconsistencies to arise. For example, if they don't balance how do …

Member Avatar for tuntunbabu
0
144
Member Avatar for wchitamb

If you have linked the form and subform using the Link Child and Master field properties (see attachment) then you should not be setting the Id in the child form, it will be populated automatically for you from the Master. For the second problem you are better to set up …

Member Avatar for ChrisPadgham
0
90
Member Avatar for Access07-Jon

Perhaps you could driving it off the parent form. If you are displaying the child form as a result of clicking a button, include in there the code. You will need to alter the image assignment statement Me.mysubform.Image1.Picture = ImageLogoPath

Member Avatar for ChrisPadgham
0
82
Member Avatar for Ranvijay87

[code] SELECT TOP 10 StudentName, StudentMark FROM StudentResults ORDER BY StudentMark DESC; [/code]

Member Avatar for ChrisPadgham
0
84
Member Avatar for leverin4

another approach Retrieve your combo box values from a table with 2 columns as follows cm,A inches,A mm,A lbs,B kg,B g,B etc the source query for combo 2 should contain both columns with a condition on the second column of the value of the first combo, eg Forms![myform].combo1 in the …

Member Avatar for ChrisPadgham
0
115
Member Avatar for carlakawill

I am not a C# programmer but something like below adjusted if necessary for C# WHERE Shift.SDate >=#" + format$(tbStartDate.Text,"mm/dd/yy") + "# and Shift.SDate <=#" + format$(tbEndDate.Text,"mm/dd/yy") + "#");

Member Avatar for ChrisPadgham
0
73
Member Avatar for Stevoni

with 9 boolean variables that is 512 combinations If you are not into maths this is going to freak you out a bit but the best approach is to resort to binary. An integer in binary form consists of a series of 1s and 0s that can represent your 9 …

Member Avatar for Stevoni
0
173
Member Avatar for bigtreeworld
Member Avatar for Subathiran
Member Avatar for mrnobody
Member Avatar for mrnobody
0
1K
Member Avatar for terdie

You are better to put a OrderCancelledDate field in the table. It provides more information to the user. If is is null then the order has not been cancelled.

Member Avatar for ChrisPadgham
0
94
Member Avatar for comsci2
Member Avatar for nelly_1005

Here is a piece of code that does something similar to what you want I thnk. [CODE]Dim WhereClause As String Dim AndStr As String AndStr = "" If Me.SearchName <> "" Then WhereClause = "(FirstName like '*" & Me.SearchName & "*' OR Surname like '*" & Me.SearchName & "*')" AndStr …

Member Avatar for ChrisPadgham
0
4K
Member Avatar for emmas4impact

if you posted it in a format that I could read you would stand a much better chance of an answer

Member Avatar for emmas4impact
-1
103
Member Avatar for ChrisPadgham

I have this problem from time to time, and at the moment. I set a breakpoint in the code to debug. I remove the breakpoint after I am finished but the program still pauses at that point. Press F5 and it continues fine. Close the database and reopen it and …

0
66
Member Avatar for bluecollagirl

units sold is the quantity which is why you are getting the same answer. are you sure the problem is not best selling products by price and quantity.

Member Avatar for bluecollagirl
0
157
Member Avatar for Myko17

<> is not equal to Unless I am going senile there are no circumstances where three lengths cannot make a triangle.

Member Avatar for ChrisPadgham
0
174
Member Avatar for tdspaul

Why don't you write an update SQL to update the table directly rather than bring it into a ds. eg UPDATE DurexBOL SET WebSvc=Yes WHERE WebSvc=No below is the code from the vb help file for executing non-query SQL [Code] Public Sub CreateCommand(ByVal queryString As String, _ ByVal connectionString As …

Member Avatar for kvprajapati
0
106
Member Avatar for tqmd1

I think you should have ActiveSheet in the assignment line (12) [Code] ExcelSheetFO.ActiveSheet.Cells(2, i) = "Some value" [/code]

Member Avatar for tqmd1
-1
147
Member Avatar for Gotang

Have you considered using either an array (choice 1) or a collection (choice 2) that you can iterate through [code] 'choice 1 Dim i As Integer Dim tbarray(10) As TextBox For i = 0 To Val(Form1.ChannelTextBox1.Text) - 1 ' set your values Next i 'choice 2 Dim tblist As New …

Member Avatar for Gotang
0
728
Member Avatar for samuel_1991

I don't think you should use GETDATE, you should hold the date of purchase in ShopCart otherwise when you run this query later you will get a different result.

Member Avatar for samuel_1991
0
177

The End.