Search Results

Search found 256 results on 11 pages for 'harpyar singh'.

Page 7/11 | < Previous Page | 3 4 5 6 7 8 9 10 11  | Next Page >

  • How to get dynamically session object in struts2

    - by Sujeet Singh
    I am trying to get dynamically session object in struts2 application. <s:if test="%{#session['resToken'].bookingType == 1}"> resToken can be get by <s:property value="%{resToken}">.. But I can't write <s:property> within <s:if test=""> its giving me error of double quotes.. org.apache.jasper.JasperException: /WEB-INF/jsp/booking/banquet/guest-Info-View.jsp(150,40) Unterminated &lt;s:if tag

    Read the article

  • Google Map key in Android?

    - by Amandeep singh
    I am developing an android app in which i have to show map view i have done it once in a previous app but the key i used in the previous is not working int his app . It is just showing a pin in the application with blank screen. Do i have to use a different Map key for each project , If not Kindly help me how can i use my previous Key in this. and also I tried generating a new key but gave the the same key back . Here is the code i used public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.map); btn=(Button)findViewById(R.id.mapbtn); str1=getIntent().getStringExtra("LATITUDE"); str2=getIntent().getStringExtra("LONGITUDE"); mapView = (MapView)findViewById(R.id.mapView1); //View zoomView = mapView.getZoomControls(); mapView.setBuiltInZoomControls(true); //mapView.setSatellite(true); mc = mapView.getController(); btn.setOnClickListener(this); MapOverlay mapOverlay = new MapOverlay(); List<Overlay> listOfOverlays = mapView.getOverlays(); listOfOverlays.clear(); listOfOverlays.add(mapOverlay); String coordinates[] = {str1, str2}; double lat = Double.parseDouble(coordinates[0]); double lng = Double.parseDouble(coordinates[1]); p = new GeoPoint( (int) (lat * 1E6), (int) (lng * 1E6)); mc.animateTo(p); mc.setZoom(17); mapView.invalidate(); //mp.equals(o); } @Override protected boolean isRouteDisplayed() { // TODO Auto-generated method stub return false; } class MapOverlay extends com.google.android.maps.Overlay { @Override public boolean draw(Canvas canvas, MapView mapView, boolean shadow, long when) { super.draw(canvas, mapView, shadow); Paint mPaint = new Paint(); mPaint.setDither(true); mPaint.setColor(Color.RED); mPaint.setStyle(Paint.Style.FILL_AND_STROKE); mPaint.setStrokeJoin(Paint.Join.ROUND); mPaint.setStrokeCap(Paint.Cap.ROUND); mPaint.setStrokeWidth(2); //---translate the GeoPoint to screen pixels--- Point screenPts = new Point(); mapView.getProjection().toPixels(p, screenPts); //---add the marker--- Bitmap bmp = BitmapFactory.decodeResource(getResources(), R.drawable.pin); canvas.drawBitmap(bmp, screenPts.x, screenPts.y-50, null); return true; } Thanks....

    Read the article

  • Non-Git Github?

    - by Mihir Singh
    This is probably a really weird question... but is there a non-git Github? I want a place to post my projects and share my code (like Github) but I don't want to have to works with versions, commits, etc. I don't like having to create a link between my folder and my git repo and then push the changes etc. In addition, I don't want to have to have a local copy to create or add files; I can edit existing files in Github, but to create or add files, I have to do it locally and then commit and push. I'm not sure if this is the best site to ask on, but I figured someone might have the answer. Thanks in advance.

    Read the article

  • WPF,XAML: How to set the ZIndex of a particular control to the topmost.

    - by Sudhakar Singh
    how do i set any control to the topmost of the screen. For e.g. i have a textblock in a datatemplate or a hierarchichal data template..etc... now i would like to set this textblock to the topmost on mouseover. Setting the Grid.ZIndex value to 1 in the trigger for IsMouseOver doesn't work many times. In order to do that i set the ZIndex value for all the contols to -1 in the window. it worked in one scenario but doesn't work other times. If anyone can get me the details of ZIndex and how to set the control to the topmost without worrying about the other controls, it would be of great help. Note: setting the value of ZIndex to a higher value e.g. 99999 also doesn't work.

    Read the article

  • How to upload a file from app in VC++ 6 to a web server?

    - by Arvind Singh
    I have an application in VC++ 6 (not MFC) , feature requires it to upload a file to a web server on regular basis. Web server is under our control, anonymous upload scripts/page are already setup that would accept a file manually. How to program in VC++ 6 to upload? which classes to use? I understand it is much possible with smtp and ftp but how through http?

    Read the article

  • How to send html content in the Email body

    - by Shalini Singh
    Hi, i am using android code with html tag.. but in mail getting same html tag please help me how can i send html link ... the code is giving below Intent emailIntent = new Intent(android.content.Intent.ACTION_SEND); emailIntent.setType("text/html"); emailIntent.putExtra(android.content.Intent.EXTRA_EMAIL, new String[] {"[EMAIL PROTECTED]"}); emailIntent.putExtra(android.content.Intent.EXTRA_SUBJECT, "Subject"); emailIntent.putExtra(android.content.Intent.EXTRA_TEXT, "Example"); context.startActivity(Intent.createChooser(emailIntent, "Send mail..."));

    Read the article

  • To remove garbage characters from a string using regex...

    - by Harjit Singh
    Hi I want to remove characters from a string other then a-z, and A-Z. Created following function for the same and it works fine. public String stripGarbage(String s) { String good = "ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789abcdefghijklmnopqrstuvwxyz"; String result = ""; for (int i = 0; i < s.length(); i++) { if (good.indexOf(s.charAt(i)) >= 0) { result += s.charAt(i); } } return result; } Can anyone tell me a better way to achieve the same. Probably regex may be better option. Regards Harry

    Read the article

  • Question regarding common class

    - by Rocky Singh
    I have following two classes: public class A : System.Web.UI.WebControls.Button { public virtual string X { get { object obj = ViewState["X"]; if (obj != null) return (string)obj; return null; } set { ViewState["X"] = value; } } protected override void OnLoad(EventArgs e) { X=2; } } and public class B : System.Web.UI.WebControls.TextBox { public virtual string X { get { object obj = ViewState["X"]; if (obj != null) return (string)obj; return null; } set { ViewState["X"] = value; } } protected override void OnLoad(EventArgs e) { X=2; } } As you must be seeing the class A and B have exactly the same code , my question is how can I make a common class for it and use these two classes.

    Read the article

  • What is the best approach to manipulate assets in Drupal from .Net application?

    - by Amandeep Singh
    I'm beginning work on a project that will access a Drupal site to create nodes on the site. This includes file uploading, as the project is to allow people to upload pictures en mass to a Drupal site with minimal ado. Note that my application is written in .Net. What I would like to know is the best approach to achieve the same? Based on initial research it looks like there are several options: 1. XML-RPC 2. Custom PHP module deployed in drupal. But, what is the way to invoke it from .Net? 3. Use a cron job to pick up the files from a watch folder. And add a cron_hook in my module to deploy the file.

    Read the article

  • Is rand() predictable in C++

    - by singh
    When I run the below program I always get the same values each time. Is rand not a true random function? int main() { while(1) { getch(); cout<<rand()<<endl; } } In each run I am getting the below values. 41 18467 6334 26500 19169 15724 ......

    Read the article

  • is rand() is perdicatable in C++

    - by singh
    Hi When i run below program i always get same values each time..Is rand is not a true random function. int main() { while(1) { getch(); cout<<rand()<<endl; } } In each run i am getting below values. 41 18467 6334 26500 19169 15724 ......

    Read the article

  • Any Sercurity issues in ajax dll

    - by lokendra singh
    Hi Friends I am using ajax dll in my application for smooth working but i have some doubt in my mind ? is there any security problem in server when we are using ajax dll in my application. means any one can missuse the application because we are using public memthods in ajax dll. Any one suggest me, thanks in advance Lokendra

    Read the article

  • how access value of array list on Struts framework by properties file

    - by singh
    arraylist.add(new ListItem("Activity1", "ActivityName1")); suppose ActivityName1 value store in properties file to provide locale feature. now how can i access the value of Activity1 key that associate to ActivityName1 value on jsp ( ActivityName1 corresponds to a properties file value) by using Struts. i want to find the ActivityName1 value that store in properties file by using the Activity1 key in Struts framework.

    Read the article

  • Replace relative urls to absolute

    - by Rocky Singh
    I have the html source of a page in a form of string with me: <html> <head> <link rel="stylesheet" type="text/css" href="/css/all.css" /> </head> <body> <a href="/test.aspx">Test</a> <a href="http://mysite.com">Test</a> <img src="/images/test.jpg"/> <img src="http://mysite.com/images/test.jpg"/> </body> </html> I want to convert all the relative paths to absolute. I want the output be: <html> <head> <link rel="stylesheet" type="text/css" href="http://mysite.com/css/all.css" /> </head> <body> <a href="http://mysite.com/test.aspx">Test</a> <a href="http://mysite.com">Test</a> <img src="http://mysite.com/images/test.jpg"/> <img src="http://mysite.com/images/test.jpg"/> </body> </html> Note: I want only the relative paths to be converted to absolute ones in that string. The absolute ones which are already in that string should not be touched, they are fine to me as they are already absolute. Can this be done by regex or other means?

    Read the article

  • Windows Phone 8 Panorama SelectionIndex not changing on swiping through items

    - by Balraj Singh
    I have created Panorama control and binded PanoramaItem from ItemSource. Now when i am changing the selected Panoramaitem by swiping over them the Selected index is always set to -1. I dont know what wrong i am doing while implementation. neither selectionchange event is getting fired. Code: <phone:Panorama Grid.Row="1" Visibility="Visible" x:Name="PnrVwMainNews" ItemsSource="{Binding ParnormaItemsData}" ItemContainerStyle="{StaticResource PanoramaContainerItemStyle}"> <phone:Panorama.ItemTemplate> <DataTemplate> <!-- Panorma Items Template --> <Controls:DynamicContentControl Content="{Binding UsrCntrlDynamic}" /> </DataTemplate> </phone:Panorama.ItemTemplate> </phone:Panorama> PanoramaContainerItemStyle <Style x:Key="PanoramaContainerItemStyle" TargetType="phone:PanoramaItem"> <Setter Property="HorizontalContentAlignment" Value="Stretch" /> <Setter Property="VerticalContentAlignment" Value="Stretch" /> <Setter Property="Template"> <Setter.Value> <ControlTemplate TargetType="phone:PanoramaItem"> <Grid Background="{TemplateBinding Background}" Margin="12,0,0,0"> <Grid.RowDefinitions> <RowDefinition Height="auto" /> <RowDefinition Height="*" /> </Grid.RowDefinitions> <ContentPresenter Content="{TemplateBinding Content}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" Margin="{TemplateBinding Padding}" Grid.Row="1" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" /> </Grid> </ControlTemplate> </Setter.Value> </Setter> </Style>

    Read the article

< Previous Page | 3 4 5 6 7 8 9 10 11  | Next Page >