Ethernet shield can't connect to web

it worked!!!! :smiley: it has really worked!!
Thank you very much SurferTim! I do appreciate your help :slight_smile:

the code now for people who are trying to do the same, with Arduino & Ethernet shield, laptop, and 3G dongle (huawei E1750), since I found the question in net but no answer..
The Dongle has its dynamic addresses. I just added a static IP address 192.168.1.170 in order to integrate it in my local network.

#include <SPI.h>
#include <Ethernet.h>

// Enter a MAC address for your controller below.
// Newer Ethernet shields have a MAC address printed on a sticker on the shield
byte mac[] = { 0xDE, 0xAD, 0xBE, 0xEF, 0xFE, 0xED };
byte ip[] = {192,168,1,177}; //Arduino
byte myDns[] = {192,168,1,1}; //Laptop Ethernet interface, myDns cause the "dns" wasn't recognized
byte gateway[] = {192,168,1,1}; //Laptop Ethernet interface
byte subnet[] = {255,255,255,0};

//IPAddress server(74,125,232,128);  // numeric IP for Google (no DNS)
char server[] = "www.google.com";    // name address for Google (using DNS)

EthernetClient client;

void setup() {
 // Open serial communications and wait for port to open:
  Serial.begin(9600);
   
  // start the Ethernet connection:
Ethernet.begin(mac, ip, myDns, gateway, subnet);  // give the Ethernet shield a second to initialize:
  delay(60000);
  Serial.println("connecting...");

  // if you get a connection, report back via serial:
  int ret= (client.connect(server, 80));
 if (ret ==1) {
    Serial.println("connected");
    // Make a HTTP request:
    client.println("GET /search?q=arduino HTTP/1.1");
    client.println("Host: www.google.com");
    client.println("Connection: close\r\n");
    client.println();
  } 
  else {
    // kf you didn't get a connection to the server:
    Serial.println("connection failed");
    Serial.print(ret,DEC);
  }
}

void loop()
{
  // if there are incoming bytes available 
  // from the server, read them and print them:
  if (client.available()) {
    char c = client.read();
    Serial.print(c);
  }

  // if the server's disconnected, stop the client:
  if (!client.connected()) {
    Serial.println();
    Serial.println("disconnecting.");
    client.stop();

    // do nothing forevermore:
    while(true);
  }
}