Jump to content
Sign in to follow this  
miketh2005

_IECreateEmbedded without scrollbars?

Recommended Posts

miketh2005

I didn't know what forum to post in:

Hi. This is my code:

#include <IE.au3>
#include <ButtonConstants.au3>
#include <EditConstants.au3>
#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>
#include <Constants.au3>
#include <GuiConstants.au3>

_IEErrorHandlerRegister()

$oIE = _IECreateEmbedded()

Opt("TrayOnEventMode", 1)
Opt("TrayMenuMode", 1)
Opt("GUIOnEventMode", 1)

#region ### START Koda GUI section ### Form=c:\users\mike\documents\chatboxappform.kxf
$chatboxappform = GUICreate("CheatingNetwork Subscriber Chatbox Desktop Application", 578, 385, 199, 258)
GUISetIcon("C:\Users\Mike\Downloads\favicon(2).ico")
GUISetFont(10, 400, 0, "Impact")
$Login = GUICtrlCreateButton("Login", 276, 125, 75, 25, $WS_GROUP)
GUICtrlSetOnEvent(-1, "chatbox")
$usernamelabel = GUICtrlCreateLabel("Username:", 146, 3, 63, 21)
GUICtrlSetColor(-1, 0xFFFFFF)
GUICtrlSetBkColor(-1, 0x000000)
$passwordlabel = GUICtrlCreateLabel("Password:", 362, 3, 61, 21)
GUICtrlSetColor(-1, 0xFFFFFF)
GUICtrlSetBkColor(-1, 0x000000)
GUICtrlCreateInput("", 146, 22, 121, 25)
GUICtrlCreateInput("", 362, 22, 121, 25)
$madeby = GUICtrlCreateLabel("Made by miketh2005", 2, 0, 117, 21)
GUICtrlSetColor(-1, 0xFFFFFF)
GUICtrlSetBkColor(-1, 0x000000)
$Pic1 = GUICtrlCreatePic("C:\Users\Mike\Desktop\cheatingnetworklogo.jpg", 0, 0, 578, 153, BitOR($SS_NOTIFY, $WS_GROUP, $WS_CLIPSIBLINGS))
TraySetClick("16")
$Launch = TrayCreateItem("Launch")
TrayItemSetOnEvent($Launch, "show")
TraySetOnEvent($TRAY_EVENT_PRIMARYDOUBLE, "show")
TraySetIcon("C:\Users\Mike\Downloads\favicon(2).ico", $Launch)
GUISetOnEvent($GUI_EVENT_MINIMIZE, "hide")
GUISetOnEvent($GUI_EVENT_CLOSE, "exxit")
GUISetState(@SW_SHOW)
#endregion ### END Koda GUI section ###

While 1
    $nMsg = GUIGetMsg()
    Switch $nMsg
        Case $GUI_EVENT_CLOSE
            GUIDelete()
            Exit
    EndSwitch
WEnd

Func chatbox()
    $GUIActiveX = GUICtrlCreateObj($oIE, 0, 153, 0, 232)
    _IENavigate($oIE, "http://www.yahoo.com")
    $oIE.document.body.scroll = "no"
    $oIE.document.body.style.border = "0px"
EndFunc   ;==>chatbox

Func hide()
    GUISetState(@SW_HIDE)
EndFunc   ;==>hide

Func show()
    GUISetState(@SW_SHOW)
EndFunc   ;==>show

Func exxit()
    Exit
EndFunc   ;==>exxit

When you press "Login", the ie window is suppose to imbed, but I don't want scrollbars on the IE window.

$oIE.document.body.scroll = "no"

$oIE.document.body.style.border = "0px"

Isn't working :/

Thanks.

Share this post


Link to post
Share on other sites
Melba23

miketh2005,

I didn't know what forum to post in:

Whichever of the forums you decide - but do not double post it! :blink:

M23


Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind._______My UDFs:

Spoiler

ArrayMultiColSort ---- Sort arrays on multiple columns
ChooseFileFolder ---- Single and multiple selections from specified path treeview listing
Date_Time_Convert -- Easily convert date/time formats, including the language used
ExtMsgBox --------- A highly customisable replacement for MsgBox
GUIExtender -------- Extend and retract multiple sections within a GUI
GUIFrame ---------- Subdivide GUIs into many adjustable frames
GUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView items
GUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeView
Marquee ----------- Scrolling tickertape GUIs
NoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxes
Notify ------------- Small notifications on the edge of the display
Scrollbars ----------Automatically sized scrollbars with a single command
StringSize ---------- Automatically size controls to fit text
Toast -------------- Small GUIs which pop out of the notification area

 

Share this post


Link to post
Share on other sites
miketh2005

O, I'll stick with this topic, then :blink:

Anyone know? ;)

Share this post


Link to post
Share on other sites
miketh2005

Daily bump.

Share this post


Link to post
Share on other sites
DaleHohm

Try to figure out what makes your code different than this example that works:

#include <GUIConstantsEx.au3>
#include <IE.au3>

Local $oIE, $hGUI, $Ctrl

$oIE = _IECreateEmbedded()
$hGUI = GUICreate("Title", 400, 400)
$Ctrl = GUICtrlCreateObj($oIE, 10, 10, 380, 380)

GUISetState()
_IENavigate($oIE, "http://www.yahoo.com")
$oIE.document.body.scroll = "no"

Do
Until GUIGetMsg() = $GUI_EVENT_CLOSE

GUIDelete()

Dale


Free Internet Tools: DebugBar, AutoIt IE Builder, HTTP UDF, MODIV2, IE Developer Toolbar, IEDocMon, Fiddler, HTML Validator, WGet, curl

MSDN docs: InternetExplorer Object, Document Object, Overviews and Tutorials, DHTML Objects, DHTML Events, WinHttpRequest, XmlHttpRequest, Cross-Frame Scripting, Office object model

Automate input type=file (Related)

Alternative to _IECreateEmbedded? better: _IECreatePseudoEmbedded  Better Better?

IE.au3 issues with Vista - Workarounds

SciTe Debug mode - it's magic: #AutoIt3Wrapper_run_debug_mode=Y Doesn't work needs to be ripped out of the troubleshooting lexicon. It means that what you tried did not produce the results you expected. It begs the questions 1) what did you try?, 2) what did you expect? and 3) what happened instead?

Reproducer: a small (the smallest?) piece of stand-alone code that demonstrates your trouble

Share this post


Link to post
Share on other sites
miketh2005

Try to figure out what makes your code different than this example that works:

#include <GUIConstantsEx.au3>
#include <IE.au3>

Local $oIE, $hGUI, $Ctrl

$oIE = _IECreateEmbedded()
$hGUI = GUICreate("Title", 400, 400)
$Ctrl = GUICtrlCreateObj($oIE, 10, 10, 380, 380)

GUISetState()
_IENavigate($oIE, "http://www.yahoo.com")
$oIE.document.body.scroll = "no"

Do
Until GUIGetMsg() = $GUI_EVENT_CLOSE

GUIDelete()

Dale

_IENavigate($oIE, "http://www.yahoo.com")

Works, but:

_IENavigate($oIE, "http://www.cheatingnetwork.net")

Doesn't :S :blink:

Share this post


Link to post
Share on other sites
DaleHohm

I don't see anything obvious... must be something tricky in the javascript on the site (or possibly in the CSS).

Dale


Free Internet Tools: DebugBar, AutoIt IE Builder, HTTP UDF, MODIV2, IE Developer Toolbar, IEDocMon, Fiddler, HTML Validator, WGet, curl

MSDN docs: InternetExplorer Object, Document Object, Overviews and Tutorials, DHTML Objects, DHTML Events, WinHttpRequest, XmlHttpRequest, Cross-Frame Scripting, Office object model

Automate input type=file (Related)

Alternative to _IECreateEmbedded? better: _IECreatePseudoEmbedded  Better Better?

IE.au3 issues with Vista - Workarounds

SciTe Debug mode - it's magic: #AutoIt3Wrapper_run_debug_mode=Y Doesn't work needs to be ripped out of the troubleshooting lexicon. It means that what you tried did not produce the results you expected. It begs the questions 1) what did you try?, 2) what did you expect? and 3) what happened instead?

Reproducer: a small (the smallest?) piece of stand-alone code that demonstrates your trouble

Share this post


Link to post
Share on other sites
PsaltyDS

Not knowing it was duplicate, I replied in the other copy of this topic. For which miketh2005 gets -2 to karma. :blink:

At any rate, the scroll bars come back as soon as you navigate to a new page. The solution I posted in the other topic was an event handler for DWebBrowserEvents2::NavigateComplete2 that reapplies the setting.

Didn't see a way to make it stick, and I think it would be more annoying than helpful if you could, anyway.

;)


Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×