Jump to content

Can you help me?


Daywap
 Share

Recommended Posts

Hi I am making random user agent maker on firefox, can anyone help me?

First that I need to. Get random line from text and print in.

Second I need to make it run every 2 minutes. (loop?)

#Include <FF.au3>

_FFStart("about:config")
_FFPrefSet("general.useragent.override", "MY RANDOM USER AGENT SHOULD BE HERE :P")

Any ideas?

Link to comment
Share on other sites

  • Developers

"Random(1, 10)"

must be

Random(1, 10)

" -> Double Quote (but you could have spent a little time to figure that out yourself.)

Jos :)

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

"Random(1, 10)"

must be

Random(1, 10)

" -> Double Quote (but you could have spent a little time to figure that out yourself.)

Jos :)

I already tried it, but it wont work

#Include <FF.au3>

_FFConnect()


_FFPrefSet("general.useragent.override", Random(1, 10))

I mean when I make not random it works.

Link to comment
Share on other sites

  • Developers

Random works fine:

MsgBox(0,"random",Random(1, 10))

Maybe you need an Integer as output of the random() func, just check the helpfile for that.

Edited by Jos

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

Random works fine:

MsgBox(0,"random",Random(1, 10))

Maybe you need an Integer as output of the random() func, just check the helpfile for that.

I searched for that about for 30minutes and nothing :). Cmon is that so hard? Please just show me where I have to write random ;). PPPLEEEAAASEE B)
Link to comment
Share on other sites

  • Developers

I searched for that about for 30minutes and nothing :). Cmon is that so hard? Please just show me where I have to write random ;). PPPLEEEAAASEE B)

Where did you search? The helpfile?

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

  • Developers

Yes, I mean I found something but have no idea how to use it

How difficult can this be?

Random

--------------------------------------------------------------------------------

Generates a pseudo-random float-type number.

Random ( [Min [, Max [, Flag]]] )

Parameters

Min [optional] The smallest number to be generated. The default is 0.

Max [optional] The largest number to be generated. The default is 1.

Flag [optional] If this is set to 1 then an integer result will be returned. Default is a floating point number.

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...