{"id":13379,"date":"2013-11-12T06:02:40","date_gmt":"2013-11-11T21:02:40","guid":{"rendered":"http:\/\/www.smallake.kr\/?p=13379"},"modified":"2013-11-12T06:18:59","modified_gmt":"2013-11-11T21:18:59","slug":"foxpro%eb%a1%9c-%eb%a7%8c%eb%93%a0-%eb%a7%a4%eb%a7%a4%ec%b2%b4%ea%b2%b0%ec%8b%9c%ec%8a%a4%ed%85%9c","status":"publish","type":"post","link":"https:\/\/smallake.kr\/?p=13379","title":{"rendered":"FOXPro\ub85c \ub9cc\ub4e0 \ub9e4\ub9e4\uccb4\uacb0\uc2dc\uc2a4\ud15c"},"content":{"rendered":"<p>1.<br \/>\n\uc544\uc8fc \uc6b0\uc5f0\ud788 \ub208\uc5d0 \ub4e4\uc5b4\uc654\uc2b5\ub2c8\ub2e4. &#8220;Island ECN\uc758 \uc18c\uc2a4\ucf54\ub4dc\ub97c \uacf5\uac1c\ud588\ub2e4&#8221;\ub294 \uae00\uc774\uc5c8\uc2b5\ub2c8\ub2e4. \uc774\ucc9c\ub144\ub300 \ucd08\ubc18 \ubbf8\uad6d\uc5d0\uc11c \ub300\uccb4\uac70\ub798\uc18c(ATS) \ubc0f ECN\uc744 \uc124\ub9bd\ud558\ub294 \ubd90\uc774 \uc788\uc5c8\uc2b5\ub2c8\ub2e4. \uc774 \ub54c\ub97c \uc124\uba85\ud55c \uae00\uc785\ub2c8\ub2e4.<\/p>\n<blockquote><p>\uc804\uc790\uac70\ub798\uc2dc\uc2a4\ud15c\uc758 \uae09\uc18d\ud55c \uc131\uc7a5\ub0b4\uc5d0\uc11c ECN(Electronic Communications Network)\uc758 \uc131\uc7a5\uc740 \ucd5c\uadfc 2-3\ub144 \ub3d9\uc548 \ub354\uc6b1 \ub450\ub4dc\ub7ec\uc9c0\uace0 \uc788\ub2e4. \uc774\ub7f0 \uc644\uc804\ud788 \uc790\ub3d9\ud654\ub41c \uc2dc\uc2a4\ud15c\uc744 \ud1b5\ud574 \uae30\uad00\uc774\ub098 \ub2e4\ub978 \uc2dc\uc7a5\ucc38\uc5ec\uc790\ub4e4\uc740 \ub2e4\uc591\ud55c \ubc29\ubc95\uc73c\ub85c \uc804\uc790\uc801\uc73c\ub85c \uac70\ub798\ub97c \uccb4\uacb0\uc2dc\ud0ac \uc218 \uc788\ub2e4.<\/p>\n<p>\uc218\ub144\uac04 Nasdaq\uacfc \uad00\ub828\ud55c \uc2dc\uc7a5\uc758 \uc99d\uac00\ub97c \ubcf4\uc544\uc628 Day-trading \ud68c\uc0ac\ub4e4\uc740 ECNs \uc124\ub9bd\uc5d0 \ub6f0\uc5b4\ub4e4\uc5c8\ub2e4. Island ECN(\ub300\ubd80\ubd84 \uc628\ub77c\uc778 \uc911\uac1c\ud68c\uc0ac\uc778 Datek\uac00 \uc18c\uc720), Attain, Archipelago, \ubc0f NexTrade\ub4f1\uc774 \uadf8 \uc608\uc774\ub2e4. \uc608\uc678\uc5c6\uc774, \uc911\uac1c \ud68c\uc0ac(brokerage firms)\ub4e4\uacfc \ub2e4\ub978 \uc804\ud1b5\uc801\uc778 players\ub294 \uadf8\ub4e4 \uc790\uc2e0\uc758 \uadf8\ub8f9\uc744 \uc9c0\uc9c0\ud588\ub2e4. REDIBook\uc740 NYSE\uc758 specialist\uc778 Spear Leeds &amp; Kellogg\uc5d0 \uc758\ud574 \ubc1c\uc871\ub418\uc5c8\uc73c\uba70 Strike\ub294 Bear Stearns\uc5d0 \uc758\ud574 \uc2dc\uc791\ub418\uc5c8\ub2e4.<\/p><\/blockquote>\n<p>\uae00 \uc911\uc5d0 \ub4f1\uc7a5\ud55c Island ECN\ub97c \uc774\ud6c4 Instinet\uac00 2002\ub144 \uc778\uc218\ud558\uc600\uace0 \uc5ed\uc0ac\uc18d\uc73c\ub85c \uc0ac\ub77c\uc84c\uc2b5\ub2c8\ub2e4.<\/p>\n<p>2.<br \/>\n2002\ub144\uc73c\ub85c\ubd80\ud130 10\ub144\uc774 \ud750\ub978 2012\ub144 Island ECN\uc5d0 \ucc38\uc5ec\ud588\ub358 \ubd84\uc774 \uadf8 \ub54c \uac1c\ubc1c\ud558\uc600\ub358 \ub9e4\ub9e4\uccb4\uacb0\uc2dc\uc2a4\ud15c\uc758 \uc18c\uc2a4\ucf54\ub4dc\ub97c \uacf5\uac1c\ud558\uc600\uc2b5\ub2c8\ub2e4.<\/p>\n<p><a href=\"http:\/\/josh.com\/notes\/island-ecn-10th-birthday\/\" target=\"_blank\">Island ECN 10th Birthday Source Code Release!<\/a><\/p>\n<p>\ubb34\uc5c7\ubcf4\ub2e4 \ub180\ub77c\uc6b4 \uc810\uc740 \uac1c\ubc1c\uc5b8\uc5b4\uac00 FoxPro\uc774\ub77c\ub294 \uc810\uc785\ub2c8\ub2e4. \uc81c\uac00 \ucc98\uc74c\ubd80\ud130 \ub05d\uae4c\uc9c0 \ud504\ub85c\uadf8\ub7a8\uc744 \uac1c\ubc1c\ud558\uc5ec \uc0ac\uc6a9\ud558\uc600\ub358 \uc720\uc77c\ud55c \uc5b8\uc5b4\uac00 Foxpro\uc785\ub2c8\ub2e4. \uc800\ub294 \uadf8\uc800 \uc790\ub8cc\uad00\ub9ac \ud504\ub85c\uadf8\ub7a8\uc744 \uac1c\ubc1c\ud558\uc600\ub294\ub370 \uc5b4\ub5a4 \uc774\ub294 \ubc29\ub300\ud55c \ud06c\uae30\uc758 \ub9e4\ub9e4\uccb4\uacb0\uc2dc\uc2a4\ud15c\uc744 \uac1c\ubc1c\ud558\uc600\uc2b5\ub2c8\ub2e4.<\/p>\n<p>\uac1c\ubc1c\uc5b8\uc5b4\uac00 \uc5c5\ubb34\ub97c \uc81c\ud55c\ud558\ub294 \uac83\uc774 \uc544\ub2c8\ub77c \uac1c\ubc1c\uc790\uc758 \ub2a5\ub825\uc774 \uac1c\ubc1c\uc5b8\uc5b4\ub97c \uc81c\uc57d\ud55c\ub2e4\ub294 \uc0dd\uac01\uc774 \ub4ed\ub2c8\ub2e4. \ucc38\uace0\ub85c C++\ub85c \uac1c\ubc1c\ud55c \ub9e4\ub9e4\uccb4\uacb0\uc2dc\uc2a4\ud15c\uacfc \ube44\uad50\ud574\ubcf4\uc138\uc694.<\/p>\n<p><a href=\"https:\/\/code.google.com\/p\/rex-matching-engine\/\" target=\"_blank\">REX Matching Engine<\/a><\/p>\n<p>\uc774\ucc9c\ub144\ub300 \ucd08\ubc18 \ud55c\uad6d\ub3c4 ECN\uc774 \uc788\uc5c8\uc2b5\ub2c8\ub2e4. \ud55c\uad6dECN\uc785\ub2c8\ub2e4\ub9cc \ub9e4\ucd9c\ubd80\uc9c4\uc73c\ub85c \ubb38\uc744 \ub2eb\uc558\uc2b5\ub2c8\ub2e4. \ud639 \uc774 \ub54c\uc758 \uc18c\uc2a4\ub97c \uacf5\uac1c\ud560 \ubd84\uc774 \uc788\uc744\uae4c\uc694? Exture\ub098 Exture+\uc774\uc804\uc5d0 \uc0ac\uc6a9\ud558\uc600\ub358 \ucf54\uc2a4\ucf64 \uc18c\uc2a4\ub85c \uc54c\uace0 \uc788\uc2b5\ub2c8\ub2e4\ub9cc.<\/p>\n<p><span style=\"font-family: Georgia, 'Times New Roman', 'Bitstream Charter', Times, serif;\">\uc704\uc758 \uc0ac\uc774\ud2b8\uc5d0\uc11c \uc18c\uc2a4\ucf54\ub4dc\ub97c \ud655\uc778\ud558\uc2e4 \uc218 \uc788\uc9c0\ub9cc \uae30\ub85d\uc744 \uc704\ud574 \uc800\ub3c4 \uc62e\uaca8\ubd05\ub2c8\ub2e4.<\/span><\/p>\n<pre class=\"height-set:true width-set:true width:650 width-unit:0 lang:default decode:true\" title=\"Island ECN\">SET TALK OFF\r\nSET CURSOR OFF\r\nSET SAFETY OFF\r\nSET MEMOWIDTH TO 80\r\nCLEAR ALL\r\nCLOSE ALL\r\nCLEAR\r\nCLEAR MACRO\t\t&amp;&amp; Get rid of F keys typing commands\r\nSET HELP OFF\t&amp;&amp; Needed to clear out F1 key too\r\n\r\n=rand(-1)\r\n\r\n#define COREDEST \"FFFFFFFF0673\"\r\n\r\ngstoredflag = .F.\t\t&amp;&amp; Are there any messages buffered that could be flushed?\r\n\r\n#define VERSION \"2.40\"\r\n\r\nmalertfile = \"M:\\logs\\island2.err\"\r\nmholdofffile = \"M:\\island2\\holdoff.txt\"\r\n\r\nblanknbuffer=\"R\"+replicate( \" \" , 200 )                 &amp;&amp; get BRIGADEN message here\r\n\r\n#define CORELINELEN 124\r\n#define COREMESSAGELEN 122\r\n\r\n#define READPORT \"067F\"\r\n\r\nload int99\r\n\r\ndefine window title    from 0,0   to  0,scols()-1  COLOR \"W\/B\" NONE\r\ndefine window output   from 1,0   to 10,scols()-1 NONE COLOR \"W+\/N\"\r\ndefine window ticker   from 12,0   to srows()-1,scols()-1 NONE\r\ndefine window status   from 11,0   to 11,scols()-1 COLOR \"W+\/R\" NONE\r\n\r\ndo title \r\ndo initstatus\r\n\r\nactivate window title\r\nactivate window status\r\n\r\nactivate window output\r\nactivate window ticker\r\n\r\ns = fopen( \"ISLAND2.TXT\" )\r\n\r\nif s &lt;= 0 \r\n\twait window \"COULD NOT FIND ISLAND2.TXT IN CURRENT DIR. RUN RESET.\"\r\n\tquit\r\nendif\r\n\r\nx = fgets( s )\r\n\r\nif \"ISLAND2\" # x\r\n\twait window \"ACCOUNT IN ISLAND2.TXT DOES NOT MATCH ACCOUNT ENV VAR. RUN RESET.\"\r\n\t=fclose( s )\r\n\tquit\r\nendif\r\n\r\ntcount = 0 \t\t&amp;&amp; For counting random stuff\r\n\r\ntseq = val( fgets( s ) )\t\t\t\t&amp;&amp; Next order number\r\ntmatch = val( fgets( s ) )\t\t\t\t&amp;&amp; Next match number\r\ntnextdead = val( fgets( s ) )\t\t\t&amp;&amp; Next dead order (zero=none)\r\n=fclose( s )\r\n\r\nselect select(1)\r\nuse events\r\nset order to WHEN\r\n\r\ntnow = 0\r\n\r\nttoolate = 0 \t\t\t&amp;&amp; Count the too late to cancel events\r\n\r\ngaccept    = .F.\t\t&amp;&amp; Let any orders in? Set by SOD, cleared by EOD\r\ngactaccept = .F.\t\t&amp;&amp; Let ACT orders in? Set by SOD, cleared by EOA\r\n\r\ngeom\t   = .F.\t\t&amp;&amp; Have we gotten EOM yet?\r\n\r\ngprinting  = .F. \t\t&amp;&amp; Print incoming messages?\r\n\r\ngo top\r\n\r\nif eof(\"EVENTS\")\r\n\r\n\ttnext = 99999.999\r\n\r\nelse\r\n\r\n\ttnext = WHEN\t\t\t&amp;&amp; Time of next event\r\n\r\nendif\r\n\r\nselect 0\r\nuse sources\r\nset order to SOURCE\r\n\r\nselect select(1)\r\nuse island\r\n\r\ngsx = alltrim( str( date() - {2\/6\/1996} ) )\r\n\r\ngsession = left( \"0000000000\" , 9-len( gsx ) ) + gsx + \"F\"\r\n\r\ns=\"N\"+gsession+\"5050\"\t\t\t&amp;&amp; Open the islandfile for writing Mold on port 5050\r\ncall int99 with s\r\n\r\nif s # \"n\" &amp;&amp; Valid open file?\r\n\r\n\tdo alert with \"InitMold filed with reason &gt;\"+s\r\n\r\n\tdo case\r\n\r\n\t\tcase s = \"i\"\r\n\r\n\t\t\tsm =\"Error opening files in deney-write mode\"\r\n\r\n\t\tcase s = \"j\"\r\n\r\n\t\t\tsm = \"a file had a partial line fragment\"\r\n\r\n\t\tcase s = \"k\"\r\n\r\n\t\t\tsm = \"not all trailing files are empty\"\r\n\r\n\t\tcase s = \"l\"\r\n\r\n\t\t\tsm = \"all files full\"\r\n\r\n\t\totherwise\r\n\r\n\t\t\tsm = \"Unknown error\"\r\n\r\n\tendcase\r\n\r\n\tdo alert with sm\r\n\r\n\twait window \"Error on ISLAND.OUT or ISLAND2.OUT OPEN:\"+s\r\n\r\n\tquit\r\n\r\nendif\r\n\r\nselect island\r\n\r\ntecount  = 0\t\t\t\t\t \t&amp;&amp; Assume worst case, just to make sure ecount is high enough\r\ntxcount  = 0\t\t\t\t\t\t&amp;&amp; Cancels\r\n\r\nx = \"L\"+READPORT+\" \"\t\t&amp;&amp; Read Island2 requests\r\ncall int99 with x\r\nif x # \"l\"\r\n\tdo alert with \"Could not open Command listen!\"\r\nendif\r\n\r\ngstatdelay = 0.25\r\ndo showstatus\r\ngnextstats = seconds() + gstatdelay\r\n\r\ngmolddelay = 1\t\t\t\t\t\t\t&amp;&amp; Time between mold heartbeats\r\ngmoldheart = seconds() + gmolddelay\t\t&amp;&amp; Time to send a MOLD heartbeat by doing a FLUSH\r\n\r\ngmessages = 0\t\t\t&amp;&amp; Number of messages written to the stream\r\ngpackets = 0\t\t\t&amp;&amp; Number of packets writtento the stream\r\n\r\nmdone = .F.\r\n\r\ndo while !mdone\r\n\r\n\ttnow = seconds()\r\n\r\n\tdo while tnow &gt;= tnext\r\n\r\n\t\tif !EVENTS.PROCESSED\r\n\r\n\t\t\tdo swrite with \"G\" , EVENTS.CODE\r\n\r\n\t\t\tselect EVENTS\t\t\r\n\t\t\treplace PROCESSED with .T.\r\n\t\t\tselect ISLAND\r\n\r\n\t\telse\r\n\r\n\t\t\t? time()+\" Event bypassed:\"+ EVENTS.CODE\r\n\r\n\t\tendif\r\n\r\n\t\tdo seteventflags with EVENTS.CODE\r\n\r\n\t\tskip 1 in EVENTS\r\n\r\n\t\tif eof(\"EVENTS\")\r\n\r\n\t\t\ttnext = 99999.999\r\n\r\n\t\telse\r\n\r\n\t\t\ttnext = EVENTS.WHEN\r\n\r\n\t\tendif\r\n\r\n\tenddo\r\n\r\n\tnbuffer = blanknbuffer\r\n\r\n\tcall int99 with nbuffer\r\n\r\n\tif nbuffer = \"r\"\r\n\r\n\t\ttlenstr = substr( nbuffer , 2 , 5 )\r\n\r\n\t\ttlen = val( tlenstr )\r\n\r\n\t\ttmessage = substr( nbuffer , 43 , tlen )\r\n\r\n\t\tif gprinting\r\n\t\t\t? time()+\" &gt;\"+tmessage+\"&lt;\"\r\n\t\tendif\r\n\r\n\t\tif tmessage = \"P\"\t&amp;&amp; PING REQUEST\r\n\r\n\t\t\ttsource = substr( nbuffer ,11 , 8)\r\n\r\n\t\t\tdo pingreply with tsource , tmessage\r\n\r\n\t\telse\r\n\r\n\t\t\tdo processtcpip with tmessage\r\n\r\n\t\tendif\r\n\r\n\telse &amp;&amp; No pending commands...\r\n\r\n\t\tif gstoredflag \r\n\r\n\t\t\tdo flush\r\n\r\n\t\t\tgstoredflag = .F.\r\n\r\n\t\t\tgmoldheart = seconds() + gmolddelay\r\n\r\n\t\t\tgpackets = gpackets + 1\r\n\r\n\t\telse\r\n\r\n\t\t\tif gmoldheart &lt; seconds()\r\n\r\n\t\t\t\tdo flush\r\n\r\n\t\t\t\tgmoldheart = seconds() + gmolddelay\r\n\r\n\t\t\tendif\r\n\r\n\t\tendif\t\r\n\r\n\tendif\r\n\r\n\tif gnextstats &lt;= seconds()\r\n\r\n\t\tdo showstatus\r\n\t\tgnextstats = seconds() + gstatdelay\t\r\n\r\n\tendif\r\n\r\n\tlastkey=inkey()\r\n\r\n\tif lastkey # 0\r\n\r\n\t\tactivate window output\r\n\r\n\t\tdo case\r\n\t\t\tcase lastkey = asc(\"~\")\r\n\t\t\t\t? time()+\" Quitting...\"\r\n\t\t\t\tmdone = .T.\r\n\r\n\t\t\tcase lastkey = asc(\"@\")\r\n\t\t\t\t? time()+\" Copying to island2.dbf\"\r\n\t\t\t\tset order to \r\n\t\t\t\tcopy to m:\\island2\\island2\r\n\t\t\t\t?? \"Done\"\r\n\r\n\t\t\tcase lastkey = asc(\"#\")\r\n\t\t\t\t? time()+\" Suspending...\"\r\n\t\t\t\tsuspend\r\n\r\n\t\t\tcase lastkey = asc(\"!\")\r\n\r\n\t\t\t\t? time()+\" ACCEPT=\"+iif(gaccept,\"T\",\"F\")+\" ACT=\"+ iif(gactaccept,\"T\",\"F\") + \" EOM=\"+iif(geom,\"T\",\"F\")+\" NEXT=\"+str(tnext,9,3)+ \" TOO-LATE=\"+str(ttoolate,6,0)+\" COUNT=\"+str(tcount,9,0)\r\n\r\n\t\t\t\ts = \"T\"+space(60)\r\n\t\t\t\tcall int99 with s\r\n\r\n\t\t\t\tif s = \"t\"\r\n\r\n\t\t\t\t\ttbuffered = val( substr(s,26,5) )\r\n\r\n\t\t\t\t\t? \"MOLD INFO: SESSION=\"+substr(s,2,10)+\" SEQ=\"+substr(s,12,10)+\" SOCKET=\"+substr(s,22,4)+\" BUFFERED=\"+str(tbuffered,5,0)\r\n\r\n\t\t\t\telse\r\n\r\n\t\t\t\t\t? \"Could not get mold info!\"\r\n\r\n\t\t\t\t\ttbuffered = 0\r\n\r\n\t\t\t\tendif\r\n\r\n\t\t\t\tif gpackets &gt; 0 \r\n\r\n\t\t\t\t\t? \"MESSAGES:\"+str(gmessages-tbuffered,12,0)+\" PACKETS:\"+str(gpackets,12,0)+\" (\"+str( (gmessages-tbuffered)\/ gpackets , 5 , 3 )+\")\"\r\n\r\n\t\t\t\t\tgmessages = tbuffered\r\n\t\t\t\t\tgpackets  =0\r\n\r\n\t\t\t\tendif\r\n\r\n\t\t\tcase lastkey = asc(\"%\")\r\n\t\t\t\t? time()+\" Shutdown attempt...\"\r\n\t\t\t\tdo shutdown\r\n\r\n\t\t\tcase lastkey = asc(\"(\")\r\n\t\t\t\t? time()+\" toggled gaccept\"\r\n\t\t\t\tgaccept = !gaccept\r\n\r\n\t\t\tcase lastkey = asc(\"?\")\r\n\t\t\t\t? \"@-Copy to island2.DBF ~-Quit !-Status #-Suspend %-ShutDown $-Print incoming\"\r\n\r\n\t\t\tcase lastkey = asc(\"$\")\r\n\r\n\t\t\t\tif gprinting\r\n\r\n\t\t\t\t\t? time()+\" Printing off\"\r\n\t\t\t\t\tgprinting = .F.\r\n\t\t\t\telse\t\t\t\t\t\r\n\r\n\t\t\t\t\t? time()+\" Printing on\"\r\n\t\t\t\t\tgprinting = .T.\r\n\r\n\t\t\t\tendif\r\n\r\n\t\tendcase\r\n\r\n\t\tactivate window ticker\r\n\r\n\tendif\r\n\r\nenddo  &amp;&amp; Main Loop\r\n\r\nactivate window output\r\n\r\n&amp;&amp; Final flush to mak sure everything is sent\r\n\r\ndo flush\r\n\r\n&amp;&amp; Close file\r\n\r\ns = \"C\"\r\ncall int99 with s\r\n\r\nx = \"H\"+READPORT\r\ncall int99 with x\r\nif x # \"h\"\r\n\tdo alert with \"Could not close PingPort!\"\r\nendif\r\n\r\nuse\t\t\t&amp;&amp; Unuse Island\r\n\r\n&amp;&amp; Create fresh waypoint file\r\n\r\nf = fcreate(\"ISLAND2.TXT\")\r\n\r\nif f&lt;=0 \r\n\t? \"Could not create ISLAND.TXT!\"\r\n\tsuspend\r\nendif\r\n\r\n=fputs( f , \"ISLAND2\" )\t\t\t\t\t&amp;&amp; ROLE\r\n\r\n=fputs( f , str( tseq , 9 , 0   )  )\t&amp;&amp; Order number\r\n=fputs( f , str( tmatch , 9 , 0 )  )\t&amp;&amp; Match number\r\n=fputs( f , str( tnextdead , 9 , 0 ) ) \t&amp;&amp; Next dead order pointer\r\n=fclose(f)\r\n\r\nquit\r\n\r\nprocedure title\r\n\tactivate window title SAME\r\n\tclear\r\n\t@ 0,0 SAY \" Island2  \ufffd Version \"+VERSION+\" (c)1996 Joshua Levine \ufffd Press [?] for help\"\r\n\tactivate window ticker SAME\r\nreturn \r\n\r\nproc werror\r\n\tparam wcode\r\n\r\n\tdo case\r\n\r\n\t\tcase wcode = \"w\"\r\n\r\n\t\t\treturn \"Error on file write\"\r\n\r\n\t\tcase wcode = \"s\"\r\n\r\n\t\t\treturn \"Error on nework send\"\r\n\r\n\t\tcase wcode = \"c\"\r\n\r\n\t\t\treturn \"Invalid message length\"\r\n\r\n\t\tcase wcode = \"d\"\r\n\r\n\t\t\treturn \"all files full\"\r\n\r\n\tendcase\r\n\r\nreturn \"Unknown error\"\r\n\r\n**** write actualy writes a string the the file, steam, and screen\r\n\r\nproc write\r\n\tparameter wstring\r\n\r\n\twl = len( wstring )\r\n\r\n\tws=\"W\"+chr(wl)+wstring\r\n\r\n \tcall int99 with ws\r\n\r\n \tgmessages = gmessages + 1\r\n\r\n\tif ws = 'b'\r\n\r\n\t\tgstoredflag = .T.\r\n\r\n\telse\r\n\r\n\t\tif ws = \"f\"\r\n\r\n\t\t\tgpackets = gpackets + 1\r\n\r\n\t\t\tgstoredflag = .F.\r\n\r\n\t\telse\r\n\r\n\t\t\tactivate window output\t\t\r\n\r\n\t\t\t? time() +\" !!!! ERROR ON WRITE!!!!!!\"\r\n\r\n\t\t\t? ws\r\n\r\n\t\t\tdo alert with \"Erorr on write:\"+werror(ws)\r\n\r\n\t\t\tactivate window ticker\r\n\r\n\t\t\tsuspend\r\n\r\n\t\tendif\r\n\r\n\tendif\r\n\r\nreturn\r\n\r\n*** Write a message\r\n\r\n**** ACTIONS:\r\n**** A - Accept \tthe order was accepted into Island\r\n**** B - Booked\t\tthis order hit the book\r\n**** E - Execute\tthe order was executed for this many shares at this price\r\n**** X - Cancel\t\tthis many shares were canceled\r\n**** C - Break\t\tthis order was executed, now broken\r\n**** G - Control    stock is the control type\r\n**** R - Report     trade done away but will report\/clear through Island\r\n\r\n**** ON Cancel CONTRA = Reason for cancel\r\n\r\n***** MINDICATE = on accept always \"D\" (legacy)\r\n*****  \t\t\ton execute \"A\"= added liquidity, \"R\"=Removed liquidity\r\n*****           on report \"Y\" trade report, \"N\" don't report, \"S\" step-out\r\n\r\n****** mmatch = on accept or book is MINIMUM shares, in execution is match number\r\n******\t\t\tnot defined on cancels, but 0 for now\r\n\r\nproc mwrite\r\n\r\n\tparameter maction,mseq,mshares,mprice,mcontra,mindicate,mmatch,mlocate\r\n\r\n\tmwhen = str( tnow , 9 , 3)\r\n\r\n\tw = left( mwhen , 5 ) + \",\" +maction+\",\"+str(mseq,9,0)+\",\"+PORT+\",\"+USER+\",\"+TOKEN+\",\"+BUY_SELL+\",\"+str(mshares,9,0)+\",\"+str(mmatch,9,0)+\",\"+STOCK+\",\"+str(mprice,11,4)+\",\" +str(mlocate,8,0)+ \",    0,\"+SHORT+\",\"+MMID+\",\"+PA+\",\"+mcontra+\",\"+mindicate+\",\"+DISPLAY+\",\"+right(mwhen,3)+\",\"+CLEARING+\",D\"\r\n\r\n\tdo write with w\r\n\r\nreturn\r\n\r\n****** Swrite writes a status message that doesnot concern an order, Like G-Good morning\r\n\r\nproc swrite\r\n\r\n\tparam maction , mcode\r\n\r\n\tmwhen = str( tnow , 9 , 3)\r\n\r\n\txcode = left( padr( mcode , 3) , 3 )\r\n\r\n\tw = left( mwhen , 5 ) +\",\"+maction+\",\"+\"        0\"+\",      ,    ,          , ,        0,        0,*\"+xcode+\"  ,     0.0000,00000000,    0, ,    , ,    , , ,\"+right( mwhen , 3 )+\", , \"\r\n\r\n\tdo write with w\r\n\r\nreturn\r\n\r\n****** Enter order adds the audit, tries for a match, and if it don't work, books it.\r\n****** Enter order assumes ostock and obuy_sell are the right length.\r\n****** Also assumes that buy_sell has aready been checked to be B or S. \r\n****** Also assumes that the token is no already used\r\n\r\nproc enter2order\r\n\r\n\tparameter oport,ouser,otoken,obuy_sell,oshares,ostock,oprice,otif,oshort,ommid,opa,odisplay,omin,oclearing,oflags\r\n\r\n\tif odisplay = \"P\"\r\n\r\n\t\tobasefirm = ouser\r\n\r\n\telse \r\n\r\n\t\tobasefirm = \"####\"\r\n\r\n\tendif\r\n\r\n\t&amp;&amp; Get the working record\r\n\r\n\tif tnextdead &gt; 0 \r\n\r\n\t\ttlocate = tnextdead\r\n\t\tgoto tnextdead\r\n\t\ttnextdead = SEQ\r\n\r\n\telse\r\n\r\n\t\tinsert into ISLAND (LEAVES) values (0)\t\t&amp;&amp; Keep it out of the indexes for now\r\n\t\ttlocate = recno()\r\n\r\n\tendif\r\n\r\n\ttseq = tseq + 1\r\n\r\n\tawhen = str( tnow , 9 , 3)\r\n\r\n\toleaves = oshares\r\n\r\n\tofilled = 0\r\n\r\n\taflag = .f.\t\t&amp;&amp; have we written the \"A\" message yet?\r\n\r\n\tif obuy_sell = \"B\"\t\t&amp;&amp; Buy order...\r\n\r\n\t\tset order to SSEEK \r\n\r\n\t\tdo case\r\n\r\n\t\t\tcase omin &gt; 1\t\t&amp;&amp; Minimum quantity specified?\r\n\r\n\t\t\t\t*** if the min is bigger than the size, set it to the size\r\n\r\n\t\t\t\tif omin &gt; oshares\r\n\r\n\t\t\t\t\tmmin = oshares\r\n\r\n\t\t\t\telse\r\n\r\n\t\t\t\t\tmmin = omin\r\n\r\n\t\t\t\tendif\r\n\r\n\t\t\t\t*** First prescan to see if we have enough size to fill it\r\n\r\n\t\t\t\tif seek( ostock )\r\n\r\n\t\t\t\t\tscan while mmin &gt; 0 .and. ostock = STOCK .and. BUY_SELL = \"S\" .and. oprice &gt;= PRICE\r\n\r\n\t\t\t\t\t\tmmin = mmin - LEAVES\r\n\r\n\t\t\t\t\tendscan\r\n\r\n\t\t\t\tendif\r\n\r\n\t\t\t\tif mmin &lt;= 0 \r\n\r\n\t\t\t\t\t*** There were at least enough to fill the minimum quantity\r\n\r\n\t\t\t\t\tmmax = oshares\r\n\r\n\t\t\t\telse\r\n\r\n\t\t\t\t\t*** Not enough to fill the min, so fill none\r\n\r\n\t\t\t\t\tmmax = 0\r\n\r\n\t\t\t\tendif\r\n\r\n\t\t\tcase odisplay = \"R\" .or. odisplay = \"P\"\t&amp;&amp; Is this a round-lot only order?\r\n\r\n\t\t\t\tmmax = 0\t\r\n\r\n\t\t\t\t*** Prescan to find the number of a shares available\r\n\r\n\t\t\t\tif seek( ostock )\r\n\r\n\t\t\t\t\tscan while mmax &lt;= oshares .and. ostock = STOCK .and. BUY_SELL = \"S\" .and. oprice &gt;= PRICE .and. obasefirm # MMID\r\n\r\n\t\t\t\t\t\tmmax = mmax + LEAVES\r\n\r\n\t\t\t\t\tendscan\r\n\r\n\t\t\t\tendif\r\n\r\n\t\t\t\tif mmax &gt;= oshares\r\n\r\n\t\t\t\t\t*** Max out with the number of shares specified\r\n\r\n\t\t\t\t\tmmax = oshares\r\n\r\n\t\t\t\tendif\r\n\r\n\t\t\t\t*** Round down to nearest round lot wihtout using floating point\r\n\r\n\t\t\t\tmmax = val( substr( str( mmax , 6, 0 ) , 1 ,4 ) + \"00\" )\r\n\r\n\t\t\totherwise\r\n\r\n\t\t\t\tmmax = oshares\r\n\r\n\t\tendcase\r\n\r\n\t\tdo while mmax &gt; 0 .and. seek( ostock  ) .and. oprice &gt;= PRICE\r\n\r\n\t\t\tif !aflag\r\n\r\n\t\t\t\tw = left( awhen , 5 ) +\",A,\" +str(tseq,9,0) +\",\" +oport+\",\" +ouser +\",\" +otoken +\",\" +obuy_sell +\",   \" +str(oshares,6,0) +\",   \" +str(omin,6,0) +\",\" +ostock +\",\" +str(oprice,11,4) +\",\" +str(tlocate,8,0) +\",\" +str(otif,5,0) +\",\" +oshort +\",\" +ommid +\",\" +opa+\",\"+oflags+\", ,\" +odisplay +\",\" +right(awhen,3) +\",\" +oclearing+\",D\" \r\n\r\n\t\t\t\tdo write with w\r\n\r\n\t\t\t\taflag = .T.\r\n\r\n\t\t\tendif\r\n\r\n\t\t\ttecount = tecount + 1\r\n\r\n\t\t\teshares = min( LEAVES , mmax )\r\n\r\n\t\t\toleaves = oleaves - eshares\r\n\r\n\t\t\tmmax = mmax - eshares\r\n\r\n\t\t\tofilled = ofilled + eshares\r\n\r\n\t\t\ttmatch = tmatch + 1\r\n\r\n\t\t\tw = left( awhen , 5 ) +\",E,\" +str( SEQ ,9,0) +\",\" +PORT +\",\" +USER +\",\" +TOKEN +\",\" +BUY_SELL +\",   \" +str(eshares,6,0) +\",\" +str(tmatch,9,0) +\",\" +ostock +\",\" +str(PRICE,11,4) +\",\" +str( recno() ,8,0)+ \",    0,\" +SHORT +\",\" +MMID +\",\" +PA+\",\" +ommid+\",A,\" +DISPLAY +\",\" +right(awhen,3) +\",\" +CLEARING+\",D\"\r\n\r\n\t\t\tdo write with w\r\n\r\n\t\t\tw = left( awhen , 5 ) +\",E,\" +str(tseq,9,0)    +\",\" +oport+\",\" +ouser +\",\" +otoken +\",\" +obuy_sell +\",   \" +str(eshares,6,0) +\",\" +str(tmatch,9,0) +\",\" +ostock +\",\" +str(PRICE,11,4) +\",\" +str(tlocate,8,0)+\",    0,\" +oshort +\",\" +ommid +\",\" +opa+\",\"+MMID+\",R,\" +odisplay +\",\" +right(awhen,3) +\",\" +oclearing+\",D\"\r\n\r\n\t\t\tdo write with w\r\n\r\n\t\t\tdleaves = LEAVES - eshares\r\n\r\n\t\t\tif dleaves &lt;= 0 \t\t&amp;&amp; Dead record?\r\n\r\n\t\t\t\treplace LEAVES with 0 , SEQ with tnextdead\r\n\t\t\t\ttnextdead \t= recno()\r\n\r\n\t\t\telse\r\n\r\n\t\t\t\treplace LEAVES with dleaves , FILLED with FILLED + eshares \r\n\r\n\t\t\tendif\r\n\r\n\t\tenddo\r\n\r\n\telse &amp;&amp; sell order..\r\n\r\n\t\tset order to BSEEK\r\n\r\n\t\tdo case\r\n\r\n\t\t\tcase omin &gt; 1\t\t&amp;&amp; Minimum quantity specified?\r\n\r\n\t\t\t\t*** if the min is bigger than the size, set it to the size\r\n\r\n\t\t\t\tif omin &gt; oshares\r\n\r\n\t\t\t\t\tmmin = oshares\r\n\r\n\t\t\t\telse\r\n\r\n\t\t\t\t\tmmin = omin\r\n\r\n\t\t\t\tendif\r\n\r\n\t\t\t\t*** First prescan to see if we have enough size to fill it\r\n\r\n\t\t\t\tif seek( ostock )\r\n\r\n\t\t\t\t\tscan while mmin &gt; 0 .and. ostock = STOCK .and. BUY_SELL = \"B\" .and. oprice &lt;= PRICE\r\n\r\n\t\t\t\t\t\tmmin = mmin - LEAVES\r\n\r\n\t\t\t\t\tendscan\r\n\r\n\t\t\t\tendif\r\n\r\n\t\t\t\tif mmin &lt;= 0 \r\n\r\n\t\t\t\t\tmmax = oshares\r\n\r\n\t\t\t\telse \r\n\r\n\t\t\t\t\tmmax = 0\r\n\r\n\t\t\t\tendif\r\n\r\n\t\t\tcase odisplay = \"R\" .or. odisplay = \"P\" &amp;&amp; Is this a round-lot only order?\r\n\r\n\t\t\t\tmmax = 0\t\r\n\r\n\t\t\t\t*** Prescan to find the number of a shares available\r\n\r\n\t\t\t\tif seek( ostock )\r\n\r\n\t\t\t\t\tscan while mmax &lt;= oshares .and. ostock = STOCK .and. BUY_SELL = \"B\" .and. oprice &lt;= PRICE .and. obasefirm # MMID\r\n\r\n\t\t\t\t\t\tmmax = mmax + LEAVES\r\n\r\n\t\t\t\t\tendscan\r\n\r\n\t\t\t\tendif\r\n\r\n\t\t\t\tif mmax &gt;= oshares\r\n\r\n\t\t\t\t\tmmax = oshares\r\n\r\n\t\t\t\tendif\r\n\r\n\t\t\t\t*** Round down to nearest round lot wihtout using floating point\r\n\r\n\t\t\t\tmmax = val( substr( str( mmax , 6, 0 ) , 1 ,4 ) + \"00\" )\r\n\r\n\t\t\totherwise\r\n\r\n\t\t\t\tmmax = oshares\r\n\r\n\t\tendcase\r\n\r\n\t\tdo while mmax &gt; 0 .and. seek( ostock  ) .and. oprice &lt;= PRICE \r\n\r\n\t\t\tif !aflag\r\n\r\n\t\t\t\tw = left( awhen , 5 ) +\",A,\" +str(tseq,9,0) +\",\" +oport+\",\" +ouser +\",\" +otoken +\",\" +obuy_sell +\",   \" +str(oshares,6,0) +\",   \" +str(omin,6,0) +\",\" +ostock +\",\" +str(oprice,11,4) +\",\" +str(tlocate,8,0) +\",\"+str(otif,5,0) +\",\" +oshort +\",\" +ommid +\",\" +opa+\",\"+oflags+\", ,\" +odisplay +\",\" +right(awhen,3) +\",\" +oclearing+\",D\" \r\n\r\n\t\t\t\tdo write with w\r\n\r\n\t\t\t\taflag = .T.\r\n\r\n\t\t\tendif\r\n\r\n\t\t\ttecount = tecount + 1\r\n\r\n\t\t\teshares = min( LEAVES , mmax )\r\n\r\n\t\t\toleaves = oleaves - eshares\r\n\r\n\t\t\tmmax = mmax - eshares\r\n\r\n\t\t\tofilled = ofilled + eshares\r\n\r\n\t\t\ttmatch = tmatch + 1\r\n\r\n\t\t\tw = left( awhen , 5 ) +\",E,\" +str( SEQ ,9,0) +\",\" +PORT +\",\" +USER +\",\" +TOKEN +\",\" +BUY_SELL +\",   \" +str(eshares,6,0) +\",\" +str(tmatch,9,0) +\",\" +ostock +\",\" +str(PRICE,11,4) +\",\" +str( recno() ,8,0) +\",    0,\" +SHORT +\",\" +MMID +\",\" +PA+\",\" +ommid+\",A,\" +DISPLAY +\",\" +right(awhen,3) +\",\" +CLEARING+\",D\"\r\n\r\n\t\t\tdo write with w\r\n\r\n\t\t\tw = left( awhen , 5 ) +\",E,\" +str(tseq,9,0)    +\",\" +oport+\",\" +ouser +\",\" +otoken +\",\" +obuy_sell +\",   \" +str(eshares,6,0) +\",\" +str(tmatch,9,0) +\",\" +ostock +\",\" +str(PRICE,11,4) +\",\" +str(tlocate,8,0) +\",    0,\" +oshort +\",\" +ommid +\",\" +opa+\",\"+MMID+\",R,\" +odisplay +\",\" +right(awhen,3) +\",\" +oclearing+\",D\"\r\n\r\n\t\t\tdo write with w\r\n\r\n\t\t\tdleaves = LEAVES - eshares\r\n\r\n\t\t\tif dleaves &lt;= 0 \t\t&amp;&amp; Dead record?\r\n\r\n\t\t\t\treplace LEAVES with 0 , SEQ with tnextdead\r\n\t\t\t\ttnextdead \t= recno()\r\n\r\n\t\t\telse\r\n\r\n\t\t\t\treplace LEAVES with dleaves , FILLED with FILLED + eshares \r\n\r\n\t\t\tendif\r\n\r\n\t\tenddo\r\n\r\n\tendif\r\n\r\n\tif oleaves &gt; 0\t\t\t&amp;&amp; any non-executed shares left?\r\n\r\n\t\tif otif = 0\t\t\t\t&amp;&amp; Fill or kill, so cancel leaves\r\n\r\n\t\t\tif !aflag\t\t&amp;&amp; did we not make an A message yet?\r\n\r\n\t\t\t\tw = left( awhen , 5 ) +\",A,\" +str(tseq,9,0) +\",\" +oport+\",\" +ouser +\",\" +otoken +\",\" +obuy_sell +\",   \" +str(oshares,6,0) +\",   \" +str(omin,6,0) +\",\" +ostock +\",\" +str(oprice,11,4) +\",\" +str(tlocate,8,0)+ \",\" +str(otif,5,0) +\",\" +oshort +\",\" +ommid +\",\" +opa+\",\"+oflags+\", ,\" +odisplay +\",\" +right(awhen,3) +\",\" +oclearing+\",D\"\r\n\t\t\t\tdo write with w\t\t\r\n\r\n\t\t\tendif\r\n\r\n\t\t\tw = left( awhen , 5 ) +\",X,\" +str(tseq,9,0)    +\",\" +oport+\",\" +ouser +\",\" +otoken +\",\" +obuy_sell +\",   \" +str(oleaves,6,0) +\",        0,\" +ostock +\",\" +str(oprice,11,4) +\",\" +str(tlocate,8,0)+ \",    0,\" +oshort +\",\" +ommid +\",\" +opa+\",#IOC, ,\" +odisplay +\",\" +right(awhen,3) +\",\" +oclearing+\",D\"\r\n\t\t\tdo write with w\t\t\r\n\r\n\t\t\toleaves = 0\r\n\r\n\t\telse\r\n\r\n\t\t\tif !aflag\t\t&amp;&amp; did we not make an A message yet?\r\n\r\n\t\t\t\tw = left( awhen , 5 ) +\",A,\" +str(tseq,9,0) +\",\" +oport+\",\" +ouser +\",\" +otoken +\",\" +obuy_sell +\",   \" +str(oshares,6,0) +\",   \" +str(omin,6,0) +\",\" +ostock +\",\" +str(oprice,11,4) +\",\" +str(tlocate,8,0) +\",\" +str(otif,5,0) +\",\" +oshort +\",\" +ommid +\",\" +opa+\",\"+oflags+\",B,\" +odisplay +\",\" +right(awhen,3) +\",\" +oclearing+\",D\" \r\n\r\n\t\t\telse\r\n\r\n\t\t\t\tw = left( awhen , 5 ) +\",B,\" +str(tseq,9,0)    +\",\" +oport+\",\" +ouser +\",\" +otoken +\",\" +obuy_sell +\",   \" +str(oleaves,6,0) +\",        0,\" +ostock +\",\" +str(oprice,11,4) +\",\" +str(tlocate,8,0) +\",\" +str(otif,5,0) +\",\" +oshort +\",\" +ommid +\",\" +opa+\",    , ,\" +odisplay +\",\" +right(awhen,3) +\",\" +oclearing+\",D\"\r\n\r\n\t\t\tendif\r\n\r\n\t\t\tdo write with w\t\t\r\n\r\n\t\tendif\t\t&amp;&amp; otif == 0\r\n\r\n\tendif  &amp;&amp; oleaves &gt; 0 \r\n\r\n\tif oleaves &gt; 0 \t\t&amp;&amp; Still open?\r\n\r\n\t\tgoto tlocate\r\n\r\n\t\treplace ;\r\n\t\t\tPORT\twith oport,;\r\n\t\t\tUSER\twith ouser,;\r\n\t\t\tTOKEN\twith otoken,;\r\n\t\t\tBUY_SELL with obuy_sell,;\r\n\t\t\tLEAVES \twith oleaves,;\r\n\t\t\tSTOCK \twith ostock,;\r\n\t\t\tPRICE \twith oprice,;\r\n\t\t\tSHORT\twith oshort,;\r\n\t\t\tMMID \twith ommid,;\r\n\t\t\tPA\t\twith opa,;\r\n\t\t\tDISPLAY\twith odisplay,;\r\n\t\t\tCLEARING with oclearing,;\r\n\t\t\tFILLED\twith ofilled,;\r\n\t\t\tSEQ\twith tseq\r\n\r\n\telse &amp;&amp; leaves = 0 (add current order to deadlist)\r\n\r\n\t\tgoto tlocate\r\n\t\treplace SEQ with tnextdead\r\n\t\ttnextdead = recno()\r\n\r\n\tendif &amp;&amp; oleaves &gt; 0 \t\r\n\r\nreturn\r\n\r\n****** Enter Report adds a type R line to the file\r\n****** Enter order assumes ostock and obuy_sell are the right length.\r\n\r\nproc enter2report\r\n\r\n\tparameter oport,ouser,otoken,obuy_sell,oshares,ostock,oprice,oshort,ommid,opa,oreport,oclearing,ocontra\r\n\r\n\ttseq = tseq + 1\t\r\n\r\n\ttmatch = tmatch + 1\r\n\r\n\tmwhen = str( tnow , 9 , 3)\r\n\r\n\tw = left( mwhen , 5 ) + \",R,\"+str(tseq,9,0) +\",\" +oPORT+\",\" +oUSER+\",\" +oTOKEN+\",\" +oBUY_SELL +\",   \"+str(oshares,6,0)+\",\"+str(tmatch,9,0)+\",\" +oSTOCK+\",\"+str(oprice,11,4)+\",00000000,    0,\"+oSHORT+\",\"+oMMID+\",\"+oPA+\",\"+ocontra+\",\"+oreport+\",R,\"+right(mwhen,3)+\",\"+oCLEARING+\",D\"\r\n\r\n\tdo write with w\r\n\r\nreturn\r\n\r\n****** Enter Reject adds a type J line to the file\r\n\r\nproc enter2reject\r\n\r\n\tparameter oport,ouser,otoken,otype,oreason\r\n\r\n\ttseq = tseq + 1\t\r\n\r\n\t*** Leaves MUST be 0 or it might be included in the match!\r\n\r\n\tmwhen = str( tnow , 9 , 3)\r\n\r\n\tw = left( mwhen , 5 ) + \",J,\" +str(tseq,9,0) +\",\" +oport+\",\" +ouser +\",\" +otoken+\",\" +otype+\",        0,        0,      ,     0.0000,00000000,    0, ,    , ,    ,\" +oreason +\",N,\"+right(mwhen,3)+\", ,D\"\r\n\r\n\tdo write with w\r\n\r\nreturn\r\n\r\n****** Enter break adds a type C line to the file\r\n\r\nproc enterbreak\r\n\r\n\tparameter oseq, oport , ouser, otoken, obuy_sell, oshares, omatch, ostock, oprice, ommid, oreason, omisc, oclearing , oshort\r\n\r\n\tif oseq &gt; tseq .or. oseq &lt; 1\r\n\r\n\t\t? time()+\" Bad SEQ in Break! OSEQ=\"+str(oseq,9,0)+\" RECS=\"+str( tseq, 9,0)\r\n\r\n\t\treturn\r\n\r\n\tendif\r\n\r\n\tif oshares &lt;= 0 \r\n\r\n\t\t? time()+\" Jerk boy BREAK zero shares SEQ=\"+str(oseq,9,0)\r\n\r\n\t\treturn\r\n\r\n\tendif\r\n\r\n\tif oprice &lt;= 0 \r\n\r\n\t\t? time()+\" Jerk boy BREAK zero price SEQ=\"+str(oseq,9,0)\r\n\r\n\t\treturn\r\n\r\n\tendif\r\n\r\n\tif ! omisc $ \"AR\"\r\n\r\n\t\t? time()+\" Invalid A\/R BREAK MISC=\"+omisc+\" SEQ=\"+str(oseq,9,0)\r\n\r\n\t\treturn\r\n\r\n\tendif\r\n\r\n\tmwhen = str( tnow , 9 , 3)\r\n\r\n\tw = left( mwhen , 5 ) + \",C,\"+str(oseq,9,0) +\",\" +oPORT+\",\" +oUSER+\",\" +oTOKEN+\",\" +oBUY_SELL +\",   \"+str(oshares,6,0)+\",\"+str(omatch,9,0)+\",\" +oSTOCK+\",\"+str(oprice,11,4)+\",00000000,    0,\"+oshort+\",\"+oMMID+\", ,\"+oreason +\",\"+omisc+\", ,\"+right(mwhen,3)+\",\"+oCLEARING+\",D\"\r\n\r\n\tdo write with w\r\n\r\nreturn\r\n\r\n****** Enter maint adds a type M line to the file\r\n\r\n*** SHORTTYPE\r\n***** N - No short sale checks\r\n***** B - Bidtick test\r\n***** L - Lasttrade test\r\n\r\n*** BLOCKSUB - Block subscriber only orders?\r\n***** B - Block\r\n***** N - No block\r\n\r\n*** CENTER\r\n***** Q - NASDAQ\r\n***** L - LISTED\r\n\r\nproc entermaint\r\n\r\n\tparameter oport,ouser,otoken,ostock,oshorttype,oblocksub,ocenter,omisc\r\n\r\n\tif ! oshorttype $ \"NBL\"\r\n\r\n\t\t? time()+\" Bad SHORTTYPE=\"+oshorttype+\" STOCK=\"+ostock\r\n\r\n\t\treturn\r\n\r\n\tendif\r\n\r\n\tif !oblocksub $ \"BN\"\r\n\t\t? time()+\" Bad BLOCKSUB=\"+oblocksub+\" STOCK=\"+ostock\r\n\r\n\t\treturn\r\n\tendif\r\n\r\n\tif !ocenter $ \"QL\"\r\n\t\t? time()+\" Bad CENTER=\"+ocenter+\" STOCK=\"+ostock\r\n\r\n\t\treturn\r\n\tendif\r\n\r\n\tif len( omisc ) # 4 \r\n\t\t? time()+\" Bad omisc len!\"+omisc\r\n\t\treturn\r\n\tendif\r\n\r\n\tfor eml = 1 to 4\r\n\r\n\t\temb = substr( omisc , eml , 1 )\r\n\r\n\t\tif !isalpha( emb ) .and. emb # \" \"\r\n\r\n\t\t\t? time()+\" Bad omisc letter!\"+omisc\r\n\t\t\treturn\r\n\r\n\t\tendif\r\n\r\n\tendfor\r\n\r\n\tawhen = str( tnow , 9 , 3 )\r\n\r\n\tw = left( awhen , 5 ) +\",M,        0,\"+oport+\",\"+ouser+\",\"+otoken+\",S,        0,        0,\" +ostock +\",     0.0000,00000000,    0,\"+oshorttype+\",    , ,\"+omisc+\",\"+ocenter+\",\"+oblocksub+\",\" +right(awhen,3) +\", , \"\r\n\r\n\tdo write with w\r\n\r\nreturn\r\n\r\n*** STATE - Trading state\r\n***** T - Trading\r\n***** H - Halted\r\n\r\nproc enterstate\r\n\r\n\tparameter oport,ouser,otoken,ostock,ostate\r\n\r\n\tif !ostate $ \"TH\"\r\n\t\t? time()+\" Bad STATE=\"+ostate+\" STOCK=\"+ostock\r\n\r\n\t\treturn\r\n\tendif\r\n\r\n\tawhen = str( tnow , 9 , 3 )\r\n\r\n\tw = left( awhen , 5 ) +\",M,        0,\"+oport+\",\"+ouser+\",\"+otoken+\",T,        0,        0,\" +ostock +\",     0.0000,00000000,    0, ,    , ,    ,\"+ostate+\", ,\" +right(awhen,3) +\", , \"\r\n\r\n\tdo write with w\r\n\r\nreturn\r\n\r\n*** Enter account configures an OUCH account\r\n\r\nproc enteraccount\r\n\r\n\tparameter oaccount,opassword,otest,otrusted, othresh, osscheck,oiflag, odefault\r\n\r\n\tif !otest$\"TN\"\r\n\r\n\t\t? time()+\" Bad TEST flag in enteraccount:\"+otest\r\n\t\treturn\r\n\r\n\tendif\r\n\r\n\tif !otrusted$\"TN\"\r\n\r\n\t\t? time()+\" Bad TRUSTED flag in enteraccount:\"+otrusted\r\n\t\treturn\r\n\r\n\tendif\r\n\r\n\tif !osscheck$\"YN\"\r\n\r\n\t\t? time()+\" Bad SSCHECK flag in enteraccount:\"+osscheck\r\n\t\treturn\r\n\r\n\tendif\r\n\r\n\tif !oiflag$\"IN\"\r\n\r\n\t\t? time()+\" Bad IFLAG flag in enteraccount:\"+oiflag\r\n\t\treturn\r\n\r\n\tendif\r\n\r\n\tif len( opassword ) # 10\r\n\t\t? time()+\" Bad opassword len!\"+opassword\r\n\t\treturn\r\n\tendif\r\n\r\n\tfor eml = 1 to 10\r\n\r\n\t\temb = substr( opassword , eml , 1 )\r\n\r\n\t\tif !isalpha( emb ) .and. !isdigit( emb) .and. emb # \" \" .and. emb # \"!\" .and. emb # \"#\"\r\n\r\n\t\t\t? time()+\" Bad opassword letter!\"+opassword+\":\"+str(eml)\r\n\t\t\treturn\r\n\r\n\t\tendif\r\n\r\n\tendfor\r\n\r\n\tif len( oaccount ) # 6\r\n\t\t? time()+\" Bad oaccount len!\"+oaccount\r\n\t\treturn\r\n\tendif\r\n\r\n\tfor eml = 1 to 6\r\n\r\n\t\temb = substr( oaccount , eml , 1 )\r\n\r\n\t\tif !isalpha( emb ) .and. !isdigit( emb ) .and. emb # \" \"\r\n\r\n\t\t\t? time()+\" Bad oaccount letter!\"+oaccount+\":\"+str(eml)\r\n\t\t\treturn\r\n\r\n\t\tendif\r\n\r\n\tendfor\r\n\r\n\tif len( odefault ) # 4\r\n\t\t? time()+\" Bad odefault len!\"+odefault\r\n\t\treturn\r\n\tendif\r\n\r\n\tfor eml = 1 to 4\r\n\r\n\t\temb = substr( odefault , eml , 1 )\r\n\r\n\t\tif !isalpha( emb ) .and. !isdigit( emb) .and. emb # \" \"\r\n\r\n\t\t\t? time()+\" Bad odefault letter!\"+odefault +\":\"+str(eml)\r\n\t\t\treturn\r\n\r\n\t\tendif\r\n\r\n\tendfor\r\n\r\n\tawhen = str( tnow , 9 , 3 )\r\n\r\n\tw = left( awhen , 5 ) +\",M,        0,\"+oaccount+\",    ,\"+opassword+\",A,\"+str(othresh,9,0)+\",        0,      ,     0.0000,00000000,    0,\"+osscheck+\",\"+odefault +\", ,\"+otest+ \" \"+ otrusted +\" ,\"+oiflag+\", ,\" +right(awhen,3) +\", , \"\r\n\r\n\tdo write with w\r\n\r\nreturn\r\n\r\n*** Enter firm configures an OUCH account for clearing\r\n\r\nproc enterfirm\r\n\r\n\tparameter oaccount,ommid,oclearing\r\n\r\n\tif !oclearing$\"AIQRN\"\r\n\r\n\t\t? time()+\" Bad clearing in enterfirm:\"+oclearing\r\n\t\treturn\r\n\r\n\tendif\r\n\r\n\tif len( ommid ) # 4\r\n\t\t? time()+\" Bad ommid len!\"+ommid\r\n\t\treturn\r\n\tendif\r\n\r\n\tfor eml = 1 to 4\r\n\r\n\t\temb = substr( ommid , eml , 1 )\r\n\r\n\t\tif !isalpha( emb ) .and. !isdigit( emb) .and. emb # \" \"\r\n\r\n\t\t\t? time()+\" Bad ommid letter!\"+ommid+\":\"+str(eml)\r\n\t\t\treturn\r\n\r\n\t\tendif\r\n\r\n\tendfor\r\n\r\n\tif len( oaccount ) # 6\r\n\t\t? time()+\" Bad oaccount len!\"+oaccount\r\n\t\treturn\r\n\tendif\r\n\r\n\tfor eml = 1 to 6\r\n\r\n\t\temb = substr( oaccount , eml , 1 )\r\n\r\n\t\tif !isalpha( emb ) .and. !isdigit( emb ) .and. emb # \" \"\r\n\r\n\t\t\t? time()+\" Bad oaccount letter!\"+oaccount+\":\"+str(eml)\r\n\t\t\treturn\r\n\r\n\t\tendif\r\n\r\n\tendfor\r\n\r\n\tawhen = str( tnow , 9 , 3 )\r\n\r\n\tw = left( awhen , 5 ) +\",M,        0,\"+oaccount+\",    ,          ,F,        0,        0,      ,     0.0000,00000000,    0, ,\"+ ommid +\", ,    , , ,\" +right(awhen,3) +\",\"+oclearing+\", \"\r\n\r\n\tdo write with w\r\n\r\nreturn\r\n\r\nproc new2cancel\r\n\r\n\tparameter olocate,oseq,oshares,ocontra\t\t&amp;&amp; Contra indeicates reason for cancel\r\n\r\n\tif olocate &lt;= 0 .or. olocate &gt; reccount()\r\n\r\n\t\t? time()+\" CANCEL LOCATE OUT OF BOUNDS \" +str( olocate , 8 , 0)+ \" SEQ=\" +str(oseq,8,0)\r\n\r\n\t\treturn 0\r\n\r\n\tendif\r\n\r\n\tgoto olocate\r\n\r\n\tif oseq # SEQ\r\n\r\n***\t\t? time()+\" CANCEL OUT OF DATE \" +str( olocate , 8 , 0)+ \" SEQ=\" +str(oseq,8,0)\r\n\r\n\t\tttoolate = ttoolate + 1\r\n\r\n\t\treturn 0\r\n\r\n\tendif\r\n\r\n\tif LEAVES &lt;= oshares\r\n\r\n\t\tttoolate = ttoolate + 1\r\n\r\n\t\treturn\r\n\r\n\tendif\r\n\r\n\txshares = LEAVES - oshares \r\n\r\n\tdo mwrite with \"X\", SEQ , xshares , PRICE , ocontra , \" \" , 0 , recno() \r\n\r\n\ttxcount = txcount + 1\r\n\r\n\tdleaves = LEAVES - xshares\r\n\r\n\tif dleaves &lt;=0 \r\n\r\n\t\t&amp;&amp; Must set LEAVES to zero to pull order from indexes\r\n\r\n\t\treplace LEAVES with 0 , SEQ with tnextdead\r\n\t\ttnextdead = recno()\r\n\r\n\telse\r\n\r\n\t\treplace LEAVES with dleaves\r\n\r\n\tendif\r\n\r\nreturn\r\n\r\n****** Cancel Order takes a locator and a SEQ number\r\n****** passed shares in new intedned order size\r\n****** returns number of shares canceled and leaves record pointer on order canceled.\r\n\r\nproc i2cancel\r\n\r\n\tparameter olocate,oseq,oshares,ocontra\t\t&amp;&amp; Contra indeicates reason for cancel\r\n\r\n\tif olocate &lt;= 0 .or. olocate &gt; reccount()\r\n\r\n\t\t? time()+\" CANCEL LOCATE OUT OF BOUNDS \" +str( olocate , 8 , 0)+ \" SEQ=\" +str(oseq,8,0)\r\n\r\n\t\treturn 0\r\n\r\n\tendif\r\n\r\n\tgoto olocate\r\n\r\n\tif oseq # SEQ\r\n\r\n***\t\t? time()+\" CANCEL OUT OF DATE \" +str( olocate , 8 , 0)+ \" SEQ=\" +str(oseq,8,0)\r\n\r\n\t\tttoolate = ttoolate + 1\r\n\r\n\t\treturn 0\r\n\r\n\tendif\r\n\r\n\tmsize = LEAVES + FILLED\t\t&amp;&amp; Current size of order\r\n\r\n\tif oshares &gt;= msize\r\n\r\n***\t\t? time()+\" INTENEDED CANCEL BIGGER THAN ORDER SHARES=\"+str( oshares, 6 , 0 )+\" REASON=\"+ocontra\r\n\r\n\t\treturn 0\r\n\r\n\tendif\r\n\r\n\txshares = msize - oshares\t\t&amp;&amp; HOwmany do we have to cancel to get from current size to new size?\r\n\r\n\tif xshares &gt; LEAVES\t\t\t\t&amp;&amp; Don't cancel more than are open\r\n\r\n\t\txshares = LEAVES\r\n\r\n\tendif\r\n\r\n\tif xshares = 0\r\n\r\n\t\tttoolate = ttoolate + 1\r\n\r\n\t\treturn 0\r\n\r\n\tendif\r\n\r\n\tdo mwrite with \"X\", SEQ , xshares , PRICE , ocontra , \" \" , 0 , recno()\r\n\r\n\ttxcount = txcount + 1\r\n\r\n\tdleaves = LEAVES - xshares\r\n\r\n\tif dleaves &lt;=0 \r\n\r\n\t\t&amp;&amp; Must set LEAVES to zero to pull order from indexes\r\n\r\n\t\treplace LEAVES with 0 , SEQ with tnextdead\r\n\t\ttnextdead = recno()\r\n\r\n\telse\r\n\r\n\t\treplace LEAVES with dleaves\r\n\r\n\tendif\r\n\r\nreturn xshares\r\n\r\nproc initstatus\r\n\tactivate window status\r\n\t@ 0,1  SAY \"Orders:\"\r\n\t@ 0,27 SAY \"Executions:\"\r\n\t@ 0,52 SAY \"Cancels:\"\r\n\tactivate window ticker\r\nreturn\r\n\r\nproc showstatus\r\n\tactivate window status\r\n\t@ 0,11 SAY tseq    PICTURE \"##,###,###\"\r\n\t@ 0,38 SAY tmatch  PICTURE \"##,###,###\"\r\n\t@ 0,60 SAY txcount PICTURE \"##,###,###\"\r\n\tactivate window ticker\r\nreturn\r\n\r\nproc processtcpip\r\n\r\n\tparam ptm\r\n\r\n\ttcommand = substr( ptm , 1 , 1 )\r\n\r\n\tif geom\r\n\r\n\t\t? time()+\" Command recieved after EOM:\"+tcommand\r\n\t\treturn\r\n\r\n\tendif\r\n\r\n\tdo case\r\n\r\n\t\tcase tcommand = \"H\"\r\n\r\n\t\t\ttport \t\t= \t\tsubstr( ptm ,  2 , 6  )\r\n\r\n\t\t\tif !seek( tport , \"SOURCES\" ) \r\n\r\n\t\t\t\tinsert into SOURCES values ( tport , 1 )\r\n\r\n\t\t\tendif\r\n\r\n\t\t\ttinseq      =   val(substr( ptm , 73,  9  ) )\r\n\r\n\t\t\tif tinseq # SOURCES.SEQ\r\n\r\n\t\t\t\tif tinseq &lt; SOURCES.SEQ \r\n\r\n***\t\t\t\t\t? time()+\" Duped inseq \"+tport+\" Expected:\"+str( SOURCES.SEQ , 9, 0)+\" Got:\"+str( tinseq , 9 , 0 )\t\t\t\t\r\n\t\t\t\t\treturn\r\n\r\n\t\t\t\tendif\t\t\t\r\n\r\n\t\t\t\tdo alert with \"Gapped inseq \"+tport+\" Expected:\"+str( SOURCES.SEQ , 9, 0)+\" Got:\"+str( tinseq , 9 , 0 )\t\t\t\t\r\n\r\n\t\t\tendif\t\t\t\t\r\n\r\n\t\t\ttuser \t\t= \t\tsubstr( ptm ,  8 , 4  )\r\n\t\t\tttoken \t\t= \t\tsubstr( ptm , 12 , 10 )\r\n\t\t\ttbuy_sell\t= \t\tsubstr( ptm , 22 , 1  )\r\n\t\t\ttshares \t= val(\tsubstr( ptm , 23 , 6  ) )\r\n\t\t\ttmin\t\t= val(\tsubstr( ptm , 29 , 6  ) )\r\n\t\t\ttstock\t\t= \t\tsubstr( ptm , 35 , 6  )\r\n\t\t\ttprice \t\t= val(  substr( ptm , 41 , 11 ) )\r\n\t\t\tttif\t\t= val( \tsubstr( ptm , 52 , 5  ) )\r\n\t\t\ttdisplay    =\t\tsubstr( ptm , 57 , 1  )\r\n\t\t\ttshort\t\t=\t\tsubstr( ptm , 58 , 1  )\r\n\t\t\ttpa\t\t\t=\t\tsubstr( ptm , 59 , 1  )\r\n\t\t\ttmmid\t\t=\t\tsubstr( ptm , 60 , 4  )\r\n\t\t\ttclearing  \t= \t\tsubstr( ptm , 64 , 1  )\r\n\t\t\ttflags      = \t\tsubstr( ptm , 65 , 4  )\r\n\r\n\t\t\tif tbuy_sell = \"B\"\r\n\r\n\t\t\t\txshort = \" \"\r\n\r\n\t\t\telse\r\n\r\n\t\t\t\tif tbuy_sell # \"S\"\r\n\r\n\t\t\t\t\t? time()+\" Bad buy_sell \"+tbuy_sell+\" port=\"+tport\r\n\r\n\t\t\t\t\treturn\r\n\r\n\t\t\t\tendif\r\n\r\n\t\t\t\tdo case\r\n\t\t\t\t\tcase tshort = \"Y\"\r\n\t\t\t\t\t\txshort = \"S\"\r\n\r\n\t\t\t\t\tcase tshort = \"S\"\r\n\t\t\t\t\t\txshort = \"S\"\r\n\r\n\t\t\t\t\tcase tshort = \"N\"\r\n\t\t\t\t\t\txshort = \"L\"\r\n\r\n\t\t\t\t\tcase tshort = \"L\"\r\n\t\t\t\t\t\txshort = \"L\"\t\r\n\r\n\t\t\t\t\tcase tshort = \"E\"\r\n\t\t\t\t\t\txshort = \"E\"\r\n\r\n\t\t\t\t\totherwise \r\n\t\t\t\t\t\txshort = \"?\"\r\n\r\n\t\t\t\tendcase\r\n\r\n\t\t\tendif\r\n\r\n\t\t\tif tshares &lt;= 0 \r\n\r\n\t\t\t\t? time()+\" Jerk boy zero shares TOKEN \" +tport+\"-\" +tuser+\"-\" +ttoken\r\n\r\n\t\t\t\treturn\r\n\r\n\t\t\tendif\r\n\r\n\t\t\tif tshares &gt;= 1000000\r\n\r\n\t\t\t\t? time()+\" Jerk boy million shares TOKEN \" +tport+\"-\" +tuser+\"-\" +ttoken\r\n\r\n\t\t\t\treturn\r\n\r\n\t\t\tendif\r\n\r\n\t\t\tif tprice &lt;= 0 \r\n\r\n\t\t\t\t? time()+\" Jerk boy zero price TOKEN \" +tport+\"-\" +tuser+\"-\" +ttoken\r\n\r\n\t\t\t\treturn\r\n\r\n\t\t\tendif\r\n\r\n\t\t\tif tprice &gt;= 1000000\r\n\r\n\t\t\t\t? time()+\" Jerk boy million price TOKEN \" +tport+\"-\" +tuser+\"-\" +ttoken\r\n\r\n\t\t\t\treturn\r\n\r\n\t\t\tendif\r\n\r\n\t\t\tif ! tclearing $ \"AIQOR\"\r\n\r\n\t\t\t\t? time()+\" Jerk boy strange clearing &gt;\" +tclearing+\"&lt; TOKEN \" +tport+\"-\" +tuser+\"-\" +ttoken\r\n\r\n\t\t\t\treturn\r\n\r\n\t\t\tendif\r\n\r\n\t\t\tif ! tdisplay $ \"YNLRP\"\r\n\r\n\t\t\t\t? time()+\" Jerk boy strange display &gt;\" +tdisplay+\"&lt; TOKEN \" +tport+\"-\" +tuser+\"-\" +ttoken\r\n\r\n\t\t\t\treturn\r\n\r\n\t\t\tendif\r\n\r\n\t\t\tif (tdisplay = \"R\" .or. tdisplay = \"P\" ) .and. ttif &gt; 0\r\n\r\n\t\t\t\t? time()+\" Jerk boy R or P or Q display with nonzero tif &gt;\" +str(ttif,5,0)+\"&lt; TOKEN \" +tport+\"-\"+tuser+\"-\"+ttoken\r\n\r\n\t\t\t\treturn\r\n\r\n\t\t\tendif\t\r\n\r\n\t\t\tif !gaccept\r\n\r\n\t\t\t\t? time()+\" Trade ignored outside SOD-EOD time \"+tport+\"-\" +tuser+\"-\" +ttoken\r\n\r\n\t\t\t\treturn\r\n\r\n\t\t\tendif\r\n\r\n\t\t\tif tclearing = \"A\"\r\n\r\n\t\t\t\tif !gactaccept\r\n\r\n\t\t\t\t\t? time()+\" ACT trade ignored outside ACT time \" +tport+\"-\" +tuser+\"-\" +ttoken\r\n\r\n\t\t\t\t\treturn\r\n\r\n\t\t\t\tendif\r\n\r\n\t\t\tendif\r\n\r\n\t\t\tselect SOURCES\r\n\t\t\treplace SEQ with tinseq + 1\r\n\t\t\tselect ISLAND\r\n\r\n\t\t\tdo enter2order with tport , tuser , ttoken , tbuy_sell , tshares , tstock , tprice , ttif , xshort , tmmid , tpa , tdisplay , tmin , tclearing , tflags\r\n\r\n\t\tcase tcommand = \"L\"\r\n\r\n\t\t\ttolocate\t= val(\tsubstr( ptm ,  2 , 8  ) )\r\n\t\t\ttoseq \t\t= val(\tsubstr( ptm , 10 , 9  ) )\r\n\t\t\ttshares \t= val(\tsubstr( ptm , 19 , 6  ) )\r\n\t\t\ttreason\t\t= \t\tsubstr( ptm , 25 , 1  ) \r\n\r\n\t\t\tdo case\r\n\t\t\t\tcase treason = \"A\"\r\n\t\t\t\t\txreason = \"#USR\"\r\n\t\t\t\tcase treason = \"B\"\r\n\t\t\t\t\txreason = \"#TME\"\r\n\t\t\t\tcase treason = \"C\"\r\n\t\t\t\t\txreason = \"#HLT\"\r\n\t\t\t\tcase treason = \"D\"\r\n\t\t\t\t\txreason = \"#SUP\"\r\n\t\t\t\tcase treason = \"E\"\r\n\t\t\t\t\txreason = \"#DNT\"\r\n\t\t\t\tcase treason = \"F\"\r\n\t\t\t\t\txreason = \"#MBL\"\r\n\r\n\t\t\t\totherwise\r\n\t\t\t\t\txreason = \"#USR\"\r\n\t\t\tendcase\r\n\r\n\t\t\tdo new2cancel with tolocate , toseq , tshares , xreason\r\n\r\n\t\tcase tcommand = \"I\"\r\n\r\n\t\t\ttport \t\t= \t\tsubstr( ptm ,  2 , 6  )\r\n\r\n\t\t\tif !seek( tport , \"SOURCES\" ) \r\n\r\n\t\t\t\tinsert into SOURCES values ( tport , 1 )\r\n\r\n\t\t\tendif\r\n\r\n\t\t\ttinseq \t\t=  val( substr( ptm , 24 , 9 ) )\t\t\t\r\n\r\n\t\t\tif tinseq # SOURCES.SEQ\r\n\r\n\t\t\t\tif tinseq &lt; SOURCES.SEQ \r\n\r\n***\t\t\t\t\t? time()+\" Duped REJ inseq \"+tport+\" Expected:\"+str( SOURCES.SEQ , 9, 0)+\" Got:\"+str( tinseq , 9 , 0 )\t\t\t\t\r\n\t\t\t\t\treturn\r\n\r\n\t\t\t\tendif\t\t\t\r\n\r\n\t\t\t\tdo alert with \"Gapped REJ inseq \"+tport+\" Expected:\"+str( SOURCES.SEQ , 9, 0)+\" Got:\"+str( tinseq , 9 , 0 )\t\t\t\t\r\n\r\n\t\t\tendif\t\t\t\t\r\n\r\n\t\t\ttuser \t\t= \t\tsubstr( ptm ,  8 , 4  )\r\n\t\t\tttoken \t\t= \t\tsubstr( ptm , 12 , 10 )\r\n\t\t\tttype\t\t=\t\tsubstr( ptm , 22 , 1 )\r\n\t\t\ttreason\t\t= \t\tsubstr( ptm , 23 , 1  ) \t\t\t\r\n\r\n\t\t\tdo enter2reject with tport , tuser , ttoken , ttype , treason\r\n\r\n\t\t\tselect SOURCES\r\n\t\t\treplace SEQ with tinseq + 1\r\n\t\t\tselect ISLAND\r\n\r\n\t\tcase tcommand = \"Z\"\r\n\r\n\t\t\ttolocate\t= val(\tsubstr( ptm ,  2 , 8  ) )\r\n\t\t\ttoseq \t\t= val(\tsubstr( ptm , 10 , 9  ) )\r\n\t\t\ttshares \t= val(\tsubstr( ptm , 19 , 6  ) )\r\n\t\t\ttreason\t\t= \t\tsubstr( ptm , 25 , 1  ) \r\n\r\n\t\t\tdo case\r\n\t\t\t\tcase treason = \"A\"\r\n\t\t\t\t\txreason = \"#USR\"\r\n\t\t\t\tcase treason = \"B\"\r\n\t\t\t\t\txreason = \"#TME\"\r\n\t\t\t\tcase treason = \"C\"\r\n\t\t\t\t\txreason = \"#HLT\"\r\n\t\t\t\tcase treason = \"D\"\r\n\t\t\t\t\txreason = \"#SUP\"\r\n\t\t\t\tcase treason = \"E\"\r\n\t\t\t\t\txreason = \"#DNT\"\r\n\t\t\t\tcase treason = \"F\"\r\n\t\t\t\t\txreason = \"#MBL\"\r\n\r\n\t\t\t\totherwise\r\n\t\t\t\t\txreason = \"#USR\"\r\n\t\t\tendcase\r\n\r\n\t\t\t=i2cancel( tolocate , toseq , tshares , xreason )\r\n\r\n\t\tcase tcommand = \"S\"\r\n\r\n\t\t\ttport \t\t= \t\tsubstr( ptm ,  2 , 6  )\r\n\r\n\t\t\tif !seek( tport , \"SOURCES\" ) \r\n\r\n\t\t\t\tinsert into SOURCES values ( tport , 1 )\r\n\r\n \t\t\tendif\r\n\r\n\t\t\ttinseq        =   val(substr( ptm , 58 , 9  ) )\r\n\r\n\t\t\tif tinseq # SOURCES.SEQ\r\n\r\n\t\t\t\tif tinseq &lt; SOURCES.SEQ \r\n\r\n***\t\t\t\t\t? time()+\" Duped REP inseq \"+tport+\" Expected:\"+str( SOURCES.SEQ , 9, 0)+\" Got:\"+str( tinseq , 9 , 0 )\t\t\t\t\r\n\t\t\t\t\treturn\r\n\r\n\t\t\t\tendif\t\t\t\r\n\r\n\t\t\t\tdo alert with \"Gapped REP inseq \"+tport+\" Expected:\"+str( SOURCES.SEQ , 9, 0)+\" Got:\"+str( tinseq , 9 , 0 )\t\t\t\t\r\n\r\n\t\t\tendif\t\t\t\t\r\n\r\n\t\t\ttuser \t\t= \t\tsubstr( ptm ,  8 , 4  )\r\n\t\t\tttoken \t\t= \t\tsubstr( ptm , 12 , 10 )\r\n\t\t\ttbuy_sell\t= \t\tsubstr( ptm , 22 , 1  )\r\n\t\t\ttshares \t= val(\tsubstr( ptm , 23 , 6  ) )\r\n\t\t\ttstock\t\t= \t\tsubstr( ptm , 29 , 6  )\r\n\t\t\ttprice \t\t= val(  substr( ptm , 35 , 11 ) )\r\n\t\t\ttreport \t=\t\tsubstr( ptm , 46 , 1  ) \r\n\t\t\ttshort\t\t=\t\tsubstr( ptm , 47 , 1  )\r\n\t\t\ttpa\t\t\t=\t\tsubstr( ptm , 48 , 1  )\r\n\t\t\ttmmid\t\t=\t\tsubstr( ptm , 49 , 4  )\r\n\t\t\ttclearing  \t= \t\tsubstr( ptm , 53 , 1  )\r\n\t\t\ttcontra     =       substr( ptm , 54 , 4  )\r\n\r\n\t\t\tif ! treport $ \"YNS\"\r\n\t\t\t\t? time()+\" Jerk boy REPORT code TOKEN \" +tport\r\n\r\n\t\t\t\treturn\r\n\r\n\t\t\tendif\r\n\r\n\t\t\tif tshares &lt;= 0 \r\n\r\n\t\t\t\t? time()+\" Jerk boy REPORT zero shares TOKEN \"+tport+\"-\"+tuser+\"-\"+ttoken\r\n\r\n\t\t\t\treturn\r\n\r\n\t\t\tendif\r\n\r\n\t\t\tif tshares &gt;= 1000000\r\n\r\n\t\t\t\t? \"Jerk boy REPORT million shares TOKEN \"+tport+\"-\"+tuser+\"-\"+ttoken\r\n\r\n\t\t\t\treturn\r\n\r\n\t\t\tendif\r\n\r\n\t\t\tif tprice &lt;= 0 \r\n\r\n\t\t\t\t? \"Jerk boy REPORT zero price TOKEN \"+tport+\"-\"+tuser+\"-\"+ttoken\r\n\r\n\t\t\t\treturn\r\n\r\n\t\t\tendif\r\n\r\n\t\t\tif tprice &gt;= 1000000\r\n\r\n\t\t\t\t? \"Jerk boy REPORT million price TOKEN \"+tport+\"-\"+tuser+\"-\"+ttoken\r\n\r\n\t\t\t\treturn\r\n\r\n\t\t\tendif\r\n\r\n\t\t\tif ! tclearing $ \"ABSIQORN\"\r\n\r\n\t\t\t\t? \"Jerk boy REPORT strange clearing &gt;\"+tclearing+\"&lt; TOKEN \"+tport+\"-\"+tuser+\"-\"+ttoken\r\n\r\n\t\t\t\treturn\r\n\r\n\t\t\tendif\r\n\r\n\t\t\tif !gaccept\r\n\r\n\t\t\t\t? \"Report ignored outside SOD-EOD time \"+tport+\"-\"+tuser+\"-\"+ttoken\r\n\r\n\t\t\t\treturn\r\n\r\n\t\t\tendif\r\n\r\n\t\t\tif tclearing = \"A\"\r\n\r\n\t\t\t\tif !gactaccept\r\n\r\n\t\t\t\t\t? \"ACT trade REPORT ignored outside ACT time \"+tport+\"-\"+tuser+\"-\"+ttoken\r\n\r\n\t\t\t\t\treturn\r\n\r\n\t\t\t\tendif\r\n\r\n\t\t\tendif\r\n\r\n\t\t\tdo enter2report with tport , tuser , ttoken , tbuy_sell , tshares , tstock , tprice , tshort , tmmid , tpa , treport ,  tclearing , tcontra\r\n\r\n\t\t\tselect SOURCES\r\n\t\t\treplace SEQ with tinseq + 1\r\n\t\t\tselect ISLAND\r\n\r\n\t\tcase tcommand = \"D\"\r\n\r\n\t\t\ttcseq \t\t= val(  substr( ptm ,  2 , 9  ) )\r\n\t\t\ttcport\t\t= \t\tsubstr( ptm , 11 , 6 )\r\n\t\t\ttcuser\t\t=\t\tsubstr( ptm , 17 , 4 )\r\n\t\t\ttctoken \t=\t\tsubstr( ptm , 21 , 10 )\r\n\t\t\ttcbuy_sell  =       substr( ptm , 31 , 1  )\r\n\t\t\ttcshares \t= val(\tsubstr( ptm , 32 , 6  ) )\r\n\t\t\ttcmatch     = val(  substr( ptm , 38 , 9  ) )\r\n\t\t\ttcstock     =       substr( ptm , 47 , 6 )\r\n\t\t\ttcprice \t= val(  substr( ptm , 53 , 11 ) )\r\n\t\t\ttcmmid   \t=       substr( ptm , 64 , 4  )\r\n\t\t\ttcmisc\t\t=       substr( ptm , 68 , 1 )\r\n\t\t\ttcreason\t= \t\tsubstr( ptm , 69 , 1 ) \r\n\t\t\ttcclearing\t=       substr( ptm , 70 , 1 )\r\n\r\n\t\t\tdo case\r\n\t\t\t\tcase tcreason = \"A\"\r\n\t\t\t\t\txreason = \"#ERR\"\r\n\t\t\t\tcase tcreason = \"B\"\r\n\t\t\t\t\txreason = \"#CON\"\r\n\t\t\t\tcase tcreason = \"C\"\r\n\t\t\t\t\txreason = \"#SUP\"\r\n\t\t\t\tcase tcreason = \"D\"\r\n\t\t\t\t\txreason = \"#SYS\"\r\n\t\t\t\tcase tcreason = \"E\"\r\n\t\t\t\t\txreason = \"#EXT\"\r\n\r\n\t\t\t\totherwise\r\n\r\n\t\t\t\t\t? time()+\" Unvalid break reason = \"+tcreason\r\n\r\n\t\t\t\t\treturn\r\n\r\n\t\t\tendcase\r\n\r\n\t\t\tdo case\r\n\r\n\t\t\t\tcase tcbuy_sell = \"B\"\r\n\t\t\t\t\txbuy_sell = \"B\"\r\n\t\t\t\t\txshort    = \" \"\r\n\r\n\t\t\t\tcase tcbuy_sell = \"S\"\r\n\t\t\t\t\txbuy_sell = \"S\"\r\n\t\t\t\t\txshort = \"L\"\r\n\r\n\t\t\t\tcase tcbuy_sell = \"T\"\r\n\t\t\t\t\txbuy_sell = \"S\"\r\n\t\t\t\t\txshort = \"S\"\r\n\r\n\t\t\t\tcase tcbuy_sell = \"E\"\r\n\t\t\t\t\txbuy_sell = \"S\"\r\n\t\t\t\t\txshort = \"E\"\r\n\r\n\t\t\t\totherwise\r\n\r\n\t\t\t\t\t? time()+\" Unvalid break buy_sell = \"+tcbuy_sell\r\n\t\t\t\t\treturn\r\n\r\n\t\t\tendcase\r\n\r\n\t\t\tdo enterbreak with tcseq , tcport, tcuser, tctoken, xbuy_sell, tcshares , tcmatch ,tcstock , tcprice , tcmmid , xreason , tcmisc , tcclearing , xshort\r\n\r\n\t\tcase tcommand = \"M\"\r\n\r\n\t\t\ttctype \t\t= \t\tsubstr( ptm ,  2 , 1 )\r\n\r\n\t\t\tdo case\r\n\r\n\t\t\t\tcase tctype = \"S\"\t\t&amp;&amp; Stock maintence\r\n\r\n\t\t\t\t\ttport \t\t= \t\tsubstr( ptm ,  3 , 6  )\r\n\t\t\t\t\ttuser \t\t= \t\tsubstr( ptm ,  9 , 4  )\r\n\t\t\t\t\tttoken \t\t= \t\tsubstr( ptm , 13 , 10 )\r\n\r\n\t\t\t\t\ttcstock     = \t\tsubstr( ptm , 23 , 6 )\r\n\r\n\t\t\t\t\ttcshorttype = substr( ptm , 29 , 1 )\r\n\t\t\t\t\ttcblocksub  = substr( ptm , 30 , 1 )\r\n\t\t\t\t\ttccenter    = substr( ptm , 31 , 1 )\r\n\t\t\t\t\ttcmisc\t\t= substr( ptm , 32 , 4 )\r\n\r\n\t\t\t\t\tdo entermaint with tport, tuser, ttoken, tcstock , tcshorttype , tcblocksub , tccenter , tcmisc\r\n\r\n\t\t\t\tcase tctype = \"A\"\t\t&amp;&amp; Account settings\r\n\r\n\t\t\t\t\ttaccount\t= \t\tsubstr( ptm ,  3 , 6  )\r\n\t\t\t\t\ttpassword\t= \t\tsubstr( ptm ,  9 , 10 )\r\n\t\t\t\t\tttest       =       substr( ptm , 19 , 1  )\r\n\t\t\t\t\tttrusted    =       substr( ptm , 20 , 1  ) \r\n\t\t\t\t\ttthresh     = val(  substr( ptm , 21 ,  6 ) )\r\n\t\t\t\t\ttsscheck    =       substr( ptm , 27 , 1 )\r\n\t\t\t\t\ttiflag      =       substr( ptm , 28 , 1 )\r\n\t\t\t\t\ttdefault    =       substr( ptm , 29 , 4  )\r\n\r\n\t\t\t\t\tdo enteraccount with taccount, tpassword, ttest , ttrusted , tthresh, tsscheck, tiflag, tdefault\r\n\r\n\t\t\t\tcase tctype = \"F\"\t\t&amp;&amp; Account settings\r\n\r\n\t\t\t\t\ttaccount\t= \t\tsubstr( ptm ,  3 , 6  )\r\n\t\t\t\t\ttmmid       =       substr( ptm ,  9 , 4  )\r\n\t\t\t\t\ttclearing   =       substr( ptm , 13 , 1  )\r\n\r\n\t\t\t\t\tdo enterfirm with taccount, tmmid, tclearing\r\n\r\n\t\t\t\tcase tctype = \"T\"\t\t&amp;&amp; Stock state\r\n\r\n\t\t\t\t\ttport \t\t= \t\tsubstr( ptm ,  3 , 6  )\r\n\t\t\t\t\ttuser \t\t= \t\tsubstr( ptm ,  9 , 4  )\r\n\t\t\t\t\tttoken \t\t= \t\tsubstr( ptm , 13 , 10 )\r\n\r\n\t\t\t\t\ttcstock     = \t\tsubstr( ptm , 23 , 6 )\r\n\r\n\t\t\t\t\ttcstate     = substr( ptm , 29 , 1 )\r\n\r\n\t\t\t\t\tdo enterstate with tport, tuser, ttoken, tcstock , tcstate\r\n\r\n\t\t\t\totherwise\r\n\r\n\t\t\t\t\t? time()+\" Unvalid maint reason = \"+tctype\r\n\r\n\t\t\tendcase\r\n\r\n\t\totherwise\r\n\r\n\t\t\tdo alert with \"Unknown command\"+ptm\r\n\r\n\tendcase\r\n\r\nreturn\r\n\r\nproc sendeos\r\n\r\n\ts = \"E\"\t\t\t\r\n\tcall int99 with s\r\n\r\n\tif s # \"f\" .and. s # \"b\"\r\n\r\n\t\tactivate window output\t\t\r\n\r\n\t\t? time() +\" !!!! ERROR ON EOS WRITE!!!!!!\"\r\n\r\n\t\t? ws\r\n\r\n\t\tactivate window ticker\r\n\r\n\t\tsuspend\r\n\r\n\tendif\r\n\r\nreturn\r\n\r\nproc flush\r\n\r\n\ts = \"F\"\t\t\t\r\n\tcall int99 with s\t\t\t\r\n\tif s # \"f\"\r\n\t\t? \"!!!!ERROR ON FLUSH!!!!\"\r\n\r\n\t\tdo alert with \"Error on flush:\"+werror(s)\r\n\t\tsuspend\r\n\tendif\r\n\r\n\tgstoredflag = .F.\r\n\r\nreturn\r\n\r\nproc shutdown\r\n\r\n\tdo alert with \"Shutdown initiated\"\r\n\r\n\tif !geom\t&amp;&amp; Shutting down too early? Just in case...\r\n\r\n\t\twait window \"Can't end day, EOM has not happened yet!\" nowait\r\n\r\n\t\tdo alert with \"Ending day attempted before EOM time!\"\r\n\r\n\t\treturn\r\n\r\n\tendif\r\n\r\n\tsdk = chr( (rand() * 25) + asc(\"A\") )\r\n\r\n\twait window \"Initiate Shutdown by pressing [\"+sdk+\"] within 10 seconds\" to sdh timeout 10\r\n\r\n\tif upper( sdh ) # sdk \r\n\r\n\t\twait window \"Shutdown Aborted\" nowait\r\n\r\n\t\tdo alert with \"Shutdown aborted\"\r\n\r\n\t\treturn \r\n\r\n\tendif\r\n\r\n\twait window \"Confirm Shutdown by pressing the magic key within 10 seconds\" to sdh timeout 10 \r\n\r\n\tif upper( sdh ) # \"M\"\r\n\r\n\t\twait window \"Inccorect Shutdown confirmation\" nowait\r\n\r\n\t\tdo alert with \"Incorrect shutdown magic key\"\r\n\r\n\t\treturn\r\n\r\n\tendif\r\n\r\n\tdo alert with \"Shutdown confirmed\"\r\n\r\n\tif file( mholdofffile )\r\n\r\n\t\t? \"Holdoff file exists! Escalate!\"\r\n\t\tsuspend\r\n\r\n\telse\r\n\r\n\t\tsdf = fcreate( mholdofffile )\r\n\t\t=fputs( sdf , \"Stop in the name of love!\")\r\n\t\t=fclose( sdf )\r\n\r\n\tendif\r\n\r\n\tif !file( mholdofffile )\r\n\r\n\t\twait window \"No HOLDOFF file created, aborting Shutdown\" nowait\r\n\r\n\t\tdo alert with \"No HOLDOFF file created, aborting shutdown\"\r\n\r\n\t\treturn \r\n\r\n\tendif\r\n\r\n\twait window \"Shutting down...\" nowait\r\n\r\n\tdo swrite with \"N\" , \"\"\r\n\twait window \"Shutting down... 3\" timeout 1\r\n\r\n\tdo swrite with \"N\" , \"\"\r\n\twait window \"Shutting down... 2\" timeout 1\r\n\r\n\tdo swrite with \"N\" , \"\"\r\n\twait window \"Shutting down... 1\" timeout 1\r\n\r\n\tdo flush\r\n\r\n\twait window \"Flushing...\" timeout 1\r\n\r\n\tdo sendeos\r\n\tdo flush\r\n\r\n\twait window \"Sending End of Session... 3\" timeout 1\r\n\tdo flush\r\n\r\n\twait window \"Sending End of Session... 2\" timeout 1\r\n\tdo flush\r\n\r\n\twait window \"Sending End of Session... 1\" timeout 1\r\n\tdo flush\r\n\r\n\twait window \"Sending End of Session... 0\" timeout 1\r\n\tdo flush\r\n\r\n\tmdone = .T.\r\n\r\n\tzap\r\n\r\nreturn \r\n\r\nproc pingreply \r\n\tparam preply , ptm\r\n\r\n\tptoken  = substr( ptm , 2 , 12 )\r\n\tpport = substr( ptm , 14 , 4 )\r\n\r\n\tx = \"R\"+ptoken+str( tseq ,9,0)+str( tmatch ,9,0)+str(0,9,0)\t\r\n\r\n\ts = \"S\"+chr(len(x))+ preply+pport+ x\r\n\tcall int99 with s\r\n\r\nreturn\r\n\r\nproc seteventflags\r\n\tparam secode\r\n\r\n\tdo case\r\n\r\n\t\tcase secode = \"SOD\"\r\n\r\n\t\t\tgaccept = .T.\r\n\t\t\tgactaccept = .T.\r\n\r\n\t\tcase secode = \"EOA\"\r\n\r\n\t\t\tgactaccept = .F.\r\n\r\n\t\tcase secode = \"EOD\"\r\n\r\n\t\t\tgaccept = .F.\r\n\r\n\t\tcase secode = \"EOM\"\r\n\r\n\t\t\tgeom = .T.\r\n\tendcase\r\n\r\nreturn\r\n\r\nproc alert\r\nparameter s\r\n\txs = dtoc(date())+\" \"+time() +\"-\"+ s\r\n\r\n\t? xs\r\n\r\n\tIF FILE( malertfile ) &amp;&amp; Does file exist? \r\n\t\terrfile = FOPEN( malertfile ,12) &amp;&amp; If so, open read\/write\r\n\tELSE\r\n\t\terrfile = FCREATE( malertfile )\t\t&amp;&amp; If not create it\r\n\tENDIF\r\n\r\n\tIF errfile &lt; 0 &amp;&amp; Check for error opening file\r\n\t\tWAIT 'Cannot open or create output file' WINDOW NOWAIT\r\n\tELSE &amp;&amp; If no error, write to file\r\n\t\t=fseek( errfile, 0 , 2 )\r\n\t\t=FWRITE(errfile, xs + chr(13) + chr(10) )\r\n\tENDIF\r\n\r\n\t=FCLOSE(errfile) &amp;&amp; Close file\r\n\r\n\t*\t? chr(07)+chr(07)+chr(07)+chr(07)\r\nreturn<\/pre>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>1. \uc544\uc8fc \uc6b0\uc5f0\ud788 \ub208\uc5d0 \ub4e4\uc5b4\uc654\uc2b5\ub2c8\ub2e4. &#8220;Island ECN\uc758 \uc18c\uc2a4\ucf54\ub4dc\ub97c \uacf5\uac1c\ud588\ub2e4&#8221;\ub294 \uae00\uc774\uc5c8\uc2b5\ub2c8\ub2e4. \uc774\ucc9c\ub144\ub300 \ucd08\ubc18 \ubbf8\uad6d\uc5d0\uc11c \ub300\uccb4\uac70\ub798\uc18c(ATS) \ubc0f ECN\uc744 \uc124\ub9bd\ud558\ub294 \ubd90\uc774 \uc788\uc5c8\uc2b5\ub2c8\ub2e4. \uc774 \ub54c\ub97c \uc124\uba85\ud55c \uae00\uc785\ub2c8\ub2e4. \uc804\uc790\uac70\ub798\uc2dc\uc2a4\ud15c\uc758 \uae09\uc18d\ud55c \uc131\uc7a5\ub0b4\uc5d0\uc11c ECN(Electronic Communications Network)\uc758 \uc131\uc7a5\uc740 \ucd5c\uadfc 2-3\ub144 \ub3d9\uc548 \ub354\uc6b1 \ub450\ub4dc\ub7ec\uc9c0\uace0 \uc788\ub2e4. \uc774\ub7f0 \uc644\uc804\ud788 \uc790\ub3d9\ud654\ub41c \uc2dc\uc2a4\ud15c\uc744 \ud1b5\ud574 \uae30\uad00\uc774\ub098 \ub2e4\ub978 \uc2dc\uc7a5\ucc38\uc5ec\uc790\ub4e4\uc740 \ub2e4\uc591\ud55c \ubc29\ubc95\uc73c\ub85c \uc804\uc790\uc801\uc73c\ub85c \uac70\ub798\ub97c \uccb4\uacb0\uc2dc\ud0ac \uc218 \uc788\ub2e4. \uc218\ub144\uac04 Nasdaq\uacfc \uad00\ub828\ud55c \uc2dc\uc7a5\uc758 \uc99d\uac00\ub97c \ubcf4\uc544\uc628 Day-trading \ud68c\uc0ac\ub4e4\uc740 ECNs&#8230;<br \/><a class=\"read-more-button\" href=\"https:\/\/smallake.kr\/?p=13379\">Read more<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"nf_dc_page":"","om_disable_all_campaigns":false,"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_feature_clip_id":0,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":true,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2},"jetpack_post_was_ever_published":false},"categories":[4],"tags":[1499,1500,1501],"class_list":["post-13379","post","type-post","status-publish","format-standard","hentry","category--it","tag-foxpro","tag-island-ecn","tag-1501"],"aioseo_notices":[],"aioseo_head":"\n\t\t<!-- All in One SEO 4.9.8 - aioseo.com -->\n\t<meta name=\"robots\" content=\"max-image-preview:large\" \/>\n\t<meta name=\"author\" content=\"smallake\"\/>\n\t<meta name=\"keywords\" content=\"foxpro,island ecn,\ub9e4\uce6d\uc5d4\uc9c4\" \/>\n\t<link rel=\"canonical\" href=\"https:\/\/smallake.kr\/?p=13379\" \/>\n\t<meta name=\"generator\" content=\"All in One SEO (AIOSEO) 4.9.8\" \/>\n\t\t<meta property=\"og:locale\" content=\"ko_KR\" \/>\n\t\t<meta property=\"og:site_name\" content=\"\uadf8\ub300\uc548\uc758\uc791\uc740\ud638\uc218 | \uc0b4\uc544\uc628 \ub0a0\uc758 \ud754\uc801, \uc0b4\uc544\uac08 \ub0a0\uc758 \uae30\ub85d\" \/>\n\t\t<meta property=\"og:type\" content=\"article\" \/>\n\t\t<meta property=\"og:title\" content=\"FOXPro\ub85c \ub9cc\ub4e0 \ub9e4\ub9e4\uccb4\uacb0\uc2dc\uc2a4\ud15c | \uadf8\ub300\uc548\uc758\uc791\uc740\ud638\uc218\" \/>\n\t\t<meta property=\"og:url\" content=\"https:\/\/smallake.kr\/?p=13379\" \/>\n\t\t<meta property=\"article:published_time\" content=\"2013-11-11T21:02:40+00:00\" \/>\n\t\t<meta property=\"article:modified_time\" content=\"2013-11-11T21:18:59+00:00\" \/>\n\t\t<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/iumgroup\" \/>\n\t\t<meta name=\"twitter:card\" content=\"summary\" \/>\n\t\t<meta name=\"twitter:site\" content=\"@smallake\" \/>\n\t\t<meta name=\"twitter:title\" content=\"FOXPro\ub85c \ub9cc\ub4e0 \ub9e4\ub9e4\uccb4\uacb0\uc2dc\uc2a4\ud15c | \uadf8\ub300\uc548\uc758\uc791\uc740\ud638\uc218\" \/>\n\t\t<meta name=\"twitter:creator\" content=\"@smallake\" \/>\n\t\t<script type=\"application\/ld+json\" class=\"aioseo-schema\">\n\t\t\t{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/smallake.kr\\\/?p=13379#article\",\"name\":\"FOXPro\\ub85c \\ub9cc\\ub4e0 \\ub9e4\\ub9e4\\uccb4\\uacb0\\uc2dc\\uc2a4\\ud15c | \\uadf8\\ub300\\uc548\\uc758\\uc791\\uc740\\ud638\\uc218\",\"headline\":\"FOXPro\\ub85c \\ub9cc\\ub4e0 \\ub9e4\\ub9e4\\uccb4\\uacb0\\uc2dc\\uc2a4\\ud15c\",\"author\":{\"@id\":\"https:\\\/\\\/smallake.kr\\\/?author=1#author\"},\"publisher\":{\"@id\":\"https:\\\/\\\/smallake.kr\\\/#person\"},\"image\":{\"@type\":\"ImageObject\",\"@id\":\"https:\\\/\\\/smallake.kr\\\/?p=13379#articleImage\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/85bc072c859f1b0c21b1f8ac82394cf817695e7d0f250d2dcfabf8ce7217b415?s=96&r=g\",\"width\":96,\"height\":96,\"caption\":\"smallake\"},\"datePublished\":\"2013-11-12T06:02:40+09:00\",\"dateModified\":\"2013-11-12T06:18:59+09:00\",\"inLanguage\":\"ko-KR\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/smallake.kr\\\/?p=13379#webpage\"},\"isPartOf\":{\"@id\":\"https:\\\/\\\/smallake.kr\\\/?p=13379#webpage\"},\"articleSection\":\"\\uc790\\ubcf8\\uc2dc\\uc7a5\\uacfc IT, foxpro, island ECN, \\ub9e4\\uce6d\\uc5d4\\uc9c4\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/smallake.kr\\\/?p=13379#breadcrumblist\",\"itemListElement\":[{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/smallake.kr#listItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/smallake.kr\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/smallake.kr\\\/?cat=4#listItem\",\"name\":\"\\uc790\\ubcf8\\uc2dc\\uc7a5\\uacfc IT\"}},{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/smallake.kr\\\/?cat=4#listItem\",\"position\":2,\"name\":\"\\uc790\\ubcf8\\uc2dc\\uc7a5\\uacfc IT\",\"item\":\"https:\\\/\\\/smallake.kr\\\/?cat=4\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/smallake.kr\\\/?p=13379#listItem\",\"name\":\"FOXPro\\ub85c \\ub9cc\\ub4e0 \\ub9e4\\ub9e4\\uccb4\\uacb0\\uc2dc\\uc2a4\\ud15c\"},\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/smallake.kr#listItem\",\"name\":\"Home\"}},{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/smallake.kr\\\/?p=13379#listItem\",\"position\":3,\"name\":\"FOXPro\\ub85c \\ub9cc\\ub4e0 \\ub9e4\\ub9e4\\uccb4\\uacb0\\uc2dc\\uc2a4\\ud15c\",\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/smallake.kr\\\/?cat=4#listItem\",\"name\":\"\\uc790\\ubcf8\\uc2dc\\uc7a5\\uacfc IT\"}}]},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/smallake.kr\\\/#person\",\"name\":\"smallake\",\"image\":{\"@type\":\"ImageObject\",\"@id\":\"https:\\\/\\\/smallake.kr\\\/?p=13379#personImage\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/85bc072c859f1b0c21b1f8ac82394cf817695e7d0f250d2dcfabf8ce7217b415?s=96&r=g\",\"width\":96,\"height\":96,\"caption\":\"smallake\"}},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/smallake.kr\\\/?author=1#author\",\"url\":\"https:\\\/\\\/smallake.kr\\\/?author=1\",\"name\":\"smallake\",\"image\":{\"@type\":\"ImageObject\",\"@id\":\"https:\\\/\\\/smallake.kr\\\/?p=13379#authorImage\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/85bc072c859f1b0c21b1f8ac82394cf817695e7d0f250d2dcfabf8ce7217b415?s=96&r=g\",\"width\":96,\"height\":96,\"caption\":\"smallake\"}},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/smallake.kr\\\/?p=13379#webpage\",\"url\":\"https:\\\/\\\/smallake.kr\\\/?p=13379\",\"name\":\"FOXPro\\ub85c \\ub9cc\\ub4e0 \\ub9e4\\ub9e4\\uccb4\\uacb0\\uc2dc\\uc2a4\\ud15c | \\uadf8\\ub300\\uc548\\uc758\\uc791\\uc740\\ud638\\uc218\",\"inLanguage\":\"ko-KR\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/smallake.kr\\\/#website\"},\"breadcrumb\":{\"@id\":\"https:\\\/\\\/smallake.kr\\\/?p=13379#breadcrumblist\"},\"author\":{\"@id\":\"https:\\\/\\\/smallake.kr\\\/?author=1#author\"},\"creator\":{\"@id\":\"https:\\\/\\\/smallake.kr\\\/?author=1#author\"},\"datePublished\":\"2013-11-12T06:02:40+09:00\",\"dateModified\":\"2013-11-12T06:18:59+09:00\"},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/smallake.kr\\\/#website\",\"url\":\"https:\\\/\\\/smallake.kr\\\/\",\"name\":\"\\uadf8\\ub300\\uc548\\uc758 \\uc791\\uc740 \\ud638\\uc218\",\"description\":\"\\uc0b4\\uc544\\uc628 \\ub0a0\\uc758 \\ud754\\uc801, \\uc0b4\\uc544\\uac08 \\ub0a0\\uc758 \\uae30\\ub85d\",\"inLanguage\":\"ko-KR\",\"publisher\":{\"@id\":\"https:\\\/\\\/smallake.kr\\\/#person\"}}]}\n\t\t<\/script>\n\t\t<!-- All in One SEO -->\n\n","aioseo_head_json":{"title":"FOXPro\ub85c \ub9cc\ub4e0 \ub9e4\ub9e4\uccb4\uacb0\uc2dc\uc2a4\ud15c | \uadf8\ub300\uc548\uc758\uc791\uc740\ud638\uc218","description":"","canonical_url":"https:\/\/smallake.kr\/?p=13379","robots":"max-image-preview:large","keywords":"foxpro,island ecn,\ub9e4\uce6d\uc5d4\uc9c4","webmasterTools":{"miscellaneous":""},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/smallake.kr\/?p=13379#article","name":"FOXPro\ub85c \ub9cc\ub4e0 \ub9e4\ub9e4\uccb4\uacb0\uc2dc\uc2a4\ud15c | \uadf8\ub300\uc548\uc758\uc791\uc740\ud638\uc218","headline":"FOXPro\ub85c \ub9cc\ub4e0 \ub9e4\ub9e4\uccb4\uacb0\uc2dc\uc2a4\ud15c","author":{"@id":"https:\/\/smallake.kr\/?author=1#author"},"publisher":{"@id":"https:\/\/smallake.kr\/#person"},"image":{"@type":"ImageObject","@id":"https:\/\/smallake.kr\/?p=13379#articleImage","url":"https:\/\/secure.gravatar.com\/avatar\/85bc072c859f1b0c21b1f8ac82394cf817695e7d0f250d2dcfabf8ce7217b415?s=96&r=g","width":96,"height":96,"caption":"smallake"},"datePublished":"2013-11-12T06:02:40+09:00","dateModified":"2013-11-12T06:18:59+09:00","inLanguage":"ko-KR","mainEntityOfPage":{"@id":"https:\/\/smallake.kr\/?p=13379#webpage"},"isPartOf":{"@id":"https:\/\/smallake.kr\/?p=13379#webpage"},"articleSection":"\uc790\ubcf8\uc2dc\uc7a5\uacfc IT, foxpro, island ECN, \ub9e4\uce6d\uc5d4\uc9c4"},{"@type":"BreadcrumbList","@id":"https:\/\/smallake.kr\/?p=13379#breadcrumblist","itemListElement":[{"@type":"ListItem","@id":"https:\/\/smallake.kr#listItem","position":1,"name":"Home","item":"https:\/\/smallake.kr","nextItem":{"@type":"ListItem","@id":"https:\/\/smallake.kr\/?cat=4#listItem","name":"\uc790\ubcf8\uc2dc\uc7a5\uacfc IT"}},{"@type":"ListItem","@id":"https:\/\/smallake.kr\/?cat=4#listItem","position":2,"name":"\uc790\ubcf8\uc2dc\uc7a5\uacfc IT","item":"https:\/\/smallake.kr\/?cat=4","nextItem":{"@type":"ListItem","@id":"https:\/\/smallake.kr\/?p=13379#listItem","name":"FOXPro\ub85c \ub9cc\ub4e0 \ub9e4\ub9e4\uccb4\uacb0\uc2dc\uc2a4\ud15c"},"previousItem":{"@type":"ListItem","@id":"https:\/\/smallake.kr#listItem","name":"Home"}},{"@type":"ListItem","@id":"https:\/\/smallake.kr\/?p=13379#listItem","position":3,"name":"FOXPro\ub85c \ub9cc\ub4e0 \ub9e4\ub9e4\uccb4\uacb0\uc2dc\uc2a4\ud15c","previousItem":{"@type":"ListItem","@id":"https:\/\/smallake.kr\/?cat=4#listItem","name":"\uc790\ubcf8\uc2dc\uc7a5\uacfc IT"}}]},{"@type":"Person","@id":"https:\/\/smallake.kr\/#person","name":"smallake","image":{"@type":"ImageObject","@id":"https:\/\/smallake.kr\/?p=13379#personImage","url":"https:\/\/secure.gravatar.com\/avatar\/85bc072c859f1b0c21b1f8ac82394cf817695e7d0f250d2dcfabf8ce7217b415?s=96&r=g","width":96,"height":96,"caption":"smallake"}},{"@type":"Person","@id":"https:\/\/smallake.kr\/?author=1#author","url":"https:\/\/smallake.kr\/?author=1","name":"smallake","image":{"@type":"ImageObject","@id":"https:\/\/smallake.kr\/?p=13379#authorImage","url":"https:\/\/secure.gravatar.com\/avatar\/85bc072c859f1b0c21b1f8ac82394cf817695e7d0f250d2dcfabf8ce7217b415?s=96&r=g","width":96,"height":96,"caption":"smallake"}},{"@type":"WebPage","@id":"https:\/\/smallake.kr\/?p=13379#webpage","url":"https:\/\/smallake.kr\/?p=13379","name":"FOXPro\ub85c \ub9cc\ub4e0 \ub9e4\ub9e4\uccb4\uacb0\uc2dc\uc2a4\ud15c | \uadf8\ub300\uc548\uc758\uc791\uc740\ud638\uc218","inLanguage":"ko-KR","isPartOf":{"@id":"https:\/\/smallake.kr\/#website"},"breadcrumb":{"@id":"https:\/\/smallake.kr\/?p=13379#breadcrumblist"},"author":{"@id":"https:\/\/smallake.kr\/?author=1#author"},"creator":{"@id":"https:\/\/smallake.kr\/?author=1#author"},"datePublished":"2013-11-12T06:02:40+09:00","dateModified":"2013-11-12T06:18:59+09:00"},{"@type":"WebSite","@id":"https:\/\/smallake.kr\/#website","url":"https:\/\/smallake.kr\/","name":"\uadf8\ub300\uc548\uc758 \uc791\uc740 \ud638\uc218","description":"\uc0b4\uc544\uc628 \ub0a0\uc758 \ud754\uc801, \uc0b4\uc544\uac08 \ub0a0\uc758 \uae30\ub85d","inLanguage":"ko-KR","publisher":{"@id":"https:\/\/smallake.kr\/#person"}}]},"og:locale":"ko_KR","og:site_name":"\uadf8\ub300\uc548\uc758\uc791\uc740\ud638\uc218 | \uc0b4\uc544\uc628 \ub0a0\uc758 \ud754\uc801, \uc0b4\uc544\uac08 \ub0a0\uc758 \uae30\ub85d","og:type":"article","og:title":"FOXPro\ub85c \ub9cc\ub4e0 \ub9e4\ub9e4\uccb4\uacb0\uc2dc\uc2a4\ud15c | \uadf8\ub300\uc548\uc758\uc791\uc740\ud638\uc218","og:url":"https:\/\/smallake.kr\/?p=13379","article:published_time":"2013-11-11T21:02:40+00:00","article:modified_time":"2013-11-11T21:18:59+00:00","article:publisher":"https:\/\/www.facebook.com\/iumgroup","twitter:card":"summary","twitter:site":"@smallake","twitter:title":"FOXPro\ub85c \ub9cc\ub4e0 \ub9e4\ub9e4\uccb4\uacb0\uc2dc\uc2a4\ud15c | \uadf8\ub300\uc548\uc758\uc791\uc740\ud638\uc218","twitter:creator":"@smallake"},"aioseo_meta_data":{"post_id":"13379","title":"FOXPro\ub85c \ub9cc\ub4e0 \ub9e4\ub9e4\uccb4\uacb0\uc2dc\uc2a4\ud15c | #site_title","description":null,"keywords":[{"label":"foxpro","value":"foxpro"},{"label":"island ECN","value":"island ECN"},{"label":"\ub9e4\uce6d\uc5d4\uc9c4","value":"\ub9e4\uce6d\uc5d4\uc9c4"}],"keyphrases":null,"primary_term":null,"canonical_url":null,"og_title":null,"og_description":null,"og_object_type":"default","og_image_type":"default","og_image_url":null,"og_image_width":null,"og_image_height":null,"og_image_custom_url":null,"og_image_custom_fields":null,"og_video":null,"og_custom_url":null,"og_article_section":null,"og_article_tags":null,"twitter_use_og":false,"twitter_card":"default","twitter_image_type":"default","twitter_image_url":null,"twitter_image_custom_url":null,"twitter_image_custom_fields":null,"twitter_title":null,"twitter_description":null,"schema":{"blockGraphs":[],"customGraphs":[],"default":{"data":{"Article":[],"Course":[],"Dataset":[],"FAQPage":[],"Movie":[],"Person":[],"Product":[],"ProductReview":[],"Car":[],"Recipe":[],"Service":[],"SoftwareApplication":[],"WebPage":[]},"graphName":"","isEnabled":true},"graphs":[],"defaultGraph":"","defaultPostTypeGraph":""},"schema_type":null,"schema_type_options":null,"pillar_content":false,"robots_default":true,"robots_noindex":false,"robots_noarchive":false,"robots_nosnippet":false,"robots_nofollow":false,"robots_noimageindex":false,"robots_noodp":false,"robots_notranslate":false,"robots_max_snippet":null,"robots_max_videopreview":null,"robots_max_imagepreview":"large","priority":null,"frequency":null,"location":null,"local_seo":null,"breadcrumb_settings":null,"limit_modified_date":false,"ai":null,"created":"2020-12-21 05:33:21","updated":"2025-06-05 05:02:05","seo_analyzer_scan_date":null},"aioseo_breadcrumb":"<div class=\"aioseo-breadcrumbs\"><span class=\"aioseo-breadcrumb\">\n\t\t\t<a href=\"https:\/\/smallake.kr\" title=\"Home\">Home<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">&raquo;<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\t<a href=\"https:\/\/smallake.kr\/?cat=4\" title=\"\uc790\ubcf8\uc2dc\uc7a5\uacfc IT\">\uc790\ubcf8\uc2dc\uc7a5\uacfc IT<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">&raquo;<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\tFOXPro\ub85c \ub9cc\ub4e0 \ub9e4\ub9e4\uccb4\uacb0\uc2dc\uc2a4\ud15c\n\t\t<\/span><\/div>","aioseo_breadcrumb_json":[{"label":"Home","link":"https:\/\/smallake.kr"},{"label":"\uc790\ubcf8\uc2dc\uc7a5\uacfc IT","link":"https:\/\/smallake.kr\/?cat=4"},{"label":"FOXPro\ub85c \ub9cc\ub4e0 \ub9e4\ub9e4\uccb4\uacb0\uc2dc\uc2a4\ud15c","link":"https:\/\/smallake.kr\/?p=13379"}],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"","jetpack_shortlink":"https:\/\/wp.me\/p2yULC-3tN","jetpack_sharing_enabled":true,"jetpack_likes_enabled":false,"_links":{"self":[{"href":"https:\/\/smallake.kr\/index.php?rest_route=\/wp\/v2\/posts\/13379","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/smallake.kr\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/smallake.kr\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/smallake.kr\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/smallake.kr\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=13379"}],"version-history":[{"count":0,"href":"https:\/\/smallake.kr\/index.php?rest_route=\/wp\/v2\/posts\/13379\/revisions"}],"wp:attachment":[{"href":"https:\/\/smallake.kr\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=13379"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/smallake.kr\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=13379"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/smallake.kr\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=13379"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}