Ya thanks Nicolas ,but the point is I don't want to insert my newly created
google spreadsheet to google base....else I want to publish it after I have
created through java client library....so that it is available to general
public.......I show u the code ..............Icebackhaz...plz u also have a
look............

1) Creation of google spreadsheet.................

   DocsService docsService= new DocsService("Create Document/Spreadsheet");
   URL documentListFeedUrl=new URL("http://"; + "docs.google.com
"+"/feeds/documents/private/full");
   URL cellFeedUrl=null;


   docsService.setUserCredentials("username","password");
   com.google.gdata.data.docs.SpreadsheetEntry newDocument=new
com.google.gdata.data.docs.SpreadsheetEntry();

   newDocument.setTitle(new PlainTextConstruct("spreadSheet Name xyz"));
  docsService.insert(documentListFeedUrl, newDocument);  // this will create
new spreadsheet in google

// now search for spreadsheet i have created..............

    SpreadsheetFeed
feed=service.getFeed(factory.getSpreadsheetsFeedUrl(),SpreadsheetFeed.class);
     List entries=feed.getEntries();

    for(int i=0;i<entries.size();i++)
           {
                 SpreadsheetEntry
spreadEntry=(SpreadsheetEntry)entries.get(i);

if(spreadEntry.getTitle().getPlainText().equalsIgnoreCase("spreadSheet Name
xyz"))
                       {
                //
createWorksheet(service,spreadEntry,worksheetName);
// my fuction to create new worksheet, here not required

                 String
spreadSheetID=spreadEntry.getId().substring(spreadEntry.getId().lastIndexOf('/')+1);

                       }
            }


now I want to publish this spreadsheet with Id I got...into google....note
it is created in my private account...but I want to publish ( say as a web
page )...so that it available to general public.

Note I want to publish this via java client library api methods only...not
manually going to share and publish as web page......because the generation
of spreadsheets is through code...and each time I have to manually publish
it......so If clear then plz help....otherwise u can ask me for more
clearity in code.................




On 11/26/08, Nicolas (Google) <[EMAIL PROTECTED]> wrote:
>
>
> Hi Uday,
>
> Please read our Java developer's guide, it explains how to
> authenticate and insert new Items in Google base:
>
> http://code.google.com/apis/base/docs/2.0/developers_guide_java.html#inserting
> You will need to "itemize" your Spreadsheet, for example each line of
> your spreadsheet would be an item. and each item's attribute would
> match your spreadsheet's column.
>
> If you only wants to publish/share your spreadsheet as a whole, you
> should look at the Google Docs Data API, which should allow you to
> just 'upload' and then publish your spreadsheet as a Google Document.
> To learn more about this visit the Google Docs API Forum:
> http://groups.google.com/group/Google-Docs-Data-APIs
>
> Thanks
> Nicolas
>
> On Nov 26, 3:36 pm, icebackhaz <[EMAIL PROTECTED]> wrote:
> > I'm really on familiar with the base api, but what has you stuck?
> > Just the final push to google apps?  Your credentials all in order?
> > What do you have so far in you program?
> >
> > On Nov 26, 8:28 am, "uday singh rawat" <[EMAIL PROTECTED]>
> > wrote:
> >
> > > I am trying to share or publish spreadsheet which i have created
> through
> > > java client library...so that anyone can access that.....but I want to
> > > achieve this only through java client library ...not manually going to
> share
> > > then publish as web...or else......
> >
> > > thanks for asking .......now plz help,...
> >
> > > On 11/26/08, icebackhaz <[EMAIL PROTECTED]> wrote:
> >
> > > > Are you trying to send a spreadsheet of items you would like listed
> at
> > > > googlebase or are you trying to share a spreadsheet?
> >
> > > > On Nov 24, 4:24 am, "uday.singh.rawat" <[EMAIL PROTECTED]>
> > > > wrote:
> > > > > Hi friends,
> >
> > > > > I have some queries regarding publishing spreadsheet into google
> > > > > through java client library.
> >
> > > > > First of all can anyone tell me how to get authorized for inserting
> > > > > data into feed/public/....url
> >
> > > > > second...where and how can i publish my google spreadsheet in
> google
> > > > > through java client library......
> >
> > > > > Or can anyone just tell me the feed url where to send insert
> request
> > > > > to publish the spreadsheets  ....
> >
> > > > > Thanks......response required asap.....
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Base Data API" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/Google-Base-data-API?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to