Search found 69 matches

by Tourless
Wed Mar 31, 2021 9:02 pm
Forum: Technical / Scripting
Topic: MS Access VB Error 2220
Replies: 3
Views: 2129

MS Access VB Error 2220

Hi Folks, I'm in the early stages of developing a new routine and the first thing I'm doing is opening a Microsoft Access DB (.accdb). There is a form load event that takes place when the file is open which looks to pull in a jpg image located on a network drive (T:\Images\no-image.jpg). When I open...
by Tourless
Fri Oct 11, 2019 1:53 pm
Forum: Technical / Scripting
Topic: xlGetSheetDims returns wrong number of rows
Replies: 4
Views: 3076

Re: xlGetSheetDims returns wrong number of rows

I think Grovkillen is on the right track. I wouldn't mind betting if you were to copy and paste those 1061x18 into a new sheet it'll find the correct dimensions. Yep, new sheet! I dumbed down my query to 29 rows of data. In my master spreadsheet I remove then add a new sheet to perform my manipulat...
by Tourless
Thu Oct 10, 2019 12:57 pm
Forum: Technical / Scripting
Topic: xlGetSheetDims returns wrong number of rows
Replies: 4
Views: 3076

Re: xlGetSheetDims returns wrong number of rows

Are you sure you haven't clicked or marked a cell some rows below? What you see isn't always what Excel sees... Yeah, I'm pretty sure. I guess it's time to take half a step back and work with a subset of my data. I'll let you know what if anything I find. After all , the answer has to be somewhere.
by Tourless
Wed Oct 09, 2019 8:28 pm
Forum: Technical / Scripting
Topic: xlGetSheetDims returns wrong number of rows
Replies: 4
Views: 3076

xlGetSheetDims returns wrong number of rows

Hi Folks, I'm working on a script that opens an excel file, runs a macro that, among other things, copies one of the sheets to a new workbook, saves that new workbook with in a specific place with a specific name, and closes both Excel files. Then, I open the newly created file and get it's dimensio...
by Tourless
Wed Oct 02, 2019 6:35 pm
Forum: Technical / Scripting
Topic: extracting values from a text file
Replies: 1
Views: 1796

extracting values from a text file

Hi Folks, Having a hard time getting my head around what is needed to accomplish extracting values from a txt file. The file in question is a result of an API GET call that dumps every field for every entry where I only need one. There is a field called idLandmark which shows up repeatedly in my txt...
by Tourless
Fri Sep 27, 2019 2:33 pm
Forum: Technical / Scripting
Topic: Excel/VBScript & LastRow Function
Replies: 3
Views: 3134

Re: Excel/VBScript & LastRow Function

Brilliant! Now I've got two new scripts that interact with excel files that auto-update upon opening. It goes like this... The script opens the Excel file. Excel updates itself and the script takes a handful of variables from one of the sheets. The script then launches a production program, logs in,...
by Tourless
Mon Sep 23, 2019 7:01 pm
Forum: Technical / Scripting
Topic: Excel/VBScript & LastRow Function
Replies: 3
Views: 3134

Excel/VBScript & LastRow Function

Hi Folks, In excel vba projects I often use a function to find the last row of data on a given sheet... Function LastRow(targetSheet As Worksheet, Optional targetCol As String = "A") With targetSheet LastRow = .Cells(.Rows.Count, targetCol).End(xlUp).row End With End Function I'm having a hard time ...
by Tourless
Wed Aug 14, 2019 7:30 pm
Forum: Technical / Scripting
Topic: multiple instances of a single macro
Replies: 1
Views: 1624

multiple instances of a single macro

Hi Folks, Had a strange thing happen to me the other day... I noticed my scheduler window had multiple instances of a single macro listed over and over. If I delete any one of them and then try to edit or run one of the others, I'm met with a 'can't be found' message and I have to restore the script...
by Tourless
Mon Jun 10, 2019 2:02 pm
Forum: Technical / Scripting
Topic: Date Format Problem
Replies: 5
Views: 3334

Re: Date Format Problem

GoSub>MONTHS_FIX Month>MONTH_NUMBER MidStr>1,1,TEST If>TEST=0 MidStr>2,1,MONTH_NUMBER EndIf> Let>VERBOSE_MONTH_NAME=MONTH_NAME_%MONTH_NUMBER% SRT>MONTHS_FIX Let>RAW_LIST=January|February|March|April|May|June|July|August|September|October|November|December Separate>RAW_LIST,|,MONTH_NAME END>MONTHS_F...
by Tourless
Thu Jun 06, 2019 5:32 pm
Forum: Technical / Scripting
Topic: Date Format Problem
Replies: 5
Views: 3334

Re: Date Format Problem

Well I came up with something that I don't think is pretty but it works... I'd love to hear how others have solved this problem, I can't be the only one. :D Month>m If>m=01 mm=January ELSE IF>m=02 Let>mm=February ELSE IF>m=03 Let>mm=March ELSE IF>m=04 Let>mm=April ELSE IF>m=05 Let>mm=May ELSE IF>m=0...
by Tourless
Thu Jun 06, 2019 3:43 pm
Forum: Technical / Scripting
Topic: Date Format Problem
Replies: 5
Views: 3334

Date Format Problem

Hi Folks, I've searched around and read a fair deal of posts regarding date formats. I understand how they tie to the system settings but I'm not able to find a post that addresses my need to format a date with the month spelled out. I know in some of my excel code I can specify a date format as MMM...
by Tourless
Thu Apr 25, 2019 6:55 pm
Forum: Technical / Scripting
Topic: [SOLVED] Launching xlsm from MS encounters errors.
Replies: 7
Views: 4360

Re: [SOVLED] Launching xlsm from MS encounters errors.

[SOLUTION] All things being equal, I attempted to run excel as admin, tried RunProgram with RP_ADMIN=1, and still failed. Some interweb posts about the specific VBA error (429) proved useful as a quick Office repair seems to have taken care of the issue. My final solution was Dorians... Let>filepath...
by Tourless
Thu Apr 25, 2019 6:33 pm
Forum: Technical / Scripting
Topic: [SOLVED] Launching xlsm from MS encounters errors.
Replies: 7
Views: 4360

Re: Launching xlsm from GS encouters errors.

I'm not seeing a 'Run' command in the MS command reference. Can you elaborate?
UPDATE: Nevermind, I see what you did there. :P
by Tourless
Thu Apr 25, 2019 5:32 pm
Forum: Technical / Scripting
Topic: [SOLVED] Launching xlsm from MS encounters errors.
Replies: 7
Views: 4360

Re: Launching xlsm from GS encouters errors.

Nope. Same failure in the same place. To implement your method I removed the CreateReport call from the Workbook Open event, and made the call using XLRun function. It indeed ran but again errors out at the same line of code I use to create the Outlook object.
by Tourless
Thu Apr 25, 2019 5:24 pm
Forum: Technical / Scripting
Topic: [SOLVED] Launching xlsm from MS encounters errors.
Replies: 7
Views: 4360

Re: Launching xlsm from GS encouters errors.

Sorry, that was supposed to read 'MS encounter errors' for Macro Scheduler of course. Apparently it was too early for my proof reading eyes. Anyway based on your reply can I assume the problem has to do with the way I handle the code within my excel file? My Macro Scheduler script code is simply as ...
Sign up to our newsletter for free automation tips, tricks & discounts