Hi all,
I am parsing a relatively large text file, and I need to split the information into various fields, and then insert the parsed data into a database.
At the moment, I have the parsing bit working fine, and I create an array to temporarily hold all the information - this is a 2-dimension...
Just started with Visual Basic Express 2008, after coming from an Access and VBA background.
I am trying to do is loop through a multi-select listbox and retrieve all the selected items, but it doesnt want to play nice.
What I have tried:
***********************
For Each varItem...
Wow, this is driving me crazy.
Just started with Visual Basic Express 2008, after coming from an Access and VBA background.
All I am trying to do is loop through a multi-select listbox and retrieve all the selected items, but it doesnt want to play nice.
What I have tried:
For...
I have a select distinct query as follows:
SELECT DISTINCT [MergeString] FROM qryMergeTime
Whilst this does return the right records (i,e. only shows unique records in the [MergeString] field, it doesnt show all the fields that I need to see, i.e. the SELECT DISTINCT function needs to run on...
Hi all,
Need some tips to help me approach this problem. I would consider myself advanced in Access and VBA, so just looking for conceptual pointers.
In essence, I have a number of text files, each of which contains data that is parsed into various database tables. The data thus stored in the...
Hi,
I have written the following procedure which prevents duplicate records from being inserted into a table. This works 100%, but was wondering if there were any other (more efficient?) ways of doing this. I am aware that this could be done with table definitions, but not quite sure of the...
As a general efficiency topic, I have the following question:
Assuming two tables in a one to many relationship, fully normalised, and a main form and sub form based on these tables.
The 'usual' way of linking these is to create a parent/child relationhip between the main and sub form, thereby...
Hi,
I have a multi-column listbox in an excel userform that is populated from a recordset (using .getrows). The recordset is from an Access database.
One of the columns in the listbox is a date field and although the date format in the Access database is DD/MM/YY (and I have verified that all...
I have a pretty complex Excel model that has about 25 sheets. The model captures about 300 variables, spread over a few of these sheets. Each of these 300 variables has been named in Excel.
We run this model for different scenarios a couple of times a day and each time we save-as with a new...
Typically, when using ADO recordsets, I like to keep everything nice and tidy. So, I always end off with the following:
cnn.close
set cnn = nothing
rsRecordset.close
set rsRecordset = nothing
However, there are times when I want to keep a recordset open all the time, especially when the...
Typically, when using ADO recordsets, I like to keep everything nice and tidy. So, I always end off with the following:
cnn.close
set cnn = nothing
rsRecordset.close
set rsRecordset = nothing
However, there are times when I want to keep a recordset open all the time, especially when the...
I have used a function from Dev Ashish's website (www.mvps.org/access) in my access project to get the user's network login name. The code is as follows:
Private Declare Function apiGetUserName Lib "advapi32.dll" Alias _
"GetUserNameA" (ByVal lpBuffer As String, nSize As Long) As Long...
Hi,
I have a command button on a form that runs a whole bunch of code (such as a few sql inserts, filecopy, etc) - lets call this Procedure A.
About half way through running procedure A, I want to halt and a small pop-up form to be opened. Once the user has populated a few fields on the...
OK, this has got to be one of the weirdest things I have seen in Access.
I have a subform, where all the controls are (with the exception of a command button for each record) are locked and not enabled. This all works fine.
I then added conditional formatting to the subform, and those records...
I have a combobox on a form that I want to use as the criteria for a query. The combobox rowsource is as follows:
SELECT [TopicID],[Topic] FROM tblSiteTopic UNION Select 99 as AllChoice, "(All)" as Bogus from tblSiteTopic ORDER BY [Topic];
Essentially, the Union part allows me to select...
Hi, I am trying to get a combobox on a form to be populated by a recordset. I am using the following code, but always get a "Type Mismatch" error on the "cboSiteName.RowSource = rsSite" line.
What am I doing wrong?
Thanks for the help!
Dim cnn As ADODB.Connection
Dim rsSite As ADODB.Recordset...
Hi,
I have tblStockPurchaseDetail that records stock purchases (with fields such as PurchaseID, Description, StockCode, Price, Quantity, etc). I may obviously purchase the same StockCode more than once.
I also have tblSockSaleDetail that records sales (wih fields such as SaleID, StockCode...
Hi, I am quite new to ado and dao, and by the looks of things, ado is the preferred method (bearing in mind future proofing of applications).
I am trying to prevent a form opening if there are no records, and have tried both ADO and DAO, but cant seem to get it right. Any help appreciated...
I have a continuous subform that lists all the Memo's associated with a particular Company (specified on the main form). Each Company can have many Memo's.
Next to each Memo record on the subform, I have a comand button (btnMemoPopup) that opens a new form (popup and modal), showing all of the...
I have a main form with an option group that allows users to choose one of 5 options (although this may increase). The forms also has 5 hidden subforms and depending on which one of the 5 choices options are chosen, then one of five sub forms will be made visible.
In order to do this, I think...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.