Posting function using API calls for review

Hi Experts,

I am working a long time on a VBA function that will constantly be reading (txt data) files in a loop and transfer data to a web hosted software using API calls.

Would like to know if you can spot any serious bugs before releasing it.

Attaching the full code.

Thanks in Advance.
1.txt
LVL 6
bfuchsAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Scott McDaniel (Microsoft Access MVP - EE MVE )Infotrakker SoftwareCommented:
Can you tell us the code flow - i.e. "I call this routine to do xxx, then call this to do yyyy".
ste5anSenior DeveloperCommented:
I would clean up the code. As it seems to be hosted by Access, use strong typing thus late binding. Also you can refactor it. Some methods do more then necessary. Error handling is incomplete, not every function has it and it seems to be disruptive (using MsgBox).

From the architecutral viewpoint:
It seems like you want to transfer data from a file to a web service. Cause we use Access, here you really should consider a three step approach. Import the file into a (staging) table. Clean up the data. Run the web service calls over the rows in that table.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
bfuchsAuthor Commented:
Hi Experts,

Can you tell us the code flow...
Sure, this is the story...
We have a Powershell script that downloads data files from a FTP site every 5 minutes (see attached file list).

So the plan is to have the following call constantly running.
Public Sub ExecuteCaspioSched()
    Dim i As Integer
    Do
               Call CallImportDataToCaspio
    Loop
End Sub

Open in new window

This will call the sub CallImportDataToCaspio()
And this will call the ImportDataToCaspio(strTable, sDir & StrFile, i) with the right params.
The function ImportDataToCaspio() is in charge of reading and exporting the data to the web...

Perhaps would need to clean up the code in general as Ste5an put it...however at the moment I'm mainly focusing on things that can prevent the program from successfully functioning, or worse stop the program from executing altogether...-:(

...not every function has it and it seems to be disruptive (using MsgBox).
Good point.

Thanks,
Ben
Capture.PNG
Fundamentals of JavaScript

Learn the fundamentals of the popular programming language JavaScript so that you can explore the realm of web development.

David Johnson, CDRetiredCommented:
line 620 Currentdb is not declared
objhttp is not declared
method arguments must be enclosed in parentheses

Severity      Code      Description      Project      File      Line      Suppression State
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      558      Active
Error      BC30451      'access_token' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      455      Active
Error      BC30451      'access_token' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      481      Active
Error      BC30451      'access_token' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      497      Active
Error      BC30451      'access_token' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      505      Active
Error      BC30451      'access_token' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      611      Active
Error      BC30451      'access_token' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      616      Active
Error      BC30451      'Close' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      259      Active
Error      BC30451      'Close' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      494      Active
Error      BC30451      'Close' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      636      Active
Error      BC30451      'CurrentDb' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      620      Active
Error      BC30451      'CurrentProject' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      208      Active
Error      BC30451      'Eval' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      29      Active
Error      BC30456      'Execute' is not a member of 'Module2.Database'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      88      Active
Error      BC30456      'Execute' is not a member of 'Module2.Database'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      558      Active
Error      BC30451      'JsonConverter' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      613      Active
Error      BC30451      'JsonConverter' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      617      Active
Error      BC30451      'JsonConverter' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      619      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      23      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      26      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      30      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      32      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      38      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      40      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      42      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      58      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      107      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      109      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      117      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      224      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      285      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      298      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      299      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      301      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      307      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      312      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      393      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      395      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      396      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      399      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      443      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      445      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      446      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      458      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      498      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      499      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      509      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      511      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      512      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      515      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      605      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      637      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      655      Active
Error      BC30807      'Let' and 'Set' assignment statements are no longer supported.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      666      Active
Error      BC30451      'Line' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      394      Active
Error      BC30451      'Line' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      404      Active
Error      BC30451      'Line' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      510      Active
Error      BC30451      'Line' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      519      Active
Error      BC30451      'Null' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      217      Active
Error      BC30451      'Nz' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      578      Active
Error      BC30451      'objHTTP' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      667      Active
Error      BC30451      'objHTTP' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      668      Active
Error      BC30451      'objHTTP' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      669      Active
Error      BC30451      'objHTTP' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      670      Active
Error      BC30451      'objHTTP' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      673      Active
Error      BC30451      'Open' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      392      Active
Error      BC30451      'Open' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      508      Active
Error      BC30207      'Option Compare' must be followed by 'Text' or 'Binary'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      2      Active
Error      BC30508      'pdb' cannot expose type 'Module2.Database' in namespace 'ee29132848' through module 'Module2'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      11      Active
Error      BC30508      'pdb' cannot expose type 'Module2.Database' in namespace 'ee29132848' through module 'Module2'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      122      Active
Error      BC30811      'ReDim' statements can no longer be used to declare array variables.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      391      Active
Error      BC30811      'ReDim' statements can no longer be used to declare array variables.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      434      Active
Error      BC30811      'ReDim' statements can no longer be used to declare array variables.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      438      Active
Error      BC30811      'ReDim' statements can no longer be used to declare array variables.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      463      Active
Error      BC30811      'ReDim' statements can no longer be used to declare array variables.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      483      Active
Error      BC30811      'ReDim' statements can no longer be used to declare array variables.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      487      Active
Error      BC30451      'RegSplit' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      372      Active
Error      BC30451      's' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      619      Active
Error      BC30451      's' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      620      Active
Error      BC30451      's' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      672      Active
Error      BC30451      's' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      673      Active
Error      BC30389      'System.Empty' is not accessible in this context because it is 'Friend'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      587      Active
Error      BC30389      'System.Empty' is not accessible in this context because it is 'Friend'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      590      Active
Error      BC30389      'System.Variant' is not accessible in this context because it is 'Friend'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      11      Active
Error      BC30389      'System.Variant' is not accessible in this context because it is 'Friend'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      122      Active
Error      BC30389      'System.Variant' is not accessible in this context because it is 'Friend'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      664      Active
Error      BC30389      'System.Variant' is not accessible in this context because it is 'Friend'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      664      Active
Error      BC30389      'System.Variant' is not accessible in this context because it is 'Friend'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      161      Active
Error      BC30451      'tLookupDoNothing' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      122      Active
Error      BC30451      'url' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      447      Active
Error      BC30451      'url' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      449      Active
Error      BC30451      'url' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      459      Active
Error      BC30451      'url' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      469      Active
Error      BC30451      'url' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      470      Active
Error      BC30451      'url' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      471      Active
Error      BC30451      'url' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      472      Active
Error      BC30451      'url' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      474      Active
Error      BC30451      'url' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      478      Active
Error      BC30451      'url' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      500      Active
Error      BC30451      'url' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      501      Active
Error      BC30451      'url' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      606      Active
Error      BC30451      'url' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      608      Active
Error      BC30451      'url' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      665      Active
Error      BC30451      'url' is not declared. It may be inaccessible due to its protection level.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      667      Active
Error      BC30804      'Variant' is no longer a supported type; use the 'Object' type instead.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      11      Active
Error      BC30804      'Variant' is no longer a supported type; use the 'Object' type instead.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      122      Active
Error      BC30804      'Variant' is no longer a supported type; use the 'Object' type instead.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      161      Active
Error      BC30804      'Variant' is no longer a supported type; use the 'Object' type instead.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      664      Active
Error      BC30804      'Variant' is no longer a supported type; use the 'Object' type instead.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      664      Active
Error      BC30455      Argument not specified for parameter 'FileName' of 'Public Sub FileOpen(FileNumber As Integer, FileName As String, Mode As OpenMode, [Access As OpenAccess = [Default]], [Share As OpenShare = [Default]], [RecordLength As Integer = -1])'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      258      Active
Error      BC30455      Argument not specified for parameter 'Mode' of 'Public Sub FileOpen(FileNumber As Integer, FileName As String, Mode As OpenMode, [Access As OpenAccess = [Default]], [Share As OpenShare = [Default]], [RecordLength As Integer = -1])'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      258      Active
Error      BC32059      Array lower bounds can be only '0'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      391      Active
Error      BC32059      Array lower bounds can be only '0'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      434      Active
Error      BC32059      Array lower bounds can be only '0'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      438      Active
Error      BC32059      Array lower bounds can be only '0'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      463      Active
Error      BC32059      Array lower bounds can be only '0'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      483      Active
Error      BC32059      Array lower bounds can be only '0'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      487      Active
Error      BC32017      Comma, ')', or a valid expression continuation expected.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      258      Active
Error      BC32017      Comma, ')', or a valid expression continuation expected.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      392      Active
Error      BC32017      Comma, ')', or a valid expression continuation expected.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      394      Active
Error      BC32017      Comma, ')', or a valid expression continuation expected.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      404      Active
Error      BC32017      Comma, ')', or a valid expression continuation expected.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      508      Active
Error      BC32017      Comma, ')', or a valid expression continuation expected.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      510      Active
Error      BC32017      Comma, ')', or a valid expression continuation expected.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      519      Active
Error      BC30201      Expression expected.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      122      Active
Error      BC30201      Expression expected.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      122      Active
Error      BC30201      Expression expected.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      494      Active
Error      BC30201      Expression expected.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      636      Active
Error      BC30201      Expression expected.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      651      Active
Warning      BC42105      Function 'ListRecords' doesn't return a value on all code paths. A null reference exception could occur at run time when the result is used.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      333      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      28      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      48      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      88      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      92      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      236      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      258      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      259      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      315      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      319      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      392      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      394      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      404      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      449      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      450      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      452      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      478      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      479      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      480      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      481      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      494      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      501      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      502      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      503      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      508      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      510      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      519      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      608      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      609      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      610      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      611      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      612      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      613      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      617      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      620      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      636      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      646      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      667      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      668      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      669      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      670      Active
Error      BC30800      Method arguments must be enclosed in parentheses.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      673      Active
Error      BC30452      Operator '&' is not defined for types 'String' and 'ErrObject'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      48      Active
Error      BC30452      Operator '&' is not defined for types 'String' and 'ErrObject'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      236      Active
Error      BC30452      Operator '=' is not defined for types 'ErrObject' and 'Integer'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      229      Active
Error      BC30812      Optional parameters must specify a default value.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      122      Active
Error      BC30812      Optional parameters must specify a default value.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      122      Active
Error      BC30812      Optional parameters must specify a default value.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      651      Active
Error      BC30516      Overload resolution failed because no accessible 'Input' accepts this number of arguments.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      394      Active
Error      BC30516      Overload resolution failed because no accessible 'Input' accepts this number of arguments.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      404      Active
Error      BC30516      Overload resolution failed because no accessible 'Input' accepts this number of arguments.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      510      Active
Error      BC30516      Overload resolution failed because no accessible 'Input' accepts this number of arguments.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      519      Active
Error      BC32042      Too few type arguments to 'Dictionary(Of TKey, TValue)'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      355      Active
Error      BC30002      Type 'ADODB.Recordset' is not defined.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      160      Active
Error      BC30002      Type 'DAO.Database' is not defined.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      159      Active
Error      BC30002      Type 'DAO.Parameter' is not defined.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      19      Active
Error      BC30002      Type 'DAO.QueryDef' is not defined.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      17      Active
Error      BC30002      Type 'DAO.Recordset' is not defined.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      18      Active
Error      BC30002      Type 'IXMLDOMNode' is not defined.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      360      Active
Error      BC30002      Type 'IXMLDOMSelection' is not defined.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      361      Active
Error      BC30002      Type 'MSXML2.DOMDocument' is not defined.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      358      Active
Error      BC30002      Type 'WinHttp.WinHttpRequest' is not defined.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      357      Active
Warning      BC42099      Unused local constant: 'ForReading'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      296      Active
Warning      BC42024      Unused local variable: 'colMatches'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      294      Active
Warning      BC42024      Unused local variable: 'file'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      101      Active
Warning      BC42024      Unused local variable: 'FolderPath'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      100      Active
Warning      BC42024      Unused local variable: 'fso'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      99      Active
Warning      BC42024      Unused local variable: 'i'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      243      Active
Warning      BC42024      Unused local variable: 'objFSO'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      297      Active
Warning      BC42024      Unused local variable: 'strMatch'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      295      Active
Error      BC30311      Value of type 'ErrObject' cannot be converted to 'Integer'.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      260      Active
Warning      BC42104      Variable 'cnt' is used before it has been assigned a value. A null reference exception could result at runtime.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      113      Active
Warning      BC42104      Variable 'db' is used before it has been assigned a value. A null reference exception could result at runtime.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      88      Active
Warning      BC42104      Variable 'db' is used before it has been assigned a value. A null reference exception could result at runtime.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      558      Active
Warning      BC42104      Variable 'g' is used before it has been assigned a value. A null reference exception could result at runtime.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      372      Active
Warning      BC42104      Variable 'l' is used before it has been assigned a value. A null reference exception could result at runtime.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      401      Active
Warning      BC42104      Variable 'lineOfFile' is used before it has been assigned a value. A null reference exception could result at runtime.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      394      Active
Warning      BC42104      Variable 'newFile' is used before it has been assigned a value. A null reference exception could result at runtime.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      319      Active
Warning      BC42104      Variable 'objFile' is used before it has been assigned a value. A null reference exception could result at runtime.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      309      Active
Warning      BC42104      Variable 'objFile2' is used before it has been assigned a value. A null reference exception could result at runtime.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      313      Active
Warning      BC42104      Variable 'objRegEx' is used before it has been assigned a value. A null reference exception could result at runtime.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      303      Active
Warning      BC42104      Variable 'objRegExp_1' is used before it has been assigned a value. A null reference exception could result at runtime.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      286      Active
Warning      BC42104      Variable 'oFile' is used before it has been assigned a value. A null reference exception could result at runtime.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      110      Active
Warning      BC42104      Variable 'prm' is used before it has been assigned a value. A null reference exception could result at runtime.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      27      Active
Warning      BC42104      Variable 'qdf' is used before it has been assigned a value. A null reference exception could result at runtime.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      25      Active
Warning      BC42104      Variable 'recCnt' is used before it has been assigned a value. A null reference exception could result at runtime.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      114      Active
Warning      BC42104      Variable 'rst' is used before it has been assigned a value. A null reference exception could result at runtime.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      33      Active
Warning      BC42104      Variable 'sFileStr' is used before it has been assigned a value. A null reference exception could result at runtime.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      61      Active
Warning      BC42104      Variable 'sPKField' is used before it has been assigned a value. A null reference exception could result at runtime.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      459      Active
Warning      BC42104      Variable 'strTable' is used before it has been assigned a value. A null reference exception could result at runtime.      ee29132848      C:\Users\david\Source\Repos\ee29132848\ee29132848\Module2.vb      84      Active
it_saigeDeveloperCommented:
David Johnson just broke the internet.  :D

-saige-
ste5anSenior DeveloperCommented:
So, that's a buffer overflow in action ;)
bfuchsAuthor Commented:
Thank you!
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Regular Expressions

From novice to tech pro — start learning today.