Jump to content
Macro Express Forums

Macro Timing


Recommended Posts

I tested it with a sample set of data and it worked. Try breaking up you macro into small tasks (you can copy your macro and edit it) and test each one.

 

I wrote a macro to load from the clipboard, split the text and display the result. To test, I copied something to the clipboard and ran the macro.

Link to comment
Share on other sites

Well I don't know why, but for some reason I don't think the clipboard was liking the copy being done in the Phone directory program. So what I did was paste it into my text editor, re-copy it; then the macro ran through fine. I know it's an extra step but it seems to need it to recognize the data properly. I thought about what you said and tested it on some text that I typed in and it split the lines properly with that test, so it pointed to the phone program.

 

Well now for the real test, 1000's of records...we'll see!

 

Thank you again for your help and above all your patience with me.

 

Bob

Link to comment
Share on other sites

You may have a solution but a puzzle remains. (And your solution will not be optimum speed). It sounds like UltraEdit may be converting LFs to CRLFs or CRs to CRLFs. To make sure you could use a quick macro to write the data from the clipboard directly to a file. But, to examine its content you would want to use a Hex Editor and not UltraEdit (since UltraEdit may be altering the data).

 

Try this macro:

Variable Set String %Contents% from the clipboard contents
Variable Modify String: Save %Content% to "d:\test.txt"

Adjust the file path as needed.

 

Copy the data from the phone directory program to the clipboard. Run the macro. Use a hex editor (Google is your friend) to examine the content. Look for the CR (0D) and/or LF (0A) characters.

 

Isn't puzzle solving fun? You learn so much.

Link to comment
Share on other sites

Kevin,

 

Wouldn't writing a file for every single record slow things down? If each record I copy gets written into a file I would think that would take a while. I could be completely wrong but...

 

Learning is fun...but it's finally getting the result you've been working so hard at that makes it rewarding.

 

I am going to play around with this a little bit with what you suggested and check it out.

 

Thanks again!

 

Bob

Link to comment
Share on other sites

Wouldn't writing a file for every single record slow things down? If each record I copy gets written into a file I would think that would take a while.

I am not suggesting that you do this for your production macro.

 

Do not be afraid to write macros to explore and test your environment. If you write a macro that gets the information from the phone directory and writes it to a file you will be able to determine whether the confusion is because UltraEdit is converting LF's to CRLF's. Once you have that knowledge you should be able to discover why your macro is not working as expected.

Link to comment
Share on other sites

Kevin - What you and others have helped me with over the last week or so has given my company a breath of fresh air. We are part of a dying industry "New Home Info". With this help we can now convert and check info against our master "Permit" data base. Before time would make it almost impossable to complete.

 

Thanks again.

 

Bob

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...