Hi Sumit,
Conceptually referencing .dll and including .cs is not different thus
both should work. In fact the .dll is nothing else but a compilation
result of the reference.cs.
If you have concerns about location of the assembly specify it with
the full absolute path in your "//css_ref". Another troubleshooting
trick is to use /verbose switch.
You can also right-click the script and open it in VS. This way you
will see what dependency files the script engine is trying to
reference/include.
Cheers,
Oleg
> > --------------------------------------------------------------------------------------------
> > Internet:
http://www.csscript.net
> > E-Mail:
csscript.supp...@gmail.com
>
> > On Mon, Jun 13, 2011 at 11:11 AM, sumit poddar <
poddarsu...@gmail.com>wrote:
>
> >> Is it just enough to copy the cs.dll file.
>
> >> I find that till the solution is open in Visual studio it works via VS and
> >> command line.
> >> However as soon as I close Visual studio it fails.
>
> >> I have copied the .cs.dll file to a separate directory and accessing the
> >> file using //css_ref
>
> >> I get an error
>
> >> c:\Users\sumit.poddar.EUTANDBERG\Documents\CS-Scripts\new script
> >> (1).cs(12,9): error CS0246: The type or namespace name 'Test1' could not be
> >> found (are you missing a using directive or an assembly reference?)
>
> >> Do I need to copy all the folders or just this 1 file should do.
>
> >> Regards
> >> Sumit
>
> >> On Mon, Jun 13, 2011 at 12:16 PM, Oleg Shilo <
oleg.sh...@gmail.com>wrote:
>
> >>> The proxy assembly is generated by VS (through execution of wsdl.exe) in
> >>> one of the project temporary directories. Typical sample:
>
> >>> C:\...\Documents\Visual Studio
> >>> 2010\Projects\WcfService2\ConsoleApplication1\obj\x86\Debug\TempPE\Service
> >>> References.ServiceReference1.Reference.cs.dll
>
> >>> Cheers,
>
> >>> Oleg Shilo
>
> >>> --------------------------------------------------------------------------------------------
> >>> Internet:
http://www.csscript.net
> >>> E-Mail:
csscript.supp...@gmail.com
>
> >>> On Mon, Jun 13, 2011 at 10:00 AM, sumit poddar <
poddarsu...@gmail.com>wrote:
>
> >>>> Hi Oleg
>
> >>>> I would like to do it the VS way rather than the command line way.
>
> >>>> A quick question though.
>
> >>>> When you say to copy the WebService proxy from where can I copy it.
>
> >>>> The steps taken to create the web reference are
>
> >>>> 1) Reference -> Service Reference -> Web Reference.
>
> >>>> I am not sure whether the webservice proxy class would have been
> >>>> created. It does not appear to have created it in the script folder.
> >>>> When I click the web reference it does not seem to tell me the folder
> >>>> location.
>
> >>>> Cheers
> >>>> Sumit
>
> >>>> On Mon, Jun 13, 2011 at 11:53 AM, Oleg Shilo <
oleg.sh...@gmail.com>wrote:
>
> >>>>> Hello Sumit,
>
> >>>>> After VS created WebService proxy you just need to copy it and then
> >>>>> reference from the script with //css_ref... After all it is nothing else but
> >>>>> a simple managed assembly.
>
> >>>>> You can also create the proxy assembly directly from the script
> >>>>> code direct from the script. Though it would require you understanding
> >>>>> command-line interface of wsdl.exe. Thus if you are not comfortable with
> >>>>> this using VS would be a preferred choice for you. Otherwise have a look
> >>>>> here:
http://www.csscript.net/help/ws.html.
>
> >>>>> Regards,
> >>>>> Oleg Shilo
>
> >>>>> --------------------------------------------------------------------------------------------
> >>>>> Internet:
http://www.csscript.net
> >>>>> E-Mail:
csscript.supp...@gmail.com
> >>>>> You can register for e-mail notification on CS-Script updates: Add to
> >>>>> mailing list <
csscript.supp...@gmail.com?subject=MailingListAdd>
>
> >>>>> On Mon, Jun 13, 2011 at 6:29 AM, poddarsumit <
poddarsu...@gmail.com>wrote:
>
> >>>>>> Hi
>
> >>>>>> In a script using the Visual Studio IDE created a webreference say
> >>>>>> (webreference 1).
> >>>>>> However to access the webreference Visual Studio resolves it as
> >>>>>> ConsoleApplication1.webreference1.
> >>>>>> This works fine from within the IDE.
>
> >>>>>> However trying to run it from the command line it fail saying
> >>>>>> c:\Users\sumit.poddar.EUTANDBERG\Documents\CS-Scripts\new script
> >>>>>> (1).cs(9,9): er
> >>>>>> ror CS0246: The type or namespace name 'ConsoleApplication1' could not
> >>>>>> be found
>
> >>>>>> Could not find any info about using web references using CS-Script so
> >>>>>> would be good to know how it can be done.
>
> >>>>>> Cheers
> >>>>>> Sumit- Hide quoted text -
>
> - Show quoted text -