Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9140599
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T09:32:15+00:00 2026-06-17T09:32:15+00:00

I have a function: function createWFS(){ //WMS wms_proj = new OpenLayers.Projection(EPSG:900913); //WFS SS=new OpenLayers.Strategy.Save();

  • 0

I have a function:

    function createWFS(){
    //WMS
    wms_proj = new OpenLayers.Projection("EPSG:900913");    
    //WFS
    SS=new OpenLayers.Strategy.Save();
    FS=new OpenLayers.Strategy.Filter({filter:Ffilter});
    var myStyle = OpenLayers.Util.extend({},
        OpenLayers.Feature.Vector.style['default']);
    myStyle.strokeWidth = 1.5;
    myStyle.strokeColor = "#ff0000";
    myStyle.fillOpacity = 0.1;

    myVecLayer= new OpenLayers.Layer.Vector("Редактируемый участок");
    myVecLayer.projection=wms_proj;
    app.mapPanel.map.addLayers([myVecLayer]);
    myVecLayer.visibility=false;

    //Стор для зума
    zoom_tab = new GeoExt.data.FeatureStore({
        layer: myVecLayer,
        fields: [
            {name: 'id', type: 'int'},
            {name: 'filedata', type: 'String'}
        ],
        proxy: new GeoExt.data.ProtocolProxy({
            protocol: new OpenLayers.Protocol.HTTP({
                //url: "/geoserver/ows?service=WFS&request=GetFeature&typeName=mrsk:parcels_temp&srsName=EPSG:4326&outputFormat=GML2",
                url: "/geoserver/ows?service=WFS&request=GetFeature&typeName=cite:parcels_temp&srsName=EPSG:4326&outputFormat=GML2",
                format: new OpenLayers.Format.GML()
            })
        }),
        autoLoad: true
    });
    zoom_store=zoom_tab;
}

You see that this function create WFS Layer and GeoExt.FeatureStore. I dont know how long function will work.
So now i call this function and want ot wait function result before make next code. How to make this?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-17T09:32:15+00:00Added an answer on June 17, 2026 at 9:32 am

    Just pass it your own callback:

    function createWFS(callback) {
        //WMS
        ...
        if (callback)
            callback();
    }
    
    
    function Main() {
        createWFS(NextStep);
    }
    
    function NextStep() {
        //stuff here
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a Parallel foreach function that creates a new instance of a class,
I am new to unit testing for web applications I have a function which
I have written a function that creates a barplot. I would like to save
I'm new about parallel computing in matlab. I have a function which creates a
I have a function that creates time intervals between two time marks. The function
I have a function that creates zip files when passed an array of files
I have a function that creates a course. I am trying to get the
I have a function which creates an object of values, but im getting this
I have a function that creates a 2D vector void generate(int n) { vector<
I have a Matlab function that creates a cell array with matrixes inside. It

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.