Methylene blue (MB) was incorporated into titanium phosphate (TiP) after pretreatment of TiP with the gas, n-butyl amine. The dye is strongly retained and not easily leached from the layered host matrix. The adsorbed MB on TiP was used to prepare modified carbon paste electrodes (MCPE), which were studied voltammetrically and in amperometric flow injection (FI) mode for the electrocatalytic oxidation of ascorbic acid (AA). The electrochemical behavior of the immobilized dye was investigated with cyclic voltammetry, at a pH 7.0 phosphate buffer containing 0.5 M KCl, at different potential scan rates. The MB immobilized on the support underwent a quasi-reversible electrochemical redox reaction. A homemade flow-through electrochemical cell with a suitable transparent window for irradiation of the electrode surface was constructed and used for amperometric FI studies. The photoamperometric-FI conditions were optimized for sensitivity and reproducibility at a flow rate of 1.5 mL/min, a transmission tubing length of 25 cm, a sample injection volume of 100 mu L, and a constant applied potential of +100 mV vs. SCE. The calibration curve for AA was linear over the concentration range from 1.0x10(-6) to 2.5x10(-5) mol l(-1) for both amperometric and photoamperometric studies. But the slope of the photoelectrocatalytic FIA procedure was improved about 52% compared with those obtained without irradiation. The results obtained for AA determination in some pharmaceutical products are in good agreement with those obtained using the procedure involving the reaction between triiodide and AA.