Recent content by deafmetal1

  1. deafmetal1

    Display Current DB File Size on a form

    I wanted to display the current Database file size on my Switchboard. I couldn't figure out how to get the code to work using a direct link to the open database (CurrentProject), so I added a field to an admin table that contains the db's filename. This same table includes the db version...
  2. deafmetal1

    Macro to open a web page

    Maybe it's me, but I noticed the FollowHyperlink method is SLOOOOOOOOOWWWWWWWWWWWWWWWWWW to open IE and go to the page requested. And it keeps maximizing the window, so I set the open new window value to True, and it solved that. But it's still SIGNIFICANTLY slower than using a macro, but I'm...
  3. deafmetal1

    Parsing To A Character Type

    Figured it out!!! Each line in the message ends with a carriage return and a line feed. Using a book I bought, Mastering VBA for MS Office, I figured out how to look for that, then the start of the line using the built in constant for carriageretun & line feed: vbCrLf Dim strPCR As String...
  4. deafmetal1

    Parsing To A Character Type

    I plugged that code in for the MSGID processing section... no joy. 'Move to MSGID line, determine Message Type, Originator, and Serial Number If InStr(strFileToParse, "MSGID/") <> 0 Then 'strFileToParse = Trim(Right(strFileToParse, Len(strFileToParse) - InStr(strFileToParse...
  5. deafmetal1

    Parsing To A Character Type

    Bob, Whoa! That worked!! I need to digest how, at that moment and point it does, but now I can see why you were getting frustrated that it was working on your end...lol I'm gonna play with it a bit and report back final findings and a clean email parsing version for the code repository once...
  6. deafmetal1

    Parsing To A Character Type

    It is my code doing that, same as in the attachment. Your code doesn't work with more than 2 lines of text in the message. i.e., If I put a full, complete message here like so: MSGID/TEST-MESSAGE/FROM-A-PIMP/023// P/-/1234/Test/Test/Test// REF/B/PHONECON/20SEP2006// T/1257PM/PACIFIC...
  7. deafmetal1

    Parsing To A Character Type

    Bob, Open up the MSG_Data table, look under the PNUM column for Test #4 data. You'll find the Value of ERROR_FORMAT (because intNthDelimitorNumber:=3 doesn't exist due to grabbing the wrong line of data). Further, if you look at the actual PLINE it parsed (P/023//), it grabbed the wrong line...
  8. deafmetal1

    Parsing To A Character Type

    If that's the case, then how do I have the Public Sub solve for x? In your intermediate code, you're providing the PLine data. Whereas my problem is finding and grabbing the PLine first, I'll worry about delimiting and getting specific fields from the line later. I need to get the PLine every...
  9. deafmetal1

    Parsing To A Character Type

    I have an example base DB attached. Included in the zipfile is also a pic of the VBA references, and 4 test emails. Reccomend creating an Outlook folder in your Inbox called MSG_PARSER or whatever. Not sure if you can just drag and drop the emails into it, though you should be able to...
  10. deafmetal1

    Parsing To A Character Type

    Bob, Great to see another Senior Enlisted! Maybe if I start from ground zero, it will help. I'm parsing messages out of Outlook. The parser stores the file to parse as an object, then I have a Public Sub that looks within each object for specific lines. Once it finds that specific line to...
  11. deafmetal1

    Parsing To A Character Type

    Bob, That's an EXCELLENT explanation, and I truly appreciate you taking the time to do so! I have fiddled with your code, it works great, I get the value after the 2nd Slash every time, but at the point that I'm using this code, I'm trying to get the parser to find the P/#/### line, not so...
  12. deafmetal1

    Parsing To A Character Type

    That would mean I'd have to understand it, and it confuses me, but am trying it now. Th eonly reason I didn't was because I didn't understand the syntax: ? fFindNthOccur(x, " ", 3) Will try and report back findings, wasn't trying to be an ignorant requester of help, my skill level of...
  13. deafmetal1

    Parsing To A Character Type

    Bob, Sorry to confuse you, I confuse myself some days!! Let me try this; In the emails/messages I parse, I look for a line that looks like this: P/-/#### Sometimes it will have a number in between, as such: P/#/#### There is more data in the lines, and they end with a //. I have it...
  14. deafmetal1

    Parsing To A Character Type

    Great thread, however I have a similar issue as follows: I am parsing as well using INSTR. The data string is formatted as follows: P/-/9 or P/1/9 I want it to grab the string irregardless of the middle character in between the delimiters (slashes) and yet take into account there must...
  15. deafmetal1

    VBA Query from a string returns adjacent cells

    Figured it out, definitely appreciate the point in the right direction dk. I ended up learning Index and Seek in the process, and those worked better for me since I needed to result in two separate strings. Those strings get used later in the parsing to be entered in a separate table. First...
Back
Top Bottom