User Profile
Collapse
-
you just insert record in a row and dont blank the primary key field..... u can insert properly record using this way -
What does the error message say? -
You can create a variable that holds today's date when the form opens. Then whatever triggers a new record or page change can increment this variable i.e.
Code:dim dte as date sub form_open dte = date end sub sub newpage() dte = dte + 1 end sub
Leave a comment:
-
Could you clarify this a little, I'm having trouble following exactly what it is you are doing. You mention that you have to loop through a file and then go on to call it a table as far as I can tell. Are you ultimately needing to deal with a file or tables. What are all the fields in those tables? Is it that you have field full of id numbers and if you come across a certain number then a blank should be appended after that number (within the...Leave a comment:
-
This depends on what you mean by change page, and how you are doing that. It sounds like you need to respond to whatever event a page change is and populate the appropriate control or record with today's date. the Functions Now or Date will return today's date. If you add a few more details we can probably zero in on what you need.Leave a comment:
-
I tested this in xl 2003 and assume it is the same. You need to invoke the copy method of the chartobjects, not the sheet itself. Such as:
Code:Excel.Worksheets("Sheet1").ChartObjects.Copy Excel.Worksheets("Sheet2").Paste
Leave a comment:
-
-
If you want to return the field names as the result of a query i.e. if you have a table with Field1, Field2 and you want to return something like:
Fields
Field1
Field2
I don't know of a way to do that using a query. You would have to use a recordset or some other mechanism to do the transposition. It's possible, and not that difficult, but it cannot be done with SQL alone.Leave a comment:
-
Yes, for every class if you include this sub it will run on instantiation of the object:
Code:Private Sub Class_Initialize() 'Do whatever here End Sub
Leave a comment:
-
The easiest way to do this depends on how you are entering the data. If the form is bound to the underlying table then I would set the default value property of the relevant fields to the relevant names (in the underlying datasource). That way any time a record is added it will be populated by the database. However, if you are using the input values as part of a query (i.e. you append those values as a record in the table) then you can either...Leave a comment:
-
Thanks Linq,
I was posting in the event that you were interested in finding the absolute value for the duration of tasks you complete before you begin. Thanks for the correction, foolish mistake on my part.Leave a comment:
-
Right now you are attempting to automate Access, which doesn't get you where you want to go because you're trying to put the application logic in vb.net. In other words what you want access to is not the Access objects, but the Data objects. To do this you will need to read up on ADO.net, the data connection API provided by the .net framework. In your case you will want to use OleDb. This gives you the ability to pull data from a table (or query)...Leave a comment:
-
janders468 started a topic Opening Mdb bypassing AutoExec with C# Solved, but curious about why solution worksin .NETOpening Mdb bypassing AutoExec with C# Solved, but curious about why solution works
Hi,
I have been messing around with automating Access (I am attempting to actually manipulate the Access objects themselves so it requires going beyond data access) from a c# program (long story as to why, but any how...). I am dealing with databases that all have AutoExec macros within them which automatically run when the database opens, which I don't want the database to do. In Access this is bypassed by holding down the shift... -
Let me know if you have questions, there are several simple things that could cause this to fail, so if it doesn't work we can certainly work through that.Leave a comment:
-
Using a parameterized query makes this difficult, but typically if all you are returning is one value then I find a dlookup the best way to go. A dlookup takes two required parameters and one optional. The first is the field that contains the value you are interested in, the second is the table or query the field is contained within, and the the third is an optional criteria, it then returns the value from the field you specified in the first argument...Leave a comment:
-
I should also have asked, what field are you interested in populating the textbox with?Leave a comment:
-
I would check out the DateDiff function built in to access for example to calculate the above would be:
Code:DateDiff("s", #09:05:00#, #09:00:00#)
Leave a comment:
-
I am unfamiliar with EOMONTH, is this a built in function (I am assuming you are using Excel?). We'll need a little more information to try and figure out what your requirements are. i.e. what are the inputs and the expected outputs of this function?Leave a comment:
-
If you go into the form properties under the format tab is a property titled 'Navigation buttons' set this to no and they should go away.Leave a comment:
-
You are not signifying your where clause as a where clause it should read:
Code:DoCmd.RunSQL "DELETE * FROM Budget_Planner_SubDatasheet WHERE CompanyStore = 'Begining Balance';"
Leave a comment:
No activity results to display
Show More
Leave a comment: