Jump to content
Trioxide

no auto login

Recommended Posts

Have Geovision ver 7 with the GV-800 card in my Windows XP system. Using LanMpegView.htm file to access my cameras on the WebCam Server. But I can not get it to autologin even though I use the command they have in the htm file of . What I end up have to do is clicking on the ShowSystemMenu button, select Change Server and then click on the OK button and it will log in and I can see my camera. How can I get it so when I open the htm file it auto logins?

Share this post


Link to post
Share on other sites

Have tried SimpleVue Geo and that works but I am trying to incorporate this into my CQC application and do not want a seperate window popping up which is what I get with this application. Want it embedded into the html code so I can display it in my IV, Interface Viewer. Any ideas why autologin would not work?

Share this post


Link to post
Share on other sites

In this order:

 

DisablePWD = True

UserName = MyUserName

Password = MyPassword

AutoLogin = True

 

CommandPort = MyCommandPort <- OPTIONAL

DataPort = MyDataPort <- OPTIONAL

AudioDataPort = MyAudioPort <- OPTIONAL

 

IpAddress = MyIPAddress

BandWidth = LAN <- LAN or MODEM

ChangeQualityX 2 <-320x240 - 2=low, 1=mid, 0=high <- OPTIONAL

ChangeCamX 0 <-camera number 0-15

 

PlayX

Share this post


Link to post
Share on other sites

since im feeling generous today .. right before I goto the dentist LOL ..

 

place this in a HTML file and change the IP and user and pass etc ..

 

---------------- HTML REQUIRES IE as it is VBSCRIPT METHOD -------------

<html>
<head>

<script language="JavaScript">

// CONNECT AND PLAY
// add sites here

function PlayX(){

   // ID, Control, Camera, IP, User, Pass, DataPort, CommandPort, AudioPort, BandWidth, Quality

   LiveXPlay (1, document.WebCamX1, 0, "10.10.10.10","demo", "demo", "4550", "5550", "6550", "LAN", 0, "480", "360")
   LiveXPlay (2, document.WebCamX2, 2, "10.10.10.10","demo", "demo", "4550", "5550", "6550", "LAN", 0, "480", "360")
   LiveXPlay (3, document.WebCamX3, 12, "24.244.132.76","demo", "demo", "4550", "5550", "6550", "LAN", 0, "480", "360")
   LiveXPlay (4, document.WebCamX4, 10, "24.244.132.76","demo", "demo", "4550", "5550", "6550", "LAN", 0, "480", "360")
}

// DISCONNECTS
// add above sites here also

function DestroyX(){   
   LiveXStop (document.WebCamX1)
   LiveXStop (document.WebCamX2)
   LiveXStop (document.WebCamX3)
   LiveXStop (document.WebCamX4)
}

// MAIN FUNCTIONS - DO NOT EDIT

function LiveXPlay(id, camx, camera, ip, user, pass, cmdport, dataport, audioport, bwidth, quality, w, h){

   camx.ChangeCamX(camera);           // CAMERA - 0=cam 1, 1=cam 2, etc.
   camx.ChangeQualityX(quality);      // QUALITY - 0=High, 1=Med, 2=Low
   camx.ChangeSizeX(w, h);            // SIZE
   document.getElementById("X"+id+"Quality").innerHTML = quality

   camx.CommandPort = cmdport         // COMMAND PORT
   camx.DataPort = dataport           // DATA PORT
   camx.AudioDataPort = audioport     // AUDIO PORT
   camx.BandWidth = bwidth            // BANDWIDTH - normal="LAN", low="MODEM"

   camx.DisablePWD = "True"           // AUTOLOGIN PART1
   camx.UserName = user               // USERNAME
   camx.Password = pass               // PASSWORD
   camx.AutoLogin = "True"            // AUTOLOGIN PART2
   camx.IpAddress = ip                // SITE IP/DDNS

   camx.PlayX();                      // CONNECT
}
function LiveXStop(camx){
   camx.Disconnect();
}
</script>


<SCRIPT LANGUAGE=vbscript>
<!--

CONST iCount = 3

'// **** 4 WAY ONLY *******

sub WebCamX1_OnConnect()
   WebCamX1.EnableDirectDraw True 
end sub
sub WebCamX2_OnConnect()
   WebCamX2.EnableDirectDraw True 
end sub
sub WebCamX3_OnConnect()
   WebCamX3.EnableDirectDraw True 
end sub
sub WebCamX4_OnConnect()
   WebCamX4.EnableDirectDraw True 
end sub

'// **********************


sub WebCamX1_OnLButtonDown()
   Call left_click(WebCamX1, 1)
end sub
sub WebCamX2_OnLButtonDown()
   Call left_click(WebCamX2, 2)
end sub
sub WebCamX3_OnLButtonDown()
   Call left_click(WebCamX3, 3)
end sub
sub WebCamX4_OnLButtonDown()
   Call left_click(WebCamX4, 4)
end sub

sub WebCamX1_OnRButtonDown()
   Call right_click(WebCamX1)
end sub
sub WebCamX2_OnRButtonDown()
   Call right_click(WebCamX2)
end sub
sub WebCamX3_OnRButtonDown()
   Call right_click(WebCamX3)
end sub
sub WebCamX4_OnRButtonDown()
   Call right_click(WebCamX4)
end sub


'// dont edit below here

sub super_res(camx)
   If camx.ChangeQualityX(130) = False Then
       If camx.ChangeQualityX(128) = True Then
           Exit Sub
       Else
           camx.ChangeQualityX(0)
       End If
   End If
end sub

sub right_click(camx)
   If camx.FixWidth = "960" Then camx.FullScreenX
end sub

sub left_click(camx, cam)

   Dim OriginalQ
   OriginalQ = document.getElementById("X" & CStr(cam) & "Quality").innerHTML
   OriginalQ = Cint(OriginalQ)

   If camx.FixWidth = "480" Then
       Call hide_all(cam)
       camx.FixWidth = "960"
       camx.FixHeight = "720"
       document.getElementById("WebCamX" & CStr(cam)).style.display = "none"
       document.getElementById("cover").style.display = "block"
       Delay 0.00001
       document.getElementById("cover").style.display = "none"
       document.getElementById("WebCamX" & CStr(cam)).style.display = "inline"
       camx.ChangeQualityX(0)
   Else
       camx.ChangeQualityX(OriginalQ)
       camx.FixWidth = "480"
       camx.FixHeight = "360"
       document.getElementById("WebCamX" & CStr(cam)).style.display = "none"
       document.getElementById("cover").style.display = "block"
       Delay 0.00001
       document.getElementById("cover").style.display = "none"
       Call show_all(cam)
       document.getElementById("WebCamX" & CStr(cam)).style.display = "inline"
   End If	
end sub

sub hide_all(cam)
   Dim i
   for i = 1 to iCount
       if i <> cam then
           document.getElementById("WebCamX" & CStr(i)).style.display = "none"
       end if
   next
   document.getElementById("br1").style.display = "none"
end sub

sub show_all(cam)
   Dim i
   for i = 1 to iCount
       if i <> cam then
           document.getElementById("WebCamX" & CStr(i)).style.display = "inline"
       end if
   next
   document.getElementById("br1").style.display = "inline"
end sub

Function Delay(nSeconds)
   Dim nStoptime
   nStoptime = timer + nSeconds
   Do While timer <= nStoptime: Loop
End Function
-->
</SCRIPT>

</head>

<body onLoad="PlayX()" onUnload="DestroyX()" bgcolor="navy">
<span id="X1Quality" style="display: none">0</span>
<span id="X2Quality" style="display: none">0</span>
<span id="X3Quality" style="display: none">0</span>
<span id="X4Quality" style="display: none">0</span>
<center>

<!-- CHANGE IN EACH CONTROL: id="WebCamX1" name="WebCamX1" -->

<object classid="clsid:DA8484DE-52DB-4860-A986-61A8682E298A" id="cover" name="cover" width="960" height="720" style="display: none">
<param name="_Version" value="65536">
<param name="_ExtentX" value="7938">
<param name="_ExtentY" value="5583">
<param name="_StockProps" value="0">
<param name="FixSize" value="-1">
<param name="FixWidth" value="960">
<param name="FixHeight" value="720">
</object>

<object classid="clsid:DA8484DE-52DB-4860-A986-61A8682E298A" id="WebCamX1" name="WebCamX1" width="480" height="360">
<param name="_Version" value="65536">
<param name="_ExtentX" value="7938">
<param name="_ExtentY" value="5583">
<param name="_StockProps" value="0">
<param name="FixSize" value="-1">
<param name="FixWidth" value="480">
<param name="FixHeight" value="360">
<param name="AutoReConnect" value="1">
<param name="MaxRetries" value="100">
<param name="RetryInterval" value="40">
</object>

<object classid="clsid:DA8484DE-52DB-4860-A986-61A8682E298A" id="WebCamX2" name="WebCamX2" width="480" height="360">
<param name="_Version" value="65536">
<param name="_ExtentX" value="7938">
<param name="_ExtentY" value="5583">
<param name="_StockProps" value="0">
<param name="FixSize" value="-1">
<param name="FixWidth" value="480">
<param name="FixHeight" value="360">
<param name="AutoReConnect" value="1">
<param name="MaxRetries" value="100">
<param name="RetryInterval" value="40">
</object>

<span id="br1"><BR></span>

<object classid="clsid:DA8484DE-52DB-4860-A986-61A8682E298A" id="WebCamX3" name="WebCamX3" width="480" height="360">
<param name="_Version" value="65536">
<param name="_ExtentX" value="7938">
<param name="_ExtentY" value="5583">
<param name="_StockProps" value="0">
<param name="FixSize" value="-1">
<param name="FixWidth" value="480">
<param name="FixHeight" value="360">
<param name="AutoReConnect" value="1">
<param name="MaxRetries" value="100">
<param name="RetryInterval" value="40">
</object>

<object classid="clsid:DA8484DE-52DB-4860-A986-61A8682E298A" id="WebCamX4" name="WebCamX4" width="480" height="360">
<param name="_Version" value="65536">
<param name="_ExtentX" value="7938">
<param name="_ExtentY" value="5583">
<param name="_StockProps" value="0">
<param name="FixSize" value="-1">
<param name="FixWidth" value="480">
<param name="FixHeight" value="360">
<param name="AutoReConnect" value="1">
<param name="MaxRetries" value="100">
<param name="RetryInterval" value="40">
</object>

<BR><BR>

<input type="Submit" name="Disconnect" value="Disconnect" onClick="DestroyX();"> 

</center>

</body>
</html>

Share this post


Link to post
Share on other sites
since im feeling generous today .. right before I goto the dentist LOL ..

 

place this in a HTML file and change the IP and user and pass etc ..

 

---------------- HTML REQUIRES IE as it is VBSCRIPT METHOD -------------

[/code][/size]

 

Tried this and changed the code for IP, user and pass.

Got it to work. Thanks. How do I go about just displaying 1 camera?

Edited by Guest

Share this post


Link to post
Share on other sites
In this order:

 

DisablePWD = True

UserName = MyUserName

Password = MyPassword

AutoLogin = True

 

CommandPort = MyCommandPort <- OPTIONAL

DataPort = MyDataPort <- OPTIONAL

AudioDataPort = MyAudioPort <- OPTIONAL

 

IpAddress = MyIPAddress

BandWidth = LAN <- LAN or MODEM

ChangeQualityX 2 <-320x240 - 2=low, 1=mid, 0=high <- OPTIONAL

ChangeCamX 0 <-camera number 0-15

 

PlayX

 

Changed the order so listed as you have them. Also changed AutoLogin to

Does not work. Tried with quotes and no quotes around the True to no avail. Still have to Change Server and click the OK button and then it logs in and I see my camera.

Share this post


Link to post
Share on other sites

 

Changed the order so listed as you have them. Also changed AutoLogin to

Does not work. Tried with quotes and no quotes around the True to no avail. Still have to Change Server and click the OK button and then it logs in and I see my camera.

 

The above script example works for you though?

Ive used it as demo on my site before and another member here also uses it, so should be okay. You are using ActiveX right, not the Java applet?

 

Rory

Edited by Guest

Share this post


Link to post
Share on other sites

Also, the only params you should use are these, the rest goes in JavaScript prior to that:

 

<object classid="clsid:DA8484DE-52DB-4860-A986-61A8682E298A" id="WebCamX1" name="WebCamX1" width="480" height="360">
<param name="_Version" value="65536">
<param name="_ExtentX" value="7938">
<param name="_ExtentY" value="5583">
<param name="_StockProps" value="0">
<param name="FixSize" value="-1">
<param name="FixWidth" value="480">
<param name="FixHeight" value="360">
<param name="AutoReConnect" value="1">
<param name="MaxRetries" value="100">
<param name="RetryInterval" value="40">
</object>

 

This is an example of the JavaScript as I posted above:

 

function LiveXPlay(id, camx, camera, ip, user, pass, cmdport, dataport, audioport, bwidth, quality, w, h){

   camx.ChangeCamX(camera);           // CAMERA - 0=cam 1, 1=cam 2, etc.
   camx.ChangeQualityX(quality);      // QUALITY - 0=High, 1=Med, 2=Low
   camx.ChangeSizeX(w, h);            // SIZE
   document.getElementById("X"+id+"Quality").innerHTML = quality

   camx.CommandPort = cmdport         // COMMAND PORT
   camx.DataPort = dataport           // DATA PORT
   camx.AudioDataPort = audioport     // AUDIO PORT
   camx.BandWidth = bwidth            // BANDWIDTH - normal="LAN", low="MODEM"

   camx.DisablePWD = "True"           // AUTOLOGIN PART1
   camx.UserName = user               // USERNAME
   camx.Password = pass               // PASSWORD
   camx.AutoLogin = "True"            // AUTOLOGIN PART2
   camx.IpAddress = ip                // SITE IP/DDNS

   camx.PlayX();                      // CONNECT
}

 

Then use that function like this still inside Javascript:

 

LiveXPlay (1, document.WebCamX1, 0, "10.10.10.10","demo", "demo", "4550", "5550", "6550", "LAN", 0, "480", "360")

 

Also, this is very important to initiate the above LiveX play when the page loads:

 

 

I have a couple versions of the above, 4, 9, and 16 way, if you want I can post each one here.

Share this post


Link to post
Share on other sites
I have a couple versions of the above, 4, 9, and 16 way, if you want I can post each one here.

 

Would love those. Thanks for your help.

Share this post


Link to post
Share on other sites

Ok here are all of them - 4, 9, and 16 channel versions.

http://www.bahamassecurity.com/geo/GeoWebCam.zip

 

Things you want to change are:

Camera, IP, User, Pass, BandWidth, Quality

 

Camera = 0-15 (1-16)

IP = your DVR's IP or DDNS

User/Pass = your user login

Bandwidth = LAN or MODEM (modem for slow connections)

Quality = 320x240 [0=High, 1=Med, 2=Low], 128=640x480, 130=720x480

 

The playX function is all you need to change, unless you want to add or remove controls.

Share this post


Link to post
Share on other sites
This is an example of the JavaScript as I posted above:

 

Was working fine but now it is not. If I am in GeoVision I can see my cameras fine but now using your script I get a "Server Close!!" for an active camera or "No Privlege" for a camera with video lost. Can not figure out why I can't see my cameras now. Only thing I have done is change my router but don't see how that would affect it.

Share this post


Link to post
Share on other sites
This is an example of the JavaScript as I posted above:

 

Noticed another problem with your script. Can see on the actual server itself but when I am on another computer in my intranet I get a error msg and can't see the images.

Error is on

Line: 31

Char: 5

Error: Object doesn't support this property or method

Code: 0

URL: http://193.175.10.158/cameras-4.htm

 

Line 31 is

camx.ChangeCamX(camera); // CAMERA - 0=cam 1, 1=cam 2, etc

 

Do you know why I am having this problem?

Share this post


Link to post
Share on other sites
Yes, it will not work unless you install the LiveX from here:

http://www.bahamassecurity.com/geo/LiveX7Install.zip

 

The standard version you currently have installed does not have all the functions required.

 

Get a version error when I install this on another computer, not the server. Installed http://www.bahamassecurity.com/geo/LiveXInstall.exe and that works.

 

Now just need to fix the Server Close msg. If I am in GeoVision I can see my cameras fine but now using your script I get a "Server Close!!" for an active camera or "No Privlege" for a camera with video lost. Can not figure out why I can't see my cameras now. Only thing I have done is change my router but don't see how that would affect it.

Share this post


Link to post
Share on other sites

Hi, Server Close means the Server closed the connection, basically the Webcam Server Stopped. (some times you can get that error for other unknown reasons though)

 

What version is on the DVR you are connecting to?

 

make sure you are adding the camera numbers in correctly also, such as Camera 1 on the DVR will be Camera 0 in the script, Camera 2 will be Camera 1 in the script, etc. as Geo uses Zero based numbering in their ActiveX.

 

Make sure all Ports are forwarded in the router also.

Data, Command, and HTTP ports.

Share this post


Link to post
Share on other sites

BTW, Invalid Version means Incompatible Webcam Version, according to Geo anyway.But ive seen it occur before when the versions were the same and put it down to being a webcam bug, such as when it disconnects too fast while it is trying to connect. Basically these are events, and they rely on the Webcam Server on the DVR .. the ActiveX has to be a compatible version though or it wont know what is what. Ive tested from 7.0-8.12 without issues using the 7.0 ActiveX (i also have the 8.xx but had issues before so did not integrate that as yet) but never tested on 8.2 yet. Ofcourse varying connection issues can cause strange event messages also from my experience.

Share this post


Link to post
Share on other sites
Hi, Server Close means the Server closed the connection, basically the Webcam Server Stopped. (some times you can get that error for other unknown reasons though)

 

What version is on the DVR you are connecting to?

 

make sure you are adding the camera numbers in correctly also, such as Camera 1 on the DVR will be Camera 0 in the script, Camera 2 will be Camera 1 in the script, etc. as Geo uses Zero based numbering in their ActiveX.

 

Make sure all Ports are forwarded in the router also.

Data, Command, and HTTP ports.

 

Geovision ver 7 with the GV-800 card in my Windows XP system. Setup everything fine that I know of.

LiveXPlay (1, document.WebCamX1, 0, "193.175.10.158","admin", "test", "4550", "5550", "6550", "LAN", 0, "200", "170")

I am seeing in the Multicam Surveillance System 7.0 that the Webcam Server(W) has a checkmark next to it and in my icon bar in the bottom right, with time, I see the icon of a camera for the WebCam running.

Share this post


Link to post
Share on other sites

Looks okay. Make sure all the ports are forwarded in the new router, that means 4550, 5550, and whichever port you are using for HTTP, 80 is the default. 6550 port forward is only required if you are using Audio.

 

Where are you running this script from, not the DVR though right?

Also what OS does this PC have (the client).

Any other software running like Nortons, or 3rd Party Firewalls?

Share this post


Link to post
Share on other sites
Looks okay. Make sure all the ports are forwarded in the new router, that means 4550, 5550, and whichever port you are using for HTTP, 80 is the default. 6550 port forward is only required if you are using Audio.

 

Where are you running this script from, not the DVR though right?

Also what OS does this PC have (the client).

Any other software running like Nortons, or 3rd Party Firewalls?

 

Checked out the settings for the router and verified that the ports were open. I am running this script on the server and 2 other computers on the intranet using Windows XP. I can't even see the cameras on the server pc. Have Windows XP Firewall running but settings have not changed on it and was working at one time and now it is not. Even turned it off and that did not make a difference.

 

If WebCam is running then I get the Server Close!! error msg. If I turn it off then I get Can't connect to server error msg. Looked in the log files and for Login it shows that the computer(s) are logging in successfully to WebCam (MPEG4).

 

Even tried LanMpegView0.htm which worked before too, but I had to login, and it is not working. Why is WebCam not being allowed through? Can someone step me through checking the ports and such to make sure?

Share this post


Link to post
Share on other sites

First on the PC, add the ports to the Windows Firewall, or disable it (not recommended).

 

In the Router's Application and Gaming section for Port Forwarding, add all the ports there also ..

 

Unless you changed the ports in the Webcam Server section:

80, 4550 and 5550

 

For port forwarding on the Router:

http://www.cctvforum.com/viewtopic.php?t=3287

http://www.cctvforum.com/viewtopic.php?t=12156

Share this post


Link to post
Share on other sites
First on the PC, add the ports to the Windows Firewall, or disable it (not recommended).

 

In the Router's Application and Gaming section for Port Forwarding, add all the ports there also ..

 

Unless you changed the ports in the Webcam Server section:

80, 4550 and 5550

 

For port forwarding on the Router:

http://www.cctvforum.com/viewtopic.php?t=3287

http://www.cctvforum.com/viewtopic.php?t=12156

 

That didn't work. Saw somewhere about reinstalling GeoVision so I did and now it is working. Go figure.

 

By the way do you have a scaled down version of your script so I could see the cameras via a wireless computer on 11g? Tried with the quality on 2 and the size real small but still do not see anything but blue in the windows.

Share this post


Link to post
Share on other sites

What type of computer is it?

Speed should be the same.

 

Anyway, you could change the "LAN" to "MODEM"

Set to quality of 2 as you have

 

You can also disable direct draw and that speeds it up just a tad:

 

Replace: (all WebCamX's)

 

EnableDirectDraw True

 

To:

 

EnableDirectDraw False

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

×