AnalystRN Posted May 16, 2019 Report Share Posted May 16, 2019 From an excel .csv how can you send a variable, %T[3]%, which includes multiple rows under it. So: A AA AAA AAAA AAAAA I want to send all of them in the example above. But i seem to only be sending "A". How can i accomplish that? I am sending this variable into Meditech (Healthcare EHR program). Quote Link to comment Share on other sites More sharing options...
acantor Posted May 17, 2019 Report Share Posted May 17, 2019 Not sure I understand the issue, but the solution may be to output the first value, navigate to the next cell using this: Text Type (Simulate Keystrokes): <ARROW DOWN> ... and then output the next value. Quote Link to comment Share on other sites More sharing options...
AnalystRN Posted May 20, 2019 Author Report Share Posted May 20, 2019 Hopefully I can describe this better. So if i send the %T[3]% it would send the "A" from my .csv in the example above. How would I program the script to go down the list and send AA then AAA, etc from that .csv. The script pulls from the .csv file and inputs the data in the Meditech program. Currently the only way I have found to do it is to put the data directly into Macro Express. Quote Link to comment Share on other sites More sharing options...
acantor Posted May 20, 2019 Report Share Posted May 20, 2019 Text File Begin Process: C:\Users\Me\Documents\tmp.csv Text Type (Simulate Keystrokes): %Value%<ENTER> Text File End Process <TEXT FILE BEGIN PROCESS Filename="C:\\Users\\Me\\Documents\\tmp.csv" Start_Record="1" Process_All="TRUE" Records="1" Variable="%Value%"/> <TEXT TYPE Action="0" Text="%Value%<ENTER>"/> <TEXT FILE END PROCESS/> I have the values stored in a column in the file tmp.csv: A AA AAA etc. The macro outputs each value followed by a new line. Quote Link to comment Share on other sites More sharing options...
AnalystRN Posted June 10, 2019 Author Report Share Posted June 10, 2019 Since I have posted this....I figured out that for my purposes it is best not to use the .csv and to work out of a .txt file Quote Link to comment Share on other sites More sharing options...
Cory Posted July 28, 2019 Report Share Posted July 28, 2019 If it's only one column, then text is good. Use Text File Process. But nothing wrong with using CSV also. I would create an integer variable %Pointer% before the loop and each time it loops, increment it one. I despise the use of the stock variables as they were meant to make transition easier form ME3. Instead create an string array variable %Values%. each line that is read in, you send it to %values[%pointer%]%. IN this example yo would have 5 elements in the array numbered 1 to 5. Quote Link to comment Share on other sites More sharing options...
AnalystRN Posted August 1, 2019 Author Report Share Posted August 1, 2019 I'm almost there! Here is what I have so far: What this script is supposed to do is put data into the EHR from a .CSV file with about 5 column and 400+rows. If the entry exists it should hit ESC then ENTER and move on to the next, if it does not exist it would build the entry. It works for the most part but if an entry exists after Line 11 it skips down to Line 33 in the scripts and starts entering wrong data in wrong area. Any ideas on what I've messed up?? Quote Link to comment Share on other sites More sharing options...
Cory Posted November 4, 2019 Report Share Posted November 4, 2019 Are you still working on this? Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.