ADezii
“Create a Blank Excel Spreadsheet from a predetermined Path” ………. This is exactly what I was looking for
Thanks ADezii and Stewart
User Profile
Collapse
-
-
save the file in Excel format
Hi,
The below code will allow the user to open the Save As dialog box,
Now my question is : after the user specify the file name and the path, how can I modify the below code in order to save the file in Excel format when the user click on the Save button
What I need is to use the file name which was specified by the user in the dialog box , and then create an Excel file using the same name &... -
Error message with declaring variable as a FileDialog
Hi
I am trying to declare a variable as a FileDialog object in VB for MS Access 2007
Dim fd As FileDialog
But, I am receiving an error message “ Compiler error : User-Defined type not defined”
Can you please help here? -
Thanks Delerna for your reply , but unfortunately the link to a worksheet from an existing Excel file doesn’t help in my case
Is there any way that I can export MS Access records and append at the same time to Excel file?Leave a comment:
-
How to append data to an existing file using DoCmd.OutputTo
Hi,
I have the following code which works fine in MS Access 2007. It export current access form records to an excel sheet:
DoCmd.OutputTo acOutputQuery, "RunQuery", acFormatXLSX, , True
Is it possible to append data from this form to an existing excel sheet instead of creating new one or replacing the existing one?
Your help is highly appreciated -
-
how can I add or remove fields
Hi,
I have a Form and SubFrom in MS Access 2007 , the SubForm default view is “Datasheet”
Now, after I run the main Form with the imbedded SubForm , how can I add or remove fields form the SubFrom using VB ( adding and removing fields will be controlled from the main Form)
Your help is highly appreciated. -
-
I am running this code via the Forms of MS Access and [Product Name] is TextLeave a comment:
-
Too few parameters
when I run the below Code :
I get the following error message " Too few parameters. Expected 1. (Error 3061)"Code:Dim dbsCurrent As Database Set dbsCurrent = CurrentDb dbsCurrent.Execute "INSERT INTO [Product information] ([Product Name]) VALUES " & "(" & [NewProdName] & ")"
can some one help me with this issue? -
-
Thanks Scott and JConsulting for your replies.
I would appreciate if you can provide me with an example of How to store SQL result into variable assuming that the SQL statement will return only single value.Leave a comment:
-
How can I store SQL result into variable?
I need to know how can I store SQL result into variable, I have used the below code but it dose not work.
Is there an easier way to do this?
---------------------------------------------------------
Dim dbsCurrent As Database
Dim count As Recordset
Dim result As String
Set dbsCurrent = CurrentDb
Set count = dbsCurrent.Open Recordset("SELE CT Estate.Electric MeterNumber... -
Thanks Scott for your efforts
I will check the query design grid and see the resultsLeave a comment:
-
Yes, I have already changed the regional settings to use Hijri date, but no luckLeave a comment:
-
Thanks Scott for your replay, but still its not working
I will explain the problem with more details and examples as follows:
When I use the below code to insert the Hijri date “2 / 9 / 1428” which is equivalent to “14 / 9 / 2007” , MS Access will recognize and insert the date “2 / 9 / 1428” as Gregorian date and since I have already selected the option to use “Hijri Calendar”, MS Access will convert...Leave a comment:
-
SQL insert into with Hijri date
I have a problem with Insert into SQL statement. When I use the below SQL to insert a Hijri date , the date will be stored in the table as Gregorian date.
How can I specify the date that I am inserting into the table is Hijri date not Gregorian date.
Code:dbsCurrent.Execute "INSERT INTO Rent ([RentDueDate]) VALUES" & "(#" & [Text_RentDueDate] & "#)"
No activity results to display
Show More
Leave a comment: