Laptops require DC electricity to operate. An external power supply converts AC electricity to DC current. Most require between 25 - 75 Watts to operate but use much less if it's operated conservatively. To determine how much power your laptop consumes, look on the external power supply adapter and multiply the output DC voltage by output current (i.e. 20V DC x 3.5 A = 70W). This is the peak power consumption that is required if the CPU operating at maximum capacity, the LCD screen is at its brightest, all peripherals are in use and the batteries are being recharged. Under normal operating conditions, the power requirement is much less.
A conveniently sized solar panel can typically provide 15 to 80 Watts of DC power under ideal conditions. For best operation, the solar panel should be used to charge a spare battery. Power output can drop dramatically when a cloud obscures the sunlight or if the panel isn't facing directly at the sun. A laptop cannot withstand these power interruptions but a spare battery can be charged from whatever electricity is generated from the available sunlight. Here's how you can harness the sun's energy for your computer:
Another way of handling this is to build a solar-powered backpack - it's easy to do, and a convenient way to carry both your laptop and the solar panels that can be used for re-charging.
If it's critical to run the laptop directly from the solar panel, try to reduce the amount of required power. Unplug the main battery so only the computer is operating, reduce the brightness of the LCD screen and stop all peripherals you're not using such as external hard-drives. Also, save your work often as your laptop will abruptly shut down when not enough current is being supplied by the solar panel (i.e. when a cloud obscures the sun).
Some computers may not tolerate the power that's coming directly from a laptop solar power panel (too many voltage dips and spikes) and may need a DC-DC adaptor to filter the incoming power. The variable voltage and current from the solar panel can be used to charge an intermediate battery which then feeds a smooth and continuous current to the computer. Similar to a UPS backup supply, a small DC-DC adaptor with a charge controller can act hold enough power for 10 - 15 minutes. As long as the sun shines, the solar panel will charge this small battery which in turn will provide clean power to the computer. Select one that is convenient in size (batteries can get heavy) that provides the correct DC output voltage for your laptop.