Sending SMS using sim 900 and Uno

Dear friends,
I am trying to send an sms using arduino Uno and the sim 900 interfaced. I have connected Rx of Sim900 to Tx(pin8) of Uno, Tx of sim900 to Rx(pin7) of Uno, and of course ground to ground of each other. Please help me, I am unable to send the sms. Following is my code:

#include <SoftwareSerial.h>
SoftwareSerial mySerial(7,8); //RX and TX pins to communicate with the GSM module

String mobNumber = "8762451263"; //The number to be texted(some number)
boolean trigger;

void setup(){
  Serial.begin(9600);
  mySerial.begin(9600);
  trigger=false;
  mySerial.println("AT");
}

void loop(){
        if(trigger==false){
          mySerial.println("AT+CMGF=1;");	// Set the Mode as Text Mode
  	  delay(150);
          mySerial.println("AT+CMGS=\"+91"+mobNumber+"\";");	// Specify the Destination number in international format
  	  delay(150);
  	  mySerial.print("First Message");	// Enter the message and append the ldr value
  	  delay(150);
  	  mySerial.write((byte)0x1A);		// End of message character 0x1A : Equivalent to Ctrl+z
  	  delay(50);
  	  mySerial.println();
          delay(50);
          trigger=true;
          }
}

First of all, are you using a SIM900 mounted on a shield? If so, can you provide a link?

Does it connect to the network? If you are using delay() it's common to allow about 20 seconds after the SoftwareSerial.begin to allow connection, handshaking, etc.

Once you have established that it does indeed connect, and if it still doesn't work, put a Serial.println() after each AT command to see if that gives you annyclues as to where the problem lies.

I have bought SIM900 module and arduino Uno separately . I have connected each other with the above pin numbers.
I have code by which I can see details in the serial monitor(ctrl+shift+m) if someone calls on the number, but somehow sms business is not working.

I think you should have a look at this link, they have shared in detail how to connect arduino with sim900 without using the arduino library, simply by sending serial commands.