Google Map with vb.net - vb.net

I am creating an application in vb where I need to attach the Google map with the application.
I have used the webbrowser for this and have added "http://maps.google.com/.. in the query address. This seems to work fine hoever my problem is I dnt want the complete google map webpage to be shown in the from, I just want the map portion to appear in the form. This is something which am not able to achieve. Could you ppplease help me on this? Thanks. Thanks a lot..

You could embed the Google Map onto some webpage of yours and then direct the WebBrowser to this web page.

Related

Modifying photosphere on website thing

What i am trying to do is to use a photosphere on my website so that it shows up on full screen as a website cover page. The problem is the the code to embed a photosphere in a webpage given here by google
https://developers.google.com/photo-sphere/web/
lets only the photosphere size to be hardcoded as
displaysize="600,400"
what ever the values but its still hardcoded. What i want is that it gets adjusted to the screen of the user and gets displayed in the whole browser window. Any one got an idea how to pull it off? I didn't find any stuff about 'photosphere on web' other than the google link i gave above.
Indeed the API is currently designed to take static values. I think it's a good point that users might want to set the dimensions to 100% and let it resize dynamically.
I put it on the TODO list and will try to get to it shortly.
In the meantime, one work around is the following: After the viewer loads you will find an iframe on the page which contains it. You can change it's dimensions dynamically to your liking and the viewer should adapt.
The API provided by Google wraps the whole photosphere in layers of iFrames.
You can use the API to request a certain photosphere but only use the response to parse it for the values you need. Then you create your own request and the result can be shown fullscreen.
An example link is this
I created this link dynamically from the JSON response from the elements
media$group media$content 0 url
Hope it helps.
Can't you take the raw image and just use webgl to project it on the inside of a sphere?

Google Search API with joomla

I would like to implement the google search API in a joomla site. What would be the best way to pass the search query and show the results inside of my templates content area. Making a custom component or there is a lighter workaround?
You could always try RokAjaxSearch as I believe this has the ability to display results from Google. And above all, it's Ajax, therefore doesn't refresh the page.
Hope this helps

display html in xaml

I wasted few hours for looking the answer and I'm very sad cause I didn't find anything usefull. I have a CMS in cloud and it provides content for diffrent devices like www site and my new windows store application.
I want to use html formating. I've already created app in c# and xaml and I'm wondering how can I display html
I was happy cause I found http://nuget.org/packages/RichTextBlock.Html2Xaml but I can't make it work. I get blank page. No text, no error, no nothing.
Can someone pls tell me how can I display html in my app ?
Use a WebView/WebViewBrush or use HTML Agility Pack and implement the styles/rendering yourself.
In WinRt app you can display html code by some ways:
Using WebView with it's NavigateToString("html content")
Using WebViewBrush and displaying it in rectangle
If you had your .html file local - you can open it with myWebview.Navigate(new Uri("ms-appx-web:///" + myPath));
You can make a screenshot of webpage by the method wich I describe here and open it as a picture.
For more info, see the WebView control sample

Find a link inside iframe in webbrowser control in VB.net

I want to find a url webbrowser control inside iframe.
1) my webbrowsercontrol opena url
2)that url has one iframe inside it
3) That Iframe has a link which I want to grab programmatically using vb.net
At any point of time use webBrowser1.Url.ToString() to get the URL of the current open link.
You can get the html code of the open url by using webBrowser1.DocumentText. Once you have the html code use string manipulation to find the "iframe src" value.
This can be abit complicated as you migt not know how may iframes you need to handle.
As well there are some limitations for the FRAME elements according to HtmlWindow.WindowFrameElement Property
You cannot access a FRAME elements or the FRAME's document if the
FRAME is in a different zone than the FRAMESET that contains it. For a
full explanation, see About Cross-Frame Scripting and Security.
Actually, all you need to do is this...
Msgbox Webbrowser1.document.frames(0),getelementbyid("linkTagId").href
This will show you the href of the link, don't bother wasting time with string manipulation.
Of course, you can loop through the frames and links as well using the .length properties in a for loop.
Also, there are ways to bypass the cross-frame security issues since you are running the code in an exe, there are examples online, just search for "bypass cross-frame security webbrowser control" in google without the quotes.
If you need more help with these let me know as I can tell you how. Remember the cross frame stuff only need bypassing if the parent domain name and iframe domain name are different (not subdomains though, they can be different no problems).
Let me know mate :)

How do I get a Captcha off a website and display it in a picturebox using VB.NET?

In Visual Basic .NET is there a way to access a website/signup page and then get the Captcha and load it into a picturebox? How would I do it?
From your question, I can't tell if you are looking for a captcha plug-in or use a plug-in from another site. If you're looking for a plugin, try Recaptcha.
UPDATE
Trying to pull a the captcha image off of a site could be done in two ways, but it the captcha rotation were done correctly, it would no do you any good to be able to pull it off.
One way would be to just right-click on the image and reference that URL in your code. However, as stated previously, this would not be that reliable. The service that generates the image would rotate, and the image URL would be different on every refresh. In other words, the copied URL would only be good for the one time you copied/captured it via right-click or whatever. If the URL did not rotate, then that would be a security issue for the site which is why the image source is different on each refresh.
Another way would be to make a direct request to the page, scrape the content for the captcha image's source, and pull the source from the parsed content. The code for this would be fairly specific per page, and, with my limited knowledge, I can't think of a way to make a generic application to do so.
I don't know why you would want to do what you are wanting to do, unless this is a homework assignment, or you are up to no good.
Depends on the captcha service the website uses.
If the site uses reCAPTCHA, you would probably need to look for the image tag that has id "recaptcha_challenge_image" and display that image tag in a web browser control.
Here is the demo page I found: http://www.google.com/recaptcha/demo/. If the captcha itself is in a frame (or iframe), you will need to check the code in the frame itself.